From de8000bc9a9287ce0850c89ffc03e50f7c07deaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Germain=20Carr=C3=A9?= Date: Thu, 1 Jun 2023 21:12:08 +0200 Subject: [PATCH] Fixing go build with GCC static linking --- Makefile | 8 ++++---- VERSION | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 4e55bbd..ea61888 100644 --- a/Makefile +++ b/Makefile @@ -42,8 +42,8 @@ releases: fi ; \ mkdir $$RELEASE_DIR; \ echo "Building Wigo release for $$target to $$RELEASE_DIR"; \ - $(build) -ldflags "-X wigo.Version=$(RELEASE_VERSION)" -o $$RELEASE_DIR/wigo $(BASE_DIR)/src/wigo.go; \ - $(build) -ldflags "-X wigo.Version=$(RELEASE_VERSION)" -o $$RELEASE_DIR/wigocli $(BASE_DIR)/src/wigocli.go; \ + $(build) -ldflags "-extldflags '-static' -X wigo.Version=$(RELEASE_VERSION)" -o $$RELEASE_DIR/wigo $(BASE_DIR)/src/wigo.go; \ + $(build) -ldflags "-extldflags '-static' -X wigo.Version=$(RELEASE_VERSION)" -o $$RELEASE_DIR/wigocli $(BASE_DIR)/src/wigocli.go; \ $(build) -o $$RELEASE_DIR/generate_cert $(BASE_DIR)/src/generate_cert.go; \ done @@ -51,8 +51,8 @@ release: @echo "Building Wigo release for current OS" @mkdir -p release @cd release; \ - $(build) -ldflags "-X wigo.Version=$(RELEASE_VERSION)" -o current/wigo $(BASE_DIR)/src/wigo.go; \ - $(build) -ldflags "-X wigo.Version=$(RELEASE_VERSION)" -o current/wigocli $(BASE_DIR)/src/wigocli.go; \ + $(build) -ldflags "-extldflags '-static' -X wigo.Version=$(RELEASE_VERSION)" -o current/wigo $(BASE_DIR)/src/wigo.go; \ + $(build) -ldflags "-extldflags '-static' -X wigo.Version=$(RELEASE_VERSION)" -o current/wigocli $(BASE_DIR)/src/wigocli.go; \ $(build) -o current/generate_cert $(BASE_DIR)/src/generate_cert.go debs: diff --git a/VERSION b/VERSION index 0633755..510927b 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.73.25 +0.73.26