blob: 9a25fd1426ed778a6562428b8f40fa81fffa4f89 (
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
# Maintainer: shulhan <ms@kilabit.info>
pkgname=rescached-git
pkgver=4.4.2.r9.gd35cf24
pkgrel=1
pkgdesc="Resolver/DNS cache daemon"
arch=('i686' 'x86_64' 'armv7h')
url="https://git.sr.ht/~shulhan/rescached"
license=('GPL-3.0-or-later')
depends=('bash')
provides=('rescached')
makedepends=('git' 'go>=1.20')
_sourcedir=$pkgname
source=(
"$pkgname::git+https://git.sr.ht/~shulhan/rescached"
)
## For testing on local.
#_sourcedir=rescached-local
#source=(
# "$_sourcedir::git+file:///home/ms/go/src/git.sr.ht/~shulhan/rescached#branch=dev"
#)
sha1sums=(
'SKIP'
)
backup=(
'etc/rescached/block.d/.pgl.yoyo.org'
'etc/rescached/block.d/.someonewhocares.org'
'etc/rescached/block.d/.winhelp2002.mvps.org'
'etc/rescached/rescached.cfg'
'etc/rescached/localhost.pem'
'etc/rescached/localhost.pem.key'
)
install=rescached.install
pkgver() {
cd "$_sourcedir"
git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "$_sourcedir"
echo ">>"
echo ">> cleaning ..."
echo ">>"
make clean
echo ">>"
echo ">> make ..."
echo ">>"
unset GOROOT
export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw"
make || return 1
}
package() {
cd "$_sourcedir"
make PREFIX="$pkgdir" install
rm -rf ${pkgdir}/usr/share/rescached/
install -Dm644 $srcdir/$pkgname/COPYING \
"${pkgdir}/usr/share/licenses/rescached/COPYING"
}
|