diff options
author | Kevin MacMartin | 2021-07-03 15:44:19 -0400 |
---|---|---|
committer | Kevin MacMartin | 2021-07-03 15:44:19 -0400 |
commit | dc527866114696a06ac83a61d517c8cf15ca242c (patch) | |
tree | 1e90f1cd953f02f44bb6599a72df0feb6b200e03 | |
parent | 7a0668c295345d41323dcaf51c20526fcdc407a8 (diff) | |
download | aur-dc527866114696a06ac83a61d517c8cf15ca242c.tar.gz |
Use the current archlinux recommended build settings for go packages
-rw-r--r-- | .SRCINFO | 2 | ||||
-rw-r--r-- | PKGBUILD | 11 |
2 files changed, 10 insertions, 3 deletions
@@ -1,7 +1,7 @@ pkgbase = syncthing-discosrv pkgdesc = Discover server for the syncthing P2P synchronization utility pkgver = 1.17.0 - pkgrel = 1 + pkgrel = 2 epoch = 1 url = http://syncthing.net install = syncthing-discosrv.install @@ -8,7 +8,7 @@ _pkgname=syncthing pkgname=$_pkgname-discosrv epoch=1 pkgver=1.17.0 -pkgrel=1 +pkgrel=2 pkgdesc='Discover server for the syncthing P2P synchronization utility' url='http://syncthing.net' license=('MIT') @@ -40,7 +40,14 @@ prepare() { build() { export GOPATH="$srcdir" cd src/github.com/$_pkgname/$_pkgname/cmd/stdiscosrv - go build -modcacherw -x -i -v -ldflags -w + + go build \ + -trimpath \ + -buildmode=pie \ + -mod=readonly \ + -modcacherw \ + -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \ + . } package() { |