1
0
Fork 0
mirror of https://github.com/pygos/build.git synced 2024-07-01 15:30:13 +02:00
build/pkg/unbound/build
David Oberhollenzer 2d57db89d9 Simplify unbound build
- Remove libevent dependency
 - Since we only have a single config file anyway,
   use it as main unbound.conf
 - We also need libbsd as build dependency
2018-05-25 18:36:36 +02:00

42 lines
977 B
Plaintext

VERSION="1.7.1"
SRCDIR="unbound-${VERSION}"
TARBALL="${SRCDIR}.tar.gz"
URL="https://www.unbound.net/downloads"
SHA256SUM="56e085ef582c5372a20207de179d0edb4e541e59f87be7d4ee1d00d12008628d"
DEPENDS="openssl expat libbsd"
prepare() {
return
}
build() {
$1/configure --prefix="" --host="$TARGET" --disable-static \
--sysconfdir=/etc --with-pidfile=/run/unbound.pid \
--sbindir=/bin --with-libexpat="$TCDIR/$TARGET" \
--with-ssl="$TCDIR/$TARGET"
make -j $NUMJOBS
}
deploy() {
local SOURCE="$1"
local DEPLOY="$2"
local DEVDEPLOY="$3"
make DESTDIR="$DEPLOY" install
rm -r "$DEPLOY/share"
mkdir -p "$DEPLOY/var/lib/unbound"
cat_file_override "unbound.conf" > "$DEPLOY/etc/unbound/unbound.conf"
split_dev_deploy "$DEPLOY" "$DEVDEPLOY"
strip_files ${DEPLOY}/{bin,lib}/*
}
check_update() {
curl --silent -L "$URL" | grep -o ">unbound-[0-9.]*tar.gz<" | \
sed 's/>unbound-//g' | sed 's/.tar.gz<//g' | \
verson_find_greatest "$VERSION"
}