11# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
22#
3- # Generated on 2025-10-08T09:20:50Z by kres 063080a .
3+ # Generated on 2026-02-12T17:24:59Z by kres 84d286e .
44
55# common variables
66
77SHA := $(shell git describe --match=none --always --abbrev=8 --dirty)
88TAG := $(shell git describe --tag --always --dirty --match v[0-9]\* )
9+ TAG_SUFFIX ?=
910ABBREV_TAG := $(shell git describe --tags >/dev/null 2>/dev/null && git describe --tag --always --match v[0-9]\* --abbrev=0 || echo 'undefined')
1011BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
1112ARTIFACTS := _out
12- IMAGE_TAG ?= $(TAG )
13+ IMAGE_TAG ?= $(TAG )$( TAG_SUFFIX )
1314OPERATING_SYSTEM := $(shell uname -s | tr '[:upper:]' '[:lower:]')
1415GOARCH := $(shell uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
1516WITH_DEBUG ?= false
1617WITH_RACE ?= false
1718REGISTRY ?= ghcr.io
1819USERNAME ?= siderolabs
1920REGISTRY_AND_USERNAME ?= $(REGISTRY ) /$(USERNAME )
20- PROTOBUF_GO_VERSION ?= 1.36.10
21- GRPC_GO_VERSION ?= 1.5 .1
22- GRPC_GATEWAY_VERSION ?= 2.27.3
21+ PROTOBUF_GO_VERSION ?= 1.36.11
22+ GRPC_GO_VERSION ?= 1.6 .1
23+ GRPC_GATEWAY_VERSION ?= 2.27.8
2324VTPROTOBUF_VERSION ?= 0.6.0
24- GOIMPORTS_VERSION ?= 0.37 .0
25+ GOIMPORTS_VERSION ?= 0.42 .0
2526GOMOCK_VERSION ?= 0.6.0
2627DEEPCOPY_VERSION ?= v0.5.8
27- GOLANGCILINT_VERSION ?= v2.5 .0
28- GOFUMPT_VERSION ?= v0.9.1
29- GO_VERSION ?= 1.25.2
28+ GOLANGCILINT_VERSION ?= v2.9 .0
29+ GOFUMPT_VERSION ?= v0.9.2
30+ GO_VERSION ?= 1.26.0
3031GO_BUILDFLAGS ?=
32+ GO_BUILDTAGS ?= ,
3133GO_LDFLAGS ?=
3234CGO_ENABLED ?= 0
3335GOTOOLCHAIN ?= local
3436GOEXPERIMENT ?=
37+ GO_BUILDFLAGS += -tags $(GO_BUILDTAGS )
3538TESTPKGS ?= ./...
3639KRES_IMAGE ?= ghcr.io/siderolabs/kres:latest
3740CONFORMANCE_IMAGE ?= ghcr.io/siderolabs/conform:latest
@@ -43,6 +46,7 @@ PLATFORM ?= linux/amd64
4346PROGRESS ?= auto
4447PUSH ?= false
4548CI_ARGS ?=
49+ WITH_BUILD_DEBUG ?=
4650BUILDKIT_MULTI_PLATFORM ?=
4751COMMON_ARGS = --file=Dockerfile
4852COMMON_ARGS += --provenance=false
@@ -72,7 +76,7 @@ COMMON_ARGS += --build-arg=DEEPCOPY_VERSION="$(DEEPCOPY_VERSION)"
7276COMMON_ARGS += --build-arg=GOLANGCILINT_VERSION="$(GOLANGCILINT_VERSION ) "
7377COMMON_ARGS += --build-arg=GOFUMPT_VERSION="$(GOFUMPT_VERSION ) "
7478COMMON_ARGS += --build-arg=TESTPKGS="$(TESTPKGS ) "
75- TOOLCHAIN ?= docker.io/golang:1.25 -alpine
79+ TOOLCHAIN ?= docker.io/golang:1.26 -alpine
7680
7781# help menu
7882
@@ -124,14 +128,18 @@ respectively.
124128
125129endef
126130
131+ ifneq (, $(filter $(WITH_BUILD_DEBUG ) , t true TRUE y yes 1) )
132+ BUILD := BUILDX_EXPERIMENTAL=1 docker buildx debug --invoke /bin/sh --on error build
133+ endif
134+
127135ifneq (, $(filter $(WITH_RACE ) , t true TRUE y yes 1) )
128136GO_BUILDFLAGS += -race
129137CGO_ENABLED := 1
130138GO_LDFLAGS += -linkmode=external -extldflags '-static'
131139endif
132140
133141ifneq (, $(filter $(WITH_DEBUG ) , t true TRUE y yes 1) )
134- GO_BUILDFLAGS += -tags sidero.debug
142+ GO_BUILDTAGS := $( GO_BUILDTAGS ) sidero.debug,
135143else
136144GO_LDFLAGS += -s
137145endif
@@ -163,6 +171,10 @@ local-%: ## Builds the specified target defined in the Dockerfile using the loc
163171 fi ; \
164172 done'
165173
174+ .PHONY : check-dirty
175+ check-dirty :
176+ @if test -n " ` git status --porcelain` " ; then echo " Source tree is dirty" ; git status; git diff; exit 1 ; fi
177+
166178generate : # # Generate .proto definitions.
167179 @$(MAKE ) local-$@ DEST=./
168180
0 commit comments