diff options
author | Caleb Maclennan | 2020-05-25 16:19:08 +0300 |
---|---|---|
committer | Caleb Maclennan | 2020-05-25 16:22:38 +0300 |
commit | 5dd110ccdaf851f3e4fcb8808d786abc28f737b6 (patch) | |
tree | e5075010612c341b2581f7eebc94263e0fddae59 /PKGBUILD | |
parent | e97cda9b95909e650a597a270ff24c72d5ea6ffc (diff) | |
download | aur-5dd110ccdaf851f3e4fcb8808d786abc28f737b6.tar.gz |
upgpkg: lab-git 0.17.2.r25.g885eea3-1
Use new Go packaging guidelines
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 22 |
1 files changed, 13 insertions, 9 deletions
@@ -5,19 +5,20 @@ _pkgname=lab pkgname=$_pkgname-git -pkgver=0.17.2.r1.gbe53a79 +pkgver=0.17.2.r25.g885eea3 _branch=master pkgrel=1 pkgdesc="A hub-like tool for GitLab (git $_branch branch)" arch=('x86_64') -url="https://zaquestion.github.io/lab/" +url="https://zaquestion.github.io/$_pkgname" license=('custom:Unlicense') depends=('git') optdepends=('hub') makedepends=('git' 'go') -conflicts=("$_pkgname" "$_pkgname-bin") +provides=("$_pkgname") +conflicts=("$_pkgname") source=("git://github.com/zaquestion/$_pkgname.git#branch=$_branch") -sha512sums=('SKIP') +sha256sums=('SKIP') pkgver() { cd "$_pkgname" @@ -32,17 +33,20 @@ prepare() { build () { cd "$_pkgname" go build \ - -gcflags "all=-trimpath=$PWD" \ - -asmflags "all=-trimpath=$PWD" \ - -ldflags "-extldflags $LDFLAGS -X main.version=$pkgver" + -trimpath \ + -buildmode=pie \ + -mod=readonly \ + -modcacherw \ + -ldflags "-extldflags ${LDFLAGS} -X main.version=$pkgver" \ + . ./lab completion bash > completion.bash ./lab completion zsh > completion.zsh } package() { cd "$_pkgname" - install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname"/LICENSE - install -Dm755 lab "$pkgdir"/usr/bin/lab + install -Dm755 -t "$pkgdir/usr/bin/" $_pkgname + install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname/" LICENSE install -Dm644 completion.bash "$pkgdir/usr/share/bash-completion/completions/lab" install -Dm644 completion.zsh "$pkgdir/usr/share/zsh/site-functions/_lab" } |