From 2dd66671f7d2ed51d3fec5c47a7d11ca648d41c9 Mon Sep 17 00:00:00 2001 From: James Mills <1290234+prologic@users.noreply.github.com> Date: Sun, 26 Mar 2023 13:49:09 +1000 Subject: [PATCH] Fix build to correctly inject version --- Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 098cc25..5c241d9 100644 --- a/Makefile +++ b/Makefile @@ -38,16 +38,16 @@ ifeq ($(DEBUG), 1) @echo "Building in debug mode..." @$(GOCMD) build -tags "netgo static_build" -installsuffix netgo \ -ldflags "\ - -X $(shell go list).Version=$(VERSION) \ - -X $(shell go list).Commit=$(COMMIT) \ - -X $(shell go list).Build=$(BUILD)" \ + -X main.Version=$(VERSION) \ + -X main.Commit=$(COMMIT) \ + -X main.Build=$(BUILD)" \ . else @$(GOCMD) build -tags "netgo static_build" -installsuffix netgo \ -ldflags "-w \ - -X $(shell go list).Version=$(VERSION) \ - -X $(shell go list).Commit=$(COMMIT) \ - -X $(shell go list).Build=$(BUILD)" \ + -X main.Version=$(VERSION) \ + -X main.Commit=$(COMMIT) \ + -X main.Build=$(BUILD)" \ . endif