void-packages/srcpkgs/rng-tools/template
Lon Willett 193e014141 rng-tools: add patch from upstream to fix rngd (#3442)
"rngd" currently crashes (smashed stack) on 64-bit machines that
support the RDRAND instruction, unless you expicitly disable its use.
This fixes the problem.
2018-10-04 23:35:44 +02:00

41 lines
952 B
Bash

# Template file for 'rng-tools'
pkgname=rng-tools
version=6.5
revision=2
wrksrc=${pkgname}-${version}
build_style=gnu-configure
makedepends="libgcrypt-devel libsysfs-devel libcurl-devel libxml2-devel"
hostmakedepends="automake pkg-config"
short_desc="Random number generator related utilities"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
license="GPL-2.0-or-later"
homepage="https://github.com/nhorman/rng-tools/releases"
distfiles="https://github.com/nhorman/rng-tools/archive/v${version}.tar.gz"
checksum=5fecd904f7d01262b3209ff78dd3b9594aac8daa41badd5a1e6438658e80c36e
configure_args="--sbindir=/usr/bin"
case "$XBPS_TARGET_MACHINE" in
*-musl) makedepends+=" argp-standalone"
;;
esac
pre_configure() {
sh autogen.sh
}
do_build() {
case "$XBPS_TARGET_MACHINE" in
*-musl)
LIBS="-largp -lgcrypt"
;;
*)
LIBS="-lgcrypt"
;;
esac
make CC="$CC" LIBS="$LIBS" CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
}
post_install() {
vsv rngd
}