diff options
author | Stephen Gregoratto | 2020-05-23 00:05:10 +1000 |
---|---|---|
committer | Stephen Gregoratto | 2020-05-23 00:05:10 +1000 |
commit | 1960c6504baf40d09353baa1f3f83afa5e74c160 (patch) | |
tree | 09da4aefd7d4fc4d9c05c4caf8288da37a8169d4 | |
parent | 071eaa6cc1f4ca04ae4910ef8960724588053362 (diff) | |
download | aur-1960c6504baf40d09353baa1f3f83afa5e74c160.tar.gz |
sync PKGBUILD with go package guidelines
- Add glibc dep for libpthread (namcap).
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 17 |
3 files changed, 17 insertions, 10 deletions
@@ -1,15 +1,15 @@ pkgbase = goawk pkgdesc = AWK interpreter written in go pkgver = 1.6.1 - pkgrel = 1 + pkgrel = 2 url = https://github.com/benhoyt/goawk arch = i686 arch = x86_64 arch = armv6h arch = armv7h license = MIT - makedepends = go-pie - makedepends = glibc + makedepends = go + depends = glibc source = goawk-1.6.1.tar.gz::https://github.com/benhoyt/goawk/archive/v1.6.1.tar.gz sha256sums = cc2bfd094950b8a67cd022b11095752a059d59efe57ccd64a0e3fc80238f8cb0 diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..e4f9ba3007cf --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +* +!.SRCINFO +!PKGBUILD +!.gitignore @@ -1,21 +1,24 @@ # Maintainer: Stephen Gregoratto <dev@sgregoratto.me> pkgname=goawk pkgver=1.6.1 -pkgrel=1 +pkgrel=2 pkgdesc="AWK interpreter written in go" url="https://github.com/benhoyt/goawk" license=('MIT') arch=('i686' 'x86_64' 'armv6h' 'armv7h') -makedepends=('go-pie' 'glibc') +depends=('glibc') +makedepends=('go') source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz") sha256sums=('cc2bfd094950b8a67cd022b11095752a059d59efe57ccd64a0e3fc80238f8cb0') build() { cd "$pkgname-$pkgver" - go build \ - -trimpath \ - -ldflags "-extldflags $LDFLAGS" \ - -o "$pkgname" . + export CGO_CPPFLAGS="${CPPFLAGS}" + export CGO_CFLAGS="${CFLAGS}" + export CGO_CXXFLAGS="${CXXFLAGS}" + export CGO_LDFLAGS="${LDFLAGS}" + export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw" + go build -o "goawk" . } check() { @@ -24,6 +27,6 @@ check() { } package() { - install -Dm755 "$pkgname-$pkgver/$pkgname" "$pkgdir/usr/bin/$pkgname" + install -Dm755 "$pkgname-$pkgver/goawk" "$pkgdir/usr/bin/goawk" install -Dm644 "$pkgname-$pkgver/LICENSE.txt" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" } |