summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD31
1 files changed, 22 insertions, 9 deletions
diff --git a/PKGBUILD b/PKGBUILD
index c7c03f9e9853..5c61bcaadcee 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,23 +1,36 @@
# Maintainer: N.Boughton, <nicholasboughton@gmail.com>
pkgname=swnt
-pkgver=0.7.4
+pkgver=0.8.2
pkgrel=1
pkgdesc="Command line GM tools for Stars Without Number"
arch=('x86_64')
url="https://github.com/nboughton/swnt"
license=("MIT")
-depends=("git")
-makedepends=('go')
optdepends=('hugo: export sectors as hugo sites')
-source=("${pkgname}-${pkgver}.tar.gz::https://github.com/nboughton/swnt/archive/v${pkgver}.tar.gz")
-sha1sums=('88de7c97fefdaa8eec2eca95e772e076fc053ee7')
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/nboughton/swnt/archive/refs/tags/v${pkgver}.tar.gz")
+sha256sums=('c6f28f6822b699994aed9ac1309aa5c95ae3ca8e5cc6b87ce0fa06e0e390fce6')
+
+prepare(){
+ cd "$pkgname-$pkgver"
+ mkdir -p build/
+}
build() {
- cd "$srcdir/$pkgname-$pkgver"
- go build -v -o swnt
+ cd "$pkgname-$pkgver"
+ export CGO_CPPFLAGS="${CPPFLAGS}"
+ export CGO_CFLAGS="${CFLAGS}"
+ export CGO_CXXFLAGS="${CXXFLAGS}"
+ export CGO_LDFLAGS="${LDFLAGS}"
+ export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw"
+ go build -v -o build
}
+#check() {
+# cd "$pkgname-$pkgver"
+# go test ./...
+#}
+
package() {
- cd "$srcdir/$pkgname-$pkgver"
- install -Dm755 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
+ cd "$pkgname-$pkgver"
+ install -Dm755 build/$pkgname "$pkgdir"/usr/bin/$pkgname
}