summarylogtreecommitdiffstats
path: root/makefile.patch
diff options
context:
space:
mode:
authorSam Whited2019-07-02 09:24:26 -0500
committerSam Whited2019-07-02 09:24:26 -0500
commitc26acab746362fd1a74af99ae8ce976efb917c3c (patch)
tree7316c88a181fe0631eb9c95aaee347e07c4403a4 /makefile.patch
parentb2c0d3ae6a276ca1103750c8312647a4fd89fb09 (diff)
downloadaur-c26acab746362fd1a74af99ae8ce976efb917c3c.tar.gz
Bump to v0.10.0
Diffstat (limited to 'makefile.patch')
-rw-r--r--makefile.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/makefile.patch b/makefile.patch
new file mode 100644
index 000000000000..9755325a23af
--- /dev/null
+++ b/makefile.patch
@@ -0,0 +1,38 @@
+1,2c1,14
+< GITREV=`git describe | cut -c 2-`
+< LDFLAGS=-ldflags="-X 'github.com/writeas/writefreely.softwareVer=$(GITREV)'"
+---
+> # make(1) from NetBSD (bmake on many Linux's) uses $(.CURDIR), but GNU Make uses
+> # $(CURDIR). Normalize on $(.CURDIR) by setting it to $(CURDIR) if not set, and
+> # then $(PWD) if still not set.
+> .CURDIR ?= $(CURDIR)
+> .CURDIR ?= $(PWD)
+>
+> # For reproducible builds, don't store the current build directory by default;
+> # instead store only the path from the root of the repo (so there is still
+> # enough info in debug messages to find the correct file).
+> GCFLAGS = -gcflags="all=-trimpath=$(.CURDIR)"
+> ASMFLAGS = -asmflags="all=-trimpath=$(.CURDIR)"
+>
+> GITREV!=git describe --tags | cut -c 2-
+> GOLDFLAGS=-ldflags="-X 'github.com/writeas/writefreely.softwareVer=$(GITREV)' -extldflags '$(LDFLAGS)'"
+5,7c17,19
+< GOINSTALL=$(GOCMD) install $(LDFLAGS)
+< GOBUILD=$(GOCMD) build $(LDFLAGS)
+< GOTEST=$(GOCMD) test $(LDFLAGS)
+---
+> GOINSTALL=$(GOCMD) install $(GOLDFLAGS) $(GCFLAGS) $(ASMFLAGS)
+> GOBUILD=$(GOCMD) build $(GOLDFLAGS) $(GCFLAGS) $(ASMFLAGS)
+> GOTEST=$(GOCMD) test $(GOLDFLAGS) $(GCFLAGS) $(ASMFLAGS)
+29c41
+< xgo --targets=linux/amd64, -dest build/ $(LDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely
+---
+> xgo --targets=linux/amd64, -dest build/ $(GOLDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely
+35c47
+< xgo --targets=windows/amd64, -dest build/ $(LDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely
+---
+> xgo --targets=windows/amd64, -dest build/ $(GOLDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely
+41c53
+< xgo --targets=darwin/amd64, -dest build/ $(LDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely
+---
+> xgo --targets=darwin/amd64, -dest build/ $(GOLDFLAGS) -tags='sqlite' -out writefreely ./cmd/writefreely