build: add -trimpath flag for reproducible builds

Strip absolute file system paths from compiled binary to
improve build reproducibility and reduce information leakage.
This commit is contained in:
ZanzyTHEbar 2026-02-18 15:55:52 +00:00
parent 6e23c80924
commit 64f6c7ff5b

View file

@ -16,7 +16,7 @@ LDFLAGS=-ldflags "-X main.version=$(VERSION) -X main.gitCommit=$(GIT_COMMIT) -X
# Go variables
GO?=go
GOFLAGS?=-v -tags stdjson
GOFLAGS?=-v -trimpath -tags stdjson
# Installation
INSTALL_PREFIX?=$(HOME)/.local