blob: b4d4abf5c1347ab68285cd0732620087051c882c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
# Maintainer: Jack O'Sullivan <j@ckos.ie>
pkgname=netsoc
pkgdesc="Netsoc CLI"
pkgver=0.4.2
pkgrel=1
arch=('x86_64')
url="https://netsoc.ie"
license=('GPL-3')
depends=('glibc')
makedepends=('go' 'rsync' 'git')
source=(https://github.com/netsoc/cli/archive/v${pkgver}/v${pkgver}.tar.gz)
sha512sums=('f392e1caabdc78779099b7978b3737da2805b0313c0cd4dd038ed7268bebd058fc160ec32c611d4b029029691787bd340f0f745486b9a6086a35943ec7208316')
build() {
cd cli-${pkgver}
export CGO_CPPFLAGS="${CPPFLAGS}"
export CGO_CFLAGS="${CFLAGS}"
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export GOFLAGS="-buildmode=pie -ldflags=-linkmode=external -trimpath -mod=readonly -modcacherw"
export GOLDFLAGS="-linkmode=external"
make VERSION="$pkgver" bin/netsoc
}
package() {
cd cli-${pkgver}
install -Dm755 bin/netsoc -t "$pkgdir/usr/bin"
"$pkgdir/usr/bin/netsoc" docs -t man -o docs/
gzip docs/man1/*
install -Dm644 docs/man1/* -t "$pkgdir/usr/share/man/man1"
"$pkgdir/usr/bin/netsoc" completion bash | install -Dm644 /dev/stdin "$pkgdir/usr/share/bash-completion/completions/netsoc"
"$pkgdir/usr/bin/netsoc" completion zsh | install -Dm644 /dev/stdin "$pkgdir/usr/share/zsh/site-functions/_netsoc"
}
# vim: ts=2 sw=2 et:
|