commit:     9d5094fbcab380d8ae5f04b8ea00ee4f726167f3
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Oct 25 21:44:52 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Oct 25 21:44:52 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d5094fb

net-dns/bind: backport test fixes to 9.18.29-r2

Backport the test fixes from 511d0f25bfa3cfd3956a83ace532fafaf947dc95.

Closes: https://bugs.gentoo.org/942132
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-dns/bind/bind-9.18.29-r2.ebuild | 20 +++++++++++++++++---
 1 file changed, 17 insertions(+), 3 deletions(-)

diff --git a/net-dns/bind/bind-9.18.29-r2.ebuild 
b/net-dns/bind/bind-9.18.29-r2.ebuild
index 1f40ca79c839..9836f987042d 100644
--- a/net-dns/bind/bind-9.18.29-r2.ebuild
+++ b/net-dns/bind/bind-9.18.29-r2.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit multiprocessing systemd tmpfiles
+inherit systemd tmpfiles
 
 MY_PV="${PV/_p/-P}"
 MY_PV="${MY_PV/_rc/rc}"
@@ -51,10 +51,19 @@ BDEPEND="
        doc? ( dev-python/sphinx )
        test? (
                dev-util/cmocka
-               dev-util/kyua
        )
 "
 
+src_prepare() {
+       default
+
+       # Don't clobber our toolchain defaults
+       sed -i -e '/FORTIFY_SOURCE=/d' configure || die
+
+       # Test is (notoriously) slow/resource intensive
+       sed -i -e 's:ISC_TEST_MAIN:int main(void) { exit(77); }:' 
tests/isc/netmgr_test.c || die
+}
+
 src_configure() {
        local myeconfargs=(
                --prefix="${EPREFIX}"/usr
@@ -73,6 +82,7 @@ src_configure() {
                $(use_enable fixed-rrset)
                $(use_enable static-libs static)
                $(use_enable geoip)
+               $(use_with test cmocka)
                $(use_with geoip maxminddb)
                $(use_with gssapi)
                $(use_with idn libidn2)
@@ -87,7 +97,11 @@ src_configure() {
 src_test() {
        # system tests ('emake test') require network configuration for IPs etc
        # so we run the unit tests instead.
-       TEST_PARALLEL_JOBS="$(makeopts_jobs)" emake unit
+       CI=1 emake unit V=1
+
+       # libtest is an internal test helper library, it has no tests,
+       # so suppress the QA warning.
+       rm libtest/test-suite.log || die
 }
 
 src_install() {

Reply via email to