summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorChocobo12019-04-29 13:55:53 +0800
committerChocobo12019-04-29 14:27:19 +0800
commit1ded36a2492cfebf3a9ed6569c929eacb4609d0c (patch)
tree31ad38c56af1d3e15ed5f776d4bfc33f12955b9a
downloadaur-1ded36a2492cfebf3a9ed6569c929eacb4609d0c.tar.gz
newpkg: chihaya 1.0.2-1
-rw-r--r--.SRCINFO20
-rw-r--r--PKGBUILD47
2 files changed, 67 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..c88dd6a44f96
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,20 @@
+pkgbase = chihaya
+ pkgdesc = A customizable, multi-protocol BitTorrent tracker
+ pkgver = 1.0.2
+ pkgrel = 1
+ url = https://github.com/chihaya/chihaya
+ arch = i686
+ arch = x86_64
+ license = BSD
+ makedepends = go-pie
+ depends = glibc
+ backup = etc/chihaya.json
+ source = https://github.com/chihaya/chihaya/archive/v1.0.2.tar.gz
+ source = chihaya.service::https://aur.archlinux.org/cgit/aur.git/plain/chihaya.service?h=chihaya-git
+ source = chihaya.sysusers::https://aur.archlinux.org/cgit/aur.git/plain/chihaya.sysusers?h=chihaya-git
+ sha256sums = 17207aeaf1887befba4a100df4e860000fe2e4747ab0c518aad98005606b05fd
+ sha256sums = SKIP
+ sha256sums = SKIP
+
+pkgname = chihaya
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..e977ef37a44f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,47 @@
+# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>
+
+pkgname=chihaya
+pkgver=1.0.2
+pkgrel=1
+pkgdesc="A customizable, multi-protocol BitTorrent tracker"
+arch=('i686' 'x86_64')
+url="https://github.com/chihaya/chihaya"
+license=('BSD')
+depends=('glibc')
+makedepends=('go-pie')
+backup=('etc/chihaya.json')
+source=("https://github.com/chihaya/chihaya/archive/v$pkgver.tar.gz"
+ "chihaya.service::https://aur.archlinux.org/cgit/aur.git/plain/chihaya.service?h=chihaya-git"
+ "chihaya.sysusers::https://aur.archlinux.org/cgit/aur.git/plain/chihaya.sysusers?h=chihaya-git")
+sha256sums=('17207aeaf1887befba4a100df4e860000fe2e4747ab0c518aad98005606b05fd'
+ 'SKIP'
+ 'SKIP')
+
+
+build() {
+ cd "$pkgname-$pkgver"
+
+ GO111MODULE=on \
+ go build \
+ -ldflags "-extldflags $LDFLAGS" \
+ ./cmd/chihaya
+}
+
+check() {
+ cd "$pkgname-$pkgver"
+
+ go test -bench $(go list ./...)
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+
+ install -Dm755 "chihaya" "$pkgdir/usr/bin/chihaya"
+
+ install -Dm644 "$srcdir/chihaya.service" "$pkgdir/usr/lib/systemd/system/chihaya.service"
+ install -Dm644 "$srcdir/chihaya.sysusers" "$pkgdir/usr/lib/sysusers.d/chihaya.conf"
+
+ install -Dm644 "example_config.json" "$pkgdir/etc/chihaya.json"
+
+ install -Dm644 "LICENSE" "$pkgdir/usr/share/licenses/chihaya/LICENSE"
+}