diff options
author | Sibren Vasse | 2019-02-22 15:08:05 +0100 |
---|---|---|
committer | Sibren Vasse | 2019-02-22 15:26:12 +0100 |
commit | 831093091a3896f8afcd88d073ee29bc49038a38 (patch) | |
tree | 8ef0cffe9eafd209ba62de189a70674772ce7931 | |
parent | f23ed0dadc1aa85edf9a5e0c0197a457984f285e (diff) | |
download | aur-831093091a3896f8afcd88d073ee29bc49038a38.tar.gz |
Fix build, add (PIE, FULL RELRO, strip), add LICENSE file and change project URL
-rw-r--r-- | .SRCINFO | 12 | ||||
-rw-r--r-- | PKGBUILD | 43 |
2 files changed, 33 insertions, 22 deletions
@@ -1,15 +1,13 @@ pkgbase = advanced-ssh-config pkgdesc = ssh wrapper using ProxyCommand that adds regex, aliases, gateways, includes, dynamic hostnames to SSH and ssh-config pkgver = 2.8.0 - pkgrel = 1 - url = https://github.com/moul/advanced-ssh-config + pkgrel = 2 + url = https://github.com/moul/assh arch = x86_64 - arch = i686 license = MIT - makedepends = git - depends = go - options = !strip - options = !emptydirs + makedepends = go-pie + source = advanced-ssh-config-2.8.0.tar.gz::https://github.com/moul/assh/archive/v2.8.0.tar.gz + sha256sums = 17656a6ac562707d6e85df44c1ccd04276fb1c08f1ff6a002291f4cb88880069 pkgname = advanced-ssh-config @@ -1,32 +1,45 @@ -# Maintainer: Hyacinthe Cartiaux <hyacinthe.cartiaux@free.fr> +# Maintainer: Sibren Vasse <arch@sibrenvasse.nl> +# Contributor: Hyacinthe Cartiaux <hyacinthe.cartiaux@free.fr> # Contributor: Philipp Schmitt <philipp@schmitt.co> pkgname=advanced-ssh-config +_name=assh pkgver=2.8.0 -pkgrel=1 +pkgrel=2 pkgdesc='ssh wrapper using ProxyCommand that adds regex, aliases, gateways, includes, dynamic hostnames to SSH and ssh-config' -arch=('x86_64' 'i686') -url='https://github.com/moul/advanced-ssh-config' +arch=('x86_64') +url='https://github.com/moul/assh' license=('MIT') -depends=('go') -makedepends=('git') -options=('!strip' '!emptydirs') -_gourl=github.com/moul/advanced-ssh-config/cmd/assh +makedepends=('go-pie') +source=("${pkgname}-${pkgver}.tar.gz::https://github.com/moul/assh/archive/v${pkgver}.tar.gz") +sha256sums=('17656a6ac562707d6e85df44c1ccd04276fb1c08f1ff6a002291f4cb88880069') +_gourl=github.com/moul/advanced-ssh-config + +prepare() { + mkdir -p "gopath/src/github.com/moul/" + ln -rTsf "${_name}-${pkgver}" "gopath/src/${_gourl}" +} build() { - GOPATH="$srcdir" go get -d ${_gourl} - cd "${srcdir}/src/github.com/moul/${pkgname}/" - git checkout "tags/v${pkgver}" - GOPATH="$srcdir" go get -fix -v -x ${_gourl} + export GOPATH="${srcdir}/gopath" + cd "gopath/src/${_gourl}" + + go install \ + -gcflags "all=-trimpath=$GOPATH" \ + -asmflags "all=-trimpath=$GOPATH" \ + -ldflags "-extldflags $LDFLAGS" \ + ./... } check() { - GOPATH="$srcdir" go test -v -x ${_gourl} + export GOPATH="$srcdir"/gopath + cd "gopath/src/${_gourl}" + go test ./... } package() { - mkdir -p "$pkgdir/usr/bin" - install -p -m755 "$srcdir/bin/"* "$pkgdir/usr/bin" + install -Dm755 gopath/bin/assh "${pkgdir}/usr/bin/assh" + install -Dm644 "${_name}-${pkgver}/LICENSE" "${pkgdir}/usr/share/licenses/$pkgname/LICENSE" } # vim:set ts=2 sw=2 et: |