summaryrefslogtreecommitdiffstats
path: root/main/tlsdate/APKBUILD
blob: c072d8ef49b24a405ab7235315b018680b886146 (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=tlsdate
pkgver=0.0.4
pkgrel=0
pkgdesc="secure parasitic rdate replacement"
url="https://github.com/ioerror/tlsdate"
arch="all"
license="BSD"
depends=""
depends_dev=""
makedepends="autoconf automake libtool openssl-dev"
install=""
subpackages="$pkgname-doc"
source="saveas-https://github.com/ioerror/tlsdate/tarball/tlsdate-${pkgver}/tlsdate-${pkgver}.tar.gz"

_builddir="$srcdir/tlsdate-${pkgver}"
prepare() {
	local i
	mv $srcdir/ioerror-tlsdate-* "$srcdir/tlsdate-${pkgver}"
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	autoreconf --install
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--disable-static \
		--sysconfdir=/etc \
		|| return 1
	make CFLAGS+="-DUNPRIV_GROUP='\"nobody\"'" || return 1
}

package() {
	cd "$_builddir"
	make install DESTDIR="$pkgdir" || return 1
	rm "$pkgdir"/usr/lib/*.la
}

md5sums="af45899b7ee5eaf1676d5a478481e6f9  tlsdate-0.0.4.tar.gz"