diff options
| author | root <root@alpha.trunkmasters.com> | 2026-06-20 14:54:46 -0500 |
|---|---|---|
| committer | root <root@alpha.trunkmasters.com> | 2026-06-20 14:54:46 -0500 |
| commit | 1a4479b4e0368c8d5ff241ebad17b2541a7e3ba0 (patch) | |
| tree | 18e2e784f9fb0dbc3546537acc42ad51b366d90e /net-dns/unbound | |
| parent | 9f6a581d94412ab1cf4b35c33101f6be0ddc7777 (diff) | |
| download | baldeagleos-repo-1a4479b4e0368c8d5ff241ebad17b2541a7e3ba0.tar.gz baldeagleos-repo-1a4479b4e0368c8d5ff241ebad17b2541a7e3ba0.tar.xz baldeagleos-repo-1a4479b4e0368c8d5ff241ebad17b2541a7e3ba0.zip | |
Adding metadata
Diffstat (limited to 'net-dns/unbound')
| -rw-r--r-- | net-dns/unbound/Manifest | 2 | ||||
| -rw-r--r-- | net-dns/unbound/files/unbound-anchor-r1.service | 15 | ||||
| -rw-r--r-- | net-dns/unbound/files/unbound-anchor.service | 13 | ||||
| -rw-r--r-- | net-dns/unbound/files/unbound.service | 12 | ||||
| -rw-r--r-- | net-dns/unbound/files/unbound.socket | 5 | ||||
| -rw-r--r-- | net-dns/unbound/files/unbound_at.service | 13 | ||||
| -rw-r--r-- | net-dns/unbound/metadata.xml | 19 | ||||
| -rw-r--r-- | net-dns/unbound/unbound-1.25.0.ebuild | 214 | ||||
| -rw-r--r-- | net-dns/unbound/unbound-1.25.1.ebuild | 142 |
9 files changed, 89 insertions, 346 deletions
diff --git a/net-dns/unbound/Manifest b/net-dns/unbound/Manifest index 226da442a1f7..d6b4ebe9fe30 100644 --- a/net-dns/unbound/Manifest +++ b/net-dns/unbound/Manifest @@ -1,4 +1,2 @@ -DIST unbound-1.25.0.tar.gz 6818581 BLAKE2B 4c22e198c2257c251505f6845c42e67481edce2c5e8dc0c475584ef6b8e85907c322f32bd7ecfcb06243ba36fb3d91c63d8c1edd67dca66d374c6a242206e548 SHA512 5b11cb06d768461dc390da989d412e8724403a9cce36e95f7b401d0b512bc81ee5a68d4cd6504c89de9a11cce69b90f09e01ae72e2ddd05130b7c459691d4f85 -DIST unbound-1.25.0.tar.gz.asc 659 BLAKE2B e1bc87ba89383da4b0e9ea084e4ea974040488a827f3407501df11cd6245c74cbff19f81c9ad6475b3db73b8f34f1a69a6c23e9c17c807bf18eaa23621915905 SHA512 2f56b626d21a69e2d55c122f49c9e329a6a97652b7e59604dd516288a558f24b9edf86762bba98181fb4a09c43820254e3c416e499e7c2cadad00c39c43ff0a8 DIST unbound-1.25.1.tar.gz 6832247 BLAKE2B da9818a14a540bf2d674f504a38da711cfead20af2c6f987aab74094b441ef31586f28608432d2369b2223b3287290f450218466654c71626e33df74da557f18 SHA512 a536ff1d9b637e4ffa46ab498919ddf089b4498e65c748748c4920a6da52e1f5bacfbba9ac1dc47798d168e2ea64a7ae7ea2a581464d1fcabae241a6e38c8d13 DIST unbound-1.25.1.tar.gz.asc 659 BLAKE2B c629e2ba167e867c49c4ca420b3801e7380a0f35224d8ba5c2c8226c096b53b16f38615cc202492966865d347526f979bc7a146502e5c592d60fdd76a6dc91c4 SHA512 307ce54a35c47e19dda75154424fe8e35382605cb3541ab2c16f567e28c44cfcace5aa14ca8c18d272647b8ef70cfc75f51c27cb0587bc51bd82d074380825aa diff --git a/net-dns/unbound/files/unbound-anchor-r1.service b/net-dns/unbound/files/unbound-anchor-r1.service new file mode 100644 index 000000000000..562e1d43252f --- /dev/null +++ b/net-dns/unbound/files/unbound-anchor-r1.service @@ -0,0 +1,15 @@ +[Unit] +Description=Update of the root trust anchor for DNSSEC validation +Documentation=man:unbound-anchor(8) +After=network-online.target +Before=unbound.service + +[Service] +Type=oneshot +User=unbound +Group=unbound +ExecStart=/usr/bin/unbound-anchor -a /etc/unbound/var/root-anchors.txt -c /etc/dnssec/icannbundle.pem +SuccessExitStatus=1 + +[Install] +WantedBy=multi-user.target diff --git a/net-dns/unbound/files/unbound-anchor.service b/net-dns/unbound/files/unbound-anchor.service deleted file mode 100644 index f55cf9db5d1e..000000000000 --- a/net-dns/unbound/files/unbound-anchor.service +++ /dev/null @@ -1,13 +0,0 @@ -[Unit] -Description=Update of the root trust anchor for DNSSEC validation -After=network.target -Before=nss-lookup.target -Wants=nss-lookup.target -Before=unbound.service - -[Service] -Type=oneshot -ExecStart=/usr/sbin/unbound-anchor - -[Install] -WantedBy=multi-user.target diff --git a/net-dns/unbound/files/unbound.service b/net-dns/unbound/files/unbound.service deleted file mode 100644 index 41dd6fabd290..000000000000 --- a/net-dns/unbound/files/unbound.service +++ /dev/null @@ -1,12 +0,0 @@ -[Unit] -Description=Unbound recursive Domain Name Server -After=network.target -Before=nss-lookup.target -Wants=nss-lookup.target - -[Service] -ExecStartPre=/usr/sbin/unbound-checkconf -ExecStart=/usr/sbin/unbound -d - -[Install] -WantedBy=multi-user.target diff --git a/net-dns/unbound/files/unbound.socket b/net-dns/unbound/files/unbound.socket deleted file mode 100644 index 0628064a4a5e..000000000000 --- a/net-dns/unbound/files/unbound.socket +++ /dev/null @@ -1,5 +0,0 @@ -[Socket] -ListenDatagram=127.0.0.1:1153 -ListenStream=127.0.0.1:1153 -[Install] -WantedBy=sockets.target diff --git a/net-dns/unbound/files/unbound_at.service b/net-dns/unbound/files/unbound_at.service deleted file mode 100644 index 84b34af45446..000000000000 --- a/net-dns/unbound/files/unbound_at.service +++ /dev/null @@ -1,13 +0,0 @@ -[Unit] -Description=Unbound recursive Domain Name Server -After=network.target -Before=nss-lookup.target -Wants=nss-lookup.target - -[Service] -Type=simple -ExecStartPre=/usr/sbin/unbound-checkconf /etc/unbound/%i.conf -ExecStart=/usr/sbin/unbound -d -c /etc/unbound/%i.conf - -[Install] -WantedBy=multi-user.target diff --git a/net-dns/unbound/metadata.xml b/net-dns/unbound/metadata.xml index 101e58b7ddf3..e444be2fbd79 100644 --- a/net-dns/unbound/metadata.xml +++ b/net-dns/unbound/metadata.xml @@ -1,18 +1,10 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> <pkgmetadata> - <maintainer type="project"> - <email>dev@liguros.net</email> - <name>Development</name> - </maintainer> <maintainer type="person"> <email>mschiff@gentoo.org</email> <name>Marc Schiffbauer</name> </maintainer> - <maintainer type="person"> - <email>whissi@gentoo.org</email> - <name>Thomas Deutschmann</name> - </maintainer> <longdescription lang="en"> Unbound is a validating, recursive, and caching DNS resolver. @@ -24,23 +16,20 @@ DNSSEC (secure DNS) validation and stub-resolvers (that do not run as a server, but are linked into an application) are easily possible. </longdescription> - <upstream> - <remote-id type="cpe">cpe:/a:unbound:unbound</remote-id> - </upstream> + <slots> + <subslots>Reflect ABI of libunbound.so.</subslots> + </slots> <use> <flag name="dnscrypt">Enable DNSCrypt support</flag> <flag name="dnstap">Enable dnstap support</flag> <flag name="ecdsa">Enable ECDSA support</flag> <flag name="ecs">Enable EDNS client subnet support</flag> <flag name="gost">Enable GOST support</flag> - <flag name="http2">Enable HTTP/2 support for DoH<pkg>net-libs/nghttp2</pkg> + <flag name="http2">Enable HTTP/2 support for DoH via <pkg>net-libs/nghttp2</pkg> </flag> <flag name="redis">Enable cache db backend which uses <pkg>dev-libs/hiredis</pkg> </flag> <flag name="tfo">Enable TCP Fast Open client+server</flag> </use> <origin>baldeagleos-repo</origin> - <slots> - <subslots>Reflect ABI of libunbound.so.</subslots> - </slots> </pkgmetadata> diff --git a/net-dns/unbound/unbound-1.25.0.ebuild b/net-dns/unbound/unbound-1.25.0.ebuild deleted file mode 100644 index 9232c8efeff9..000000000000 --- a/net-dns/unbound/unbound-1.25.0.ebuild +++ /dev/null @@ -1,214 +0,0 @@ -# Copyright 2021-2026 Liguros Authors -# Distributed under the terms of the GNU General Public License v2 -EAPI=8 -PYTHON_COMPAT=( python3_{13..14} ) - -inherit autotools flag-o-matic multilib-minimal python-single-r1 systemd verify-sig - -MY_P=${PN}-${PV/_/} -DESCRIPTION="A validating, recursive and caching DNS resolver" -HOMEPAGE="https://unbound.net/ https://nlnetlabs.nl/projects/unbound/about/" -SRC_URI=" - https://nlnetlabs.nl/downloads/unbound/${MY_P}.tar.gz - verify-sig? ( https://nlnetlabs.nl/downloads/unbound/${MY_P}.tar.gz.asc ) -" -VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/unbound.net.asc - -LICENSE="BSD GPL-2" -SLOT="0/8" # ABI version of libunbound.so -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~x86" -IUSE="debug dnscrypt dnstap +ecdsa ecs gost +http2 python redis selinux static-libs systemd test +tfo threads" -REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" -RESTRICT="!test? ( test )" - -# Note: expat is needed by executable only but the Makefile is custom -# and doesn't make it possible to easily install the library without -# the executables. MULTILIB_USEDEP may be dropped once build system -# is fixed. - -CDEPEND="acct-group/unbound - acct-user/unbound - >=dev-libs/expat-2.1.0-r3[${MULTILIB_USEDEP}] - >=dev-libs/libevent-2.0.21:0=[${MULTILIB_USEDEP}] - - >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] - dnscrypt? ( dev-libs/libsodium:=[${MULTILIB_USEDEP}] ) - dnstap? ( - dev-libs/fstrm[${MULTILIB_USEDEP}] - >=dev-libs/protobuf-c-1.0.2-r1:=[${MULTILIB_USEDEP}] - ) - ecdsa? ( - dev-libs/openssl:0[-bindist(-)] - ) - http2? ( net-libs/nghttp2:=[${MULTILIB_USEDEP}] ) - python? ( ${PYTHON_DEPS} ) - redis? ( dev-libs/hiredis:= ) -" - -BDEPEND="virtual/pkgconfig" - -DEPEND="${CDEPEND} - python? ( dev-lang/swig ) - test? ( - || ( - net-libs/ldns[examples(-)] - net-dns/ldns-utils[examples(-)] - ) - dev-util/splint - app-text/wdiff - ) - verify-sig? ( sec-keys/openpgp-keys-unbound ) - systemd? ( sys-apps/systemd )" - -RDEPEND="${CDEPEND} - net-dns/dnssec-root - selinux? ( sec-policy/selinux-bind )" - -# bug #347415 -RDEPEND="${RDEPEND} - net-dns/dnssec-root" - -PATCHES=( - "${FILESDIR}"/${PN}-1.5.7-trust-anchor-file.patch - "${FILESDIR}"/${PN}-1.6.3-pkg-config.patch - "${FILESDIR}"/${PN}-1.10.1-find-ar.patch -) - -S=${WORKDIR}/${MY_P} - -pkg_setup() { - use python && python-single-r1_pkg_setup -} - -src_prepare() { - default - - eautoreconf - - # required for the python part - multilib_copy_sources -} - -src_configure() { - [[ ${CHOST} == *-darwin* ]] || append-ldflags -Wl,-z,noexecstack - multilib-minimal_src_configure -} - -multilib_src_configure() { - econf \ - $(multilib_native_use_enable debug) \ - $(multilib_native_use_enable gost) \ - $(multilib_native_use_enable dnscrypt) \ - $(multilib_native_use_enable dnstap) \ - $(multilib_native_use_enable ecdsa) \ - $(multilib_native_use_enable ecs subnet) \ - $(multilib_native_use_enable redis cachedb) \ - $(multilib_native_use_enable static-libs static) \ - $(multilib_native_use_enable systemd) \ - $(multilib_native_use_with python pythonmodule) \ - $(multilib_native_use_with python pyunbound) \ - $(multilib_native_use_with threads pthreads) \ - $(multilib_native_use_with http2 libnghttp2) \ - $(multilib_native_use_enable tfo tfo-client) \ - $(multilib_native_use_enable tfo tfo-server) \ - --disable-flto \ - --disable-rpath \ - --enable-event-api \ - --enable-ipsecmod \ - --with-libevent="${ESYSROOT}"/usr \ - $(multilib_native_usex redis --with-libhiredis="${ESYSROOT}/usr" --without-libhiredis) \ - --with-pidfile="${EPREFIX}"/run/unbound.pid \ - --with-rootkey-file="${EPREFIX}"/etc/dnssec/root-anchors.txt \ - --with-ssl="${ESYSROOT}"/usr \ - --with-libexpat="${ESYSROOT}"/usr - - # http://unbound.nlnetlabs.nl/pipermail/unbound-users/2011-April/001801.html - # $(use_enable debug lock-checks) \ - # $(use_enable debug alloc-checks) \ - # $(use_enable debug alloc-lite) \ - # $(use_enable debug alloc-nonregional) \ -} - -multilib_src_install() { - emake DESTDIR="${D}" install - systemd_dounit contrib/unbound.service - systemd_dounit contrib/unbound.socket -} - -multilib_src_install_all() { - use python && python_optimize - - newinitd "${FILESDIR}"/unbound-r1.initd unbound - newconfd "${FILESDIR}"/unbound-r1.confd unbound - - systemd_newunit "${FILESDIR}"/unbound_at.service "unbound@.service" - systemd_dounit "${FILESDIR}"/unbound-anchor.service - - dodoc doc/{README,CREDITS,TODO,Changelog,FEATURES} - - # bug #315519 - dodoc contrib/unbound_munin_ - - docinto selinux - dodoc contrib/selinux/* - - exeinto /usr/share/${PN} - doexe contrib/update-anchor.sh - - # create space for auto-trust-anchor-file... - keepdir /etc/unbound/var - fowners root:unbound /etc/unbound/var - fperms 0770 /etc/unbound/var - # ... and point example config to it - sed -i \ - -e '/# auto-trust-anchor-file:/s,/etc/dnssec/root-anchors.txt,/etc/unbound/var/root-anchors.txt,' \ - "${ED}/etc/unbound/unbound.conf" \ - || die - - # Used to store cache data - keepdir /var/lib/${PN} - fowners root:unbound /var/lib/${PN} - fperms 0770 /var/lib/${PN} - - find "${ED}" -name '*.la' -delete || die - if ! use static-libs ; then - find "${ED}" -name "*.a" -delete || die - fi -} - -pkg_postinst() { - if [[ ! -f "${EROOT}/etc/unbound/unbound_control.key" ]] ; then - einfo "Trying to create unbound control key ..." - if ! unbound-control-setup &>/dev/null ; then - ewarn "Failed to create unbound control key!" - fi - fi - - if [[ ! -f "${EROOT}/etc/unbound/var/root-anchors.txt" ]] ; then - einfo "" - einfo "If you want unbound to automatically update the root-anchor file for DNSSEC validation" - einfo "set 'auto-trust-anchor-file: ${EROOT}/etc/unbound/var/root-anchors.txt' in ${EROOT}/etc/unbound/unbound.conf" - einfo "and run" - einfo "" - einfo " su -s /bin/sh -c '${EROOT}/usr/sbin/unbound-anchor -a ${EROOT}/etc/unbound/var/root-anchors.txt' unbound" - einfo "" - einfo "as root to create it initially before starting unbound for the first time after enabling this." - einfo "" - fi - - # Our user is not available on prefix - use prefix && return - - local _perm_check_testfile=$(mktemp --dry-run "${EPREFIX}"/etc/unbound/var/.pkg_postinst-perm-check.XXXXXXXXX) - su -s /bin/sh -c "touch ${_perm_check_testfile}" unbound &>/dev/null - if [ $? -ne 0 ] ; then - ewarn "WARNING: unbound user cannot write to \"${EPREFIX}/etc/unbound/var\"!" - ewarn "Run the following commands to restore default permission:" - ewarn "" - ewarn " chown root:unbound ${EPREFIX}/etc/unbound/var" - ewarn " chmod 0770 ${EPREFIX}/etc/unbound/var" - else - # Cleanup -- no reason to die here! - rm -f "${_perm_check_testfile}" - fi -} diff --git a/net-dns/unbound/unbound-1.25.1.ebuild b/net-dns/unbound/unbound-1.25.1.ebuild index 9232c8efeff9..df1221bc4e90 100644 --- a/net-dns/unbound/unbound-1.25.1.ebuild +++ b/net-dns/unbound/unbound-1.25.1.ebuild @@ -1,9 +1,11 @@ -# Copyright 2021-2026 Liguros Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 + EAPI=8 -PYTHON_COMPAT=( python3_{13..14} ) -inherit autotools flag-o-matic multilib-minimal python-single-r1 systemd verify-sig +PYTHON_COMPAT=( python3_{13..14} ) +VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/nlnetlabs.asc +inherit autotools flag-o-matic python-single-r1 systemd verify-sig multilib-minimal MY_P=${PN}-${PV/_/} DESCRIPTION="A validating, recursive and caching DNS resolver" @@ -12,12 +14,14 @@ SRC_URI=" https://nlnetlabs.nl/downloads/unbound/${MY_P}.tar.gz verify-sig? ( https://nlnetlabs.nl/downloads/unbound/${MY_P}.tar.gz.asc ) " -VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/unbound.net.asc +S="${WORKDIR}"/${MY_P} LICENSE="BSD GPL-2" SLOT="0/8" # ABI version of libunbound.so -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~x86" -IUSE="debug dnscrypt dnstap +ecdsa ecs gost +http2 python redis selinux static-libs systemd test +tfo threads" +if [[ ${PV} != *_rc* ]] ; then + KEYWORDS="~alpha amd64 arm arm64 ~hppa ~mips ppc ppc64 ~riscv ~sparc x86" +fi +IUSE="debug dnscrypt dnstap +ecdsa ecs gost +http2 python redis selinux static-libs systemd test +tfo" REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" RESTRICT="!test? ( test )" @@ -25,12 +29,11 @@ RESTRICT="!test? ( test )" # and doesn't make it possible to easily install the library without # the executables. MULTILIB_USEDEP may be dropped once build system # is fixed. - -CDEPEND="acct-group/unbound +DEPEND=" + acct-group/unbound acct-user/unbound >=dev-libs/expat-2.1.0-r3[${MULTILIB_USEDEP}] >=dev-libs/libevent-2.0.21:0=[${MULTILIB_USEDEP}] - >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] dnscrypt? ( dev-libs/libsodium:=[${MULTILIB_USEDEP}] ) dnstap? ( @@ -43,30 +46,27 @@ CDEPEND="acct-group/unbound http2? ( net-libs/nghttp2:=[${MULTILIB_USEDEP}] ) python? ( ${PYTHON_DEPS} ) redis? ( dev-libs/hiredis:= ) + systemd? ( sys-apps/systemd ) " - -BDEPEND="virtual/pkgconfig" - -DEPEND="${CDEPEND} +BDEPEND=" + virtual/pkgconfig python? ( dev-lang/swig ) test? ( - || ( - net-libs/ldns[examples(-)] - net-dns/ldns-utils[examples(-)] - ) + net-libs/ldns[examples(-)] dev-util/splint app-text/wdiff ) - verify-sig? ( sec-keys/openpgp-keys-unbound ) - systemd? ( sys-apps/systemd )" - -RDEPEND="${CDEPEND} + verify-sig? ( >=sec-keys/openpgp-keys-nlnetlabs-20260101 ) +" +RDEPEND=" + ${DEPEND} net-dns/dnssec-root - selinux? ( sec-policy/selinux-bind )" + selinux? ( sec-policy/selinux-bind ) +" -# bug #347415 -RDEPEND="${RDEPEND} - net-dns/dnssec-root" +QA_CONFIG_IMPL_DECL_SKIP=( + ioctlsocket # not on Linux (bug #900060) +) PATCHES=( "${FILESDIR}"/${PN}-1.5.7-trust-anchor-file.patch @@ -74,8 +74,6 @@ PATCHES=( "${FILESDIR}"/${PN}-1.10.1-find-ar.patch ) -S=${WORKDIR}/${MY_P} - pkg_setup() { use python && python-single-r1_pkg_setup } @@ -85,7 +83,7 @@ src_prepare() { eautoreconf - # required for the python part + # Required for the python part multilib_copy_sources } @@ -95,44 +93,50 @@ src_configure() { } multilib_src_configure() { - econf \ - $(multilib_native_use_enable debug) \ - $(multilib_native_use_enable gost) \ - $(multilib_native_use_enable dnscrypt) \ - $(multilib_native_use_enable dnstap) \ - $(multilib_native_use_enable ecdsa) \ - $(multilib_native_use_enable ecs subnet) \ - $(multilib_native_use_enable redis cachedb) \ - $(multilib_native_use_enable static-libs static) \ - $(multilib_native_use_enable systemd) \ - $(multilib_native_use_with python pythonmodule) \ - $(multilib_native_use_with python pyunbound) \ - $(multilib_native_use_with threads pthreads) \ - $(multilib_native_use_with http2 libnghttp2) \ - $(multilib_native_use_enable tfo tfo-client) \ - $(multilib_native_use_enable tfo tfo-server) \ - --disable-flto \ - --disable-rpath \ - --enable-event-api \ - --enable-ipsecmod \ - --with-libevent="${ESYSROOT}"/usr \ - $(multilib_native_usex redis --with-libhiredis="${ESYSROOT}/usr" --without-libhiredis) \ - --with-pidfile="${EPREFIX}"/run/unbound.pid \ - --with-rootkey-file="${EPREFIX}"/etc/dnssec/root-anchors.txt \ - --with-ssl="${ESYSROOT}"/usr \ + local myeconfargs=( + $(multilib_native_use_enable debug) + $(multilib_native_use_enable gost) + $(multilib_native_use_enable dnscrypt) + $(multilib_native_use_enable dnstap) + $(multilib_native_use_enable ecdsa) + $(multilib_native_use_enable ecs subnet) + $(multilib_native_use_enable redis cachedb) + $(multilib_native_use_enable static-libs static) + $(multilib_native_use_enable systemd) + $(multilib_native_use_with python pythonmodule) + $(multilib_native_use_with python pyunbound) + $(multilib_native_use_with http2 libnghttp2) + $(multilib_native_use_enable tfo tfo-client) + $(multilib_native_use_enable tfo tfo-server) + + --disable-flto + --disable-rpath + --enable-event-api + --enable-ipsecmod + + --with-libevent="${ESYSROOT}"/usr + $(multilib_native_usex redis --with-libhiredis="${ESYSROOT}/usr" --without-libhiredis) + + --with-pidfile="${EPREFIX}"/run/unbound.pid + --with-rootkey-file="${EPREFIX}"/etc/dnssec/root-anchors.txt + --with-ssl="${ESYSROOT}"/usr --with-libexpat="${ESYSROOT}"/usr # http://unbound.nlnetlabs.nl/pipermail/unbound-users/2011-April/001801.html - # $(use_enable debug lock-checks) \ - # $(use_enable debug alloc-checks) \ - # $(use_enable debug alloc-lite) \ - # $(use_enable debug alloc-nonregional) \ + # $(use_enable debug lock-checks) + # $(use_enable debug alloc-checks) + # $(use_enable debug alloc-lite) + # $(use_enable debug alloc-nonregional) + ) + + econf "${myeconfargs[@]}" } multilib_src_install() { emake DESTDIR="${D}" install systemd_dounit contrib/unbound.service systemd_dounit contrib/unbound.socket + systemd_dounit contrib/unbound_portable.service } multilib_src_install_all() { @@ -141,29 +145,22 @@ multilib_src_install_all() { newinitd "${FILESDIR}"/unbound-r1.initd unbound newconfd "${FILESDIR}"/unbound-r1.confd unbound - systemd_newunit "${FILESDIR}"/unbound_at.service "unbound@.service" - systemd_dounit "${FILESDIR}"/unbound-anchor.service + systemd_newunit "${FILESDIR}"/unbound-anchor-r1.service unbound-anchor.service dodoc doc/{README,CREDITS,TODO,Changelog,FEATURES} - - # bug #315519 - dodoc contrib/unbound_munin_ + dodoc contrib/{unbound_munin_,metrics.awk} docinto selinux dodoc contrib/selinux/* exeinto /usr/share/${PN} - doexe contrib/update-anchor.sh + doexe contrib/{update-anchor.sh,unbound_cache.sh} - # create space for auto-trust-anchor-file... + # Create space for auto-trust-anchor-file eventually + # downloaded by unbound-anchor keepdir /etc/unbound/var fowners root:unbound /etc/unbound/var fperms 0770 /etc/unbound/var - # ... and point example config to it - sed -i \ - -e '/# auto-trust-anchor-file:/s,/etc/dnssec/root-anchors.txt,/etc/unbound/var/root-anchors.txt,' \ - "${ED}/etc/unbound/unbound.conf" \ - || die # Used to store cache data keepdir /var/lib/${PN} @@ -177,14 +174,14 @@ multilib_src_install_all() { } pkg_postinst() { - if [[ ! -f "${EROOT}/etc/unbound/unbound_control.key" ]] ; then + if [[ ! -f "${EROOT}/etc/unbound/unbound_control.key" ]]; then einfo "Trying to create unbound control key ..." if ! unbound-control-setup &>/dev/null ; then ewarn "Failed to create unbound control key!" fi fi - if [[ ! -f "${EROOT}/etc/unbound/var/root-anchors.txt" ]] ; then + if [[ ! -f "${EROOT}/etc/unbound/var/root-anchors.txt" ]]; then einfo "" einfo "If you want unbound to automatically update the root-anchor file for DNSSEC validation" einfo "set 'auto-trust-anchor-file: ${EROOT}/etc/unbound/var/root-anchors.txt' in ${EROOT}/etc/unbound/unbound.conf" @@ -194,6 +191,7 @@ pkg_postinst() { einfo "" einfo "as root to create it initially before starting unbound for the first time after enabling this." einfo "" + einfo "If using systemd you may also enable the unbound-anchor.service" fi # Our user is not available on prefix @@ -201,7 +199,7 @@ pkg_postinst() { local _perm_check_testfile=$(mktemp --dry-run "${EPREFIX}"/etc/unbound/var/.pkg_postinst-perm-check.XXXXXXXXX) su -s /bin/sh -c "touch ${_perm_check_testfile}" unbound &>/dev/null - if [ $? -ne 0 ] ; then + if [[ $? -ne 0 ]]; then ewarn "WARNING: unbound user cannot write to \"${EPREFIX}/etc/unbound/var\"!" ewarn "Run the following commands to restore default permission:" ewarn "" |
