Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@
.DEFAULT_GOAL := help

CGO_ENABLED = 1
# Go toolchain version. CI exports GO_VERSION (see .github/workflows/*.yml), which
# overrides this default, so the two cannot drift apart.
# The xgo image must ship a Go >= the `go` directive in native/go.mod. Otherwise the
# container silently downloads a newer toolchain whose linker is incompatible with
# that image's mingw-w64 binutils, and the Windows DLL fails to link.
GO_VERSION ?= 1.26.7
XGO_IMAGE = ghcr.io/techknowlogick/xgo:go-$(GO_VERSION)
LD_FLAGS = -s -w
COMMON_BUILD_ARGS = -ldflags "$(LD_FLAGS)" -buildmode=c-shared
MAVEN_OPTIONS =
Expand Down Expand Up @@ -59,7 +66,7 @@ build-native: ## Build the native shared library for the current platform
.PHONY: build-native-cross-platform
build-native-cross-platform: ## Build native shared libraries for all 5 supported platforms (requires Docker)
go install src.techknowlogick.com/xgo@latest
xgo -image ghcr.io/techknowlogick/xgo:go-1.25.10 $(COMMON_BUILD_ARGS) -out native/out/helm --targets */arm64,*/amd64 ./native
xgo -image $(XGO_IMAGE) $(COMMON_BUILD_ARGS) -out native/out/helm --targets */arm64,*/amd64 ./native

.PHONY: build-java
build-java: ## Build and verify the Java artifacts (mvn clean verify)
Expand Down