~dricottone/huttese-apk

ref: 434435020100281b9066726a31d1e4f174ee9941 huttese-apk/sr.ht/searchhut/APKBUILD -rw-r--r-- 2.1 KiB
43443502 — Drew DeVault searchhut: upgrade to 2b6407eacb6f1d682e56157421b408a8cc1cd3a8 2 years ago
                                                                                
3c4b3a32 Drew DeVault
43443502 Drew DeVault
3c4b3a32 Drew DeVault
43443502 Drew DeVault
3c4b3a32 Drew DeVault
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=searchhut
pkgver=0_git20220715
_commit=2b6407eacb6f1d682e56157421b408a8cc1cd3a8
pkgrel=0
pkgdesc="Search engine"
url="https://searchhut.org"
license="AGPL-3.0"
arch="all"
pkgusers="$pkgname"
pkggroups="$pkgname"
install="$pkgname.pre-install"
makedepends="go"
subpackages="$pkgname-openrc"
source="$pkgname-$pkgver.tar.gz::https://git.sr.ht/~sircmpwn/searchhut/archive/$_commit.tar.gz
	sh-api.initd
	sh-api.confd
	sh-web.initd
	sh-web.confd
	"
builddir="$srcdir/$pkgname-$_commit"
options="!check" # no upstream tests

export GOPATH="$srcdir"
export GOFLAGS="$GOFLAGS -trimpath -modcacherw"

build() {
	make
}

package() {
	mkdir -p "$pkgdir"/usr/bin
	for bin in sh-admin sh-api sh-index sh-search sh-web
	do
		cp $bin "$pkgdir"/usr/bin/
	done

	install -Dm755 "$srcdir"/sh-api.initd "$pkgdir"/etc/init.d/sh-api
	install -Dm644 "$srcdir"/sh-api.confd "$pkgdir"/etc/conf.d/sh-api
	install -Dm755 "$srcdir"/sh-web.initd "$pkgdir"/etc/init.d/sh-web
	install -Dm644 "$srcdir"/sh-web.confd "$pkgdir"/etc/conf.d/sh-web

	mkdir -p "$pkgdir"/etc/searchhut
	install -Dm644 config.example.ini "$pkgdir"/etc/searchhut/config.ini

	mkdir -p "$pkgdir"/usr/share/searchhut/templates
	mkdir -p "$pkgdir"/usr/share/searchhut/static
	install -Dm644 templates/* "$pkgdir"/usr/share/searchhut/templates
	install -Dm644 static/* "$pkgdir"/usr/share/searchhut/static
}

sha512sums="
6da89503e6a39181732fd648205095297bf9a07c09e0aa0c88bf22cca8e24abda190fd751d121a0c42fefb38f960f79b5526c5b53fa3a726da345fc64a31f3c5  searchhut-0_git20220715.tar.gz
682a3eccdc59603392bb29ecdfaef07353dcf03d73be4e4a34f4658fada4849163abac2049d9fc988710e47c03b95db4806c7c6f8e4946c177d998f1a838f11d  sh-api.initd
37704c27c178c1e1f7d7475769ec62c5a76cf3acd8e2ab5d981b665d77c21b6135ea73f27b2b79a158fbff814bcdadbc11f31f09c9212064967c712b3bc7907c  sh-api.confd
fc7998ef7de051b4288387b5a172293a0fb6402dc6f6facdfa02f8aa628d4d307e0d2e94f40dfbd4a6bab066961d1af6a8c88bb61fe7b589748a6be0a7b0ef37  sh-web.initd
798824b3100e41de019ccd86f565094826b7a33369f97b07ce33da323817f95b401e07fc73c3d9e3302955a1284b086d18e5355182294f07d301dbbc30ffd278  sh-web.confd
"