From 700f71bb311ccdcf1fed9a5e5948ca1d01e4c790 Mon Sep 17 00:00:00 2001 From: 9seconds Date: Wed, 5 May 2021 11:22:51 +0300 Subject: [PATCH] Add trimpath for better build reproducibility --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a786d4d..f2b25b8 100644 --- a/Makefile +++ b/Makefile @@ -9,7 +9,7 @@ GOLANGCI_LINT_VERSION := v1.39.0 VERSION_GO := $(shell go version) VERSION_DATE := $(shell date -Ru) VERSION_TAG := $(shell git describe --tags --always) -COMMON_BUILD_FLAGS := -mod=readonly -ldflags="-extldflags '-static' -s -w -X 'main.version=$(VERSION_TAG) ($(VERSION_GO)) [$(VERSION_DATE)]'" +COMMON_BUILD_FLAGS := -trimpath -mod=readonly -ldflags="-extldflags '-static' -s -w -X 'main.version=$(VERSION_TAG) ($(VERSION_GO)) [$(VERSION_DATE)]'" GOBIN := $(ROOT_DIR)/.bin GOTOOL := env "GOBIN=$(GOBIN)" "PATH=$(ROOT_DIR)/.bin:$(PATH)"