Skip to content

Commit

Permalink
Add LDFLAGS
Browse files Browse the repository at this point in the history
  • Loading branch information
tomohiro committed Dec 10, 2019
1 parent e9fc789 commit 41e626f
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ PACKAGE = $(shell basename $(PWD))
VERSION = $(shell git describe --abbrev=0 --tags)

# Build information
DIST_DIR = $(PWD)/dist
ASSETS_DIR = $(DIST_DIR)/$(VERSION)
XC_OS = "linux darwin"
XC_ARCH = "386 amd64"
DIST_DIR = $(PWD)/dist
ASSETS_DIR = $(DIST_DIR)/$(VERSION)
XC_OS = "linux darwin"
XC_ARCH = "386 amd64"
BUILD_FLAGS = "-w -s"

# Tasks
help:
Expand Down Expand Up @@ -50,7 +51,10 @@ test: deps

dist: deps
@echo "===> Shipping packages as release assets..."
goxz -d $(ASSETS_DIR) -z -os $(XC_OS) -arch $(XC_ARCH)
goxz -d $(ASSETS_DIR) -z -os $(XC_OS) -arch $(XC_ARCH) --build-ldflags=$(BUILD_LDFLAGS)
pushd $(ASSETS_DIR); \
shasum -a 256 *.zip > ./$(VERSION)_SHA256SUMS; \
popd

release:
@echo "===> Publishing release assets to GitHub..."
Expand Down

0 comments on commit 41e626f

Please sign in to comment.