aboutsummaryrefslogtreecommitdiffstats
path: root/community/rng-tools/APKBUILD
blob: d102c0c55a923debce019a0dd9254059999d7f33 (plain) (blame)
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
# Contributor: Dennis Przytarski <dennis@przytarski.com>
# Maintainer: ScrumpyJack <scrumypjack@st.ilet.to>
pkgname=rng-tools
pkgver=6.2
pkgrel=0
pkgdesc="A random number generator daemon"
url="https://sourceforge.net/projects/gkernel/"
arch="all"
license="GPL-2.0-or-later"
makedepends="argp-standalone autoconf automake linux-headers libtool sysfsutils-dev"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/nhorman/$pkgname/archive/v$pkgver.tar.gz
	fix-textrels-on-PIC-x86.patch
	rngd.confd
	rngd.initd
	"
builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	default_prepare
	./autogen.sh
}

build() {
	cd "$builddir"

	export LIBS="-largp"

	# NOTE: nistbeacon depends on libxml2 and libcurl, so it would
	# significantly increase rng-tools' total size.
	# Likewise for libgcrypt.
	./configure \
		--prefix=/usr \
		--libexecdir=/usr/lib/rng-tools \
		--sysconfdir=/etc \
		--disable-silent-rules \
		--without-libgcrypt \
		--without-nistbeacon
	make
}

package() {
	cd "$builddir"

	make DESTDIR="$pkgdir" install

	install -m 644 -D "$srcdir"/rngd.confd "$pkgdir"/etc/conf.d/rngd
	install -m 755 -D "$srcdir"/rngd.initd "$pkgdir"/etc/init.d/rngd
}

sha512sums="ffd8be5b232f092f8bcfdb6281580ce9053ec8bb87ff6bcae76585c38e3e91b9e464a9544a33ecd9814a9f244a89bac973d15c9bd3560d1164559685c720d174  rng-tools-6.2.tar.gz
5c8196c3e70c093215fc0720cd3f58f339f74293a7eb35d95b914591d783472119dcc34fb27ab6a4c3ce5359e050b4987d1e7ddf213a7445fc0b70d9fae5eae5  fix-textrels-on-PIC-x86.patch
0646fadcdd655038e990b84f7af77f4d0bf4e3353ced849d095d1068f466c9844d8ecdf455f3d7048264a94f60505aae0573b90d62f72ae513ddf41769c0654f  rngd.confd
f9c1ba451c4c2297872287043414af361d8be2822caa6f76f3ea978f01c83b805b9f48cb00c77c7e57f4e385f6e92f704d55ccda92ef956f4ffe7ba1e4bbfdd8  rngd.initd"