make(linux): smaller output binary

This commit is contained in:
mappu 2025-04-16 18:33:42 +12:00
parent 8fdc3a0428
commit 1cddd17017

View File

@ -48,7 +48,7 @@ rsrc_windows_amd64.syso: windows-manifest.json
# Linux release # Linux release
build/qbolt: $(SOURCES) build/qbolt: $(SOURCES)
$(GO) build $(GOFLAGS_L) -o build/qbolt CGO_CFLAGS='-Os -ffunction-sections -fdata-sections -flto=auto' CGO_CXXFLAGS='-Os -ffunction-sections -fdata-sections -flto=auto' CGO_LDFLAGS='-Wl,--gc-sections -flto=auto -fwhole-program' $(GO) build $(GOFLAGS_L) -o build/qbolt
upx build/qbolt upx build/qbolt
build/qbolt-${VERSION}-debian12-x86_64.tar.xz: build/qbolt build/qbolt-${VERSION}-debian12-x86_64.tar.xz: build/qbolt