diff options
author | jjohnstondev | 2023-01-09 00:11:30 -0800 |
---|---|---|
committer | jjohnstondev | 2023-01-09 00:11:30 -0800 |
commit | 3d12837f2ba716abe63f8dfc7ed299ac216e31ec (patch) | |
tree | 2fdbd68c4edfee2081865d7f7908ce51d08965e2 | |
parent | ecdf1fe9969901bead3e161744ec4cd3f41b76b4 (diff) | |
download | aur-3d12837f2ba716abe63f8dfc7ed299ac216e31ec.tar.gz |
update pkgbuild
-rw-r--r-- | .SRCINFO | 9 | ||||
-rw-r--r-- | PKGBUILD | 42 |
2 files changed, 34 insertions, 17 deletions
@@ -1,13 +1,12 @@ pkgbase = gospt - pkgdesc = Spotify TUI and CLI written in Go + pkgdesc = Spotify TUI And CLI written in Go pkgver = 0.0.2 pkgrel = 1 - epoch = 1 url = https://gitea.asdf.cafe/abs3nt/gospt arch = x86_64 - arch = amd64 license = GPL - source = https://gitea.asdf.cafe/abs3nt/gospt/releases/download/v0.0.2/gospt - sha256sums = 6ce6b7743cd6bcd4d6c929528cf40ba4d943b97ae1453a0114c318a6f8cde4b2 + makedepends = go + source = https://gitea.asdf.cafe/abs3nt/gospt/archive/v0.0.2.tar.gz + sha256sums = 11dd23973ad1804176fc9d7a0f552c02b5f435694a1742236a78a8dcbd67c4c8 pkgname = gospt @@ -1,17 +1,35 @@ -# Maintainer: abs3nt <abs3nt@asdf.cafe> -pkgname="gospt" +pkgname=gospt pkgver=0.0.2 pkgrel=1 -epoch=1 -pkgdesc="Spotify TUI and CLI written in Go" -arch=("x86_64" "amd64") -url="https://gitea.asdf.cafe/abs3nt/gospt" +pkgdesc='Spotify TUI And CLI written in Go' +arch=('x86_64') +url="https://gitea.asdf.cafe/abs3nt/$pkgname" license=('GPL') -depends=() -source=( - "https://gitea.asdf.cafe/abs3nt/gospt/releases/download/v${pkgver}/gospt" -) +makedepends=('go') +source=("$url/archive/v$pkgver.tar.gz") +sha256sums=('11dd23973ad1804176fc9d7a0f552c02b5f435694a1742236a78a8dcbd67c4c8') + +prepare(){ + cd "$pkgname" + mkdir -p build/ +} + +build() { + cd "$pkgname" + 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 -o build ./... +} + +check() { + cd "$pkgname" + go test ./... +} + package() { - install -Dm755 gospt "${pkgdir}"/usr/bin/gospt + cd "$pkgname" + install -Dm755 build/$pkgname "$pkgdir"/usr/bin/$pkgname } -sha256sums=('6ce6b7743cd6bcd4d6c929528cf40ba4d943b97ae1453a0114c318a6f8cde4b2') |