summarylogtreecommitdiffstats
path: root/mattermost-ldflags.patch
diff options
context:
space:
mode:
authorWilliam Gathoye2018-11-12 00:01:12 +0100
committerWilliam Gathoye2018-11-12 00:01:12 +0100
commit83d79d16e6609da0489302c735e77251650c2232 (patch)
treee879b58131881d4cc95885992ca1f05692a0db62 /mattermost-ldflags.patch
parent5a3a5657ec681456b9df5ddd4fae2815edfe3c72 (diff)
downloadaur-mattermost-git.tar.gz
Compile Go with PIE and remove unneeded log folder creation
Diffstat (limited to 'mattermost-ldflags.patch')
-rw-r--r--mattermost-ldflags.patch11
1 files changed, 11 insertions, 0 deletions
diff --git a/mattermost-ldflags.patch b/mattermost-ldflags.patch
new file mode 100644
index 00000000000..2f863a0ff9b
--- /dev/null
+++ b/mattermost-ldflags.patch
@@ -0,0 +1,11 @@
+--- a/Makefile
++++ b/Makefile
+@@ -48,6 +48,7 @@ GOFLAGS ?= $(GOFLAGS:)
+ GO=go
+ DELVE=dlv
+ GO_LINKER_FLAGS ?= -ldflags \
+- "-X github.com/mattermost/mattermost-server/model.BuildNumber=$(BUILD_NUMBER)\
++ "-linkmode external -extldflags '$(LDFLAGS)' -s -w \
++ -X github.com/mattermost/mattermost-server/model.BuildNumber=$(BUILD_NUMBER)\
+ -X 'github.com/mattermost/mattermost-server/model.BuildDate=$(BUILD_DATE)'\
+ -X github.com/mattermost/mattermost-server/model.BuildHash=$(BUILD_HASH)\