When building bind-tools 9.8.1 (current stable) with ssl USE flags, it does : # ROOT=/data/tmp USE=ssl emerge -vat =bind-tools 9.8.1 ... configure:13743: checking for OpenSSL library configure:13840: result: using OpenSSL from /usr/lib and /usr/include This is wrong here, this is due to configure.in file that set default search dirs if configure is called without a prefix search define in --with-openssl : AC_ARG_WITH(openssl, [ --with-openssl[=PATH] Build with OpenSSL [yes|no|path]. (Required for DNSSEC)], use_openssl="$withval", use_openssl="auto") openssldirs="/usr /usr/local /usr/local/ssl /usr/pkg /usr/sfw" if test "$use_openssl" = "auto" then for d in $openssldirs do if test -f $d/include/openssl/opensslv.h then use_openssl=$d break fi done fi Here a fix for the ebuild to use a correct --with-openssl Reproducible: Always
Created attachment 312711 [details, diff] bind-tools-9.8.1-BJA-SSL-path.diff the patch
This may be extend to xml USE flag, but don't have libxml2 for current target. This to change xml2-config binary PATH
openssl installs .pc files now which should be easy to use
Comment on attachment 312711 [details, diff] bind-tools-9.8.1-BJA-SSL-path.diff ROOT should not be used in src_* funcs
should be all set now in the tree; thanks for the report! Commit message: Clean up openssl logic to fix cross-compiling http://sources.gentoo.org/net-dns/bind-tools/bind-tools-9.10.2-r1.ebuild?rev=1.1 http://sources.gentoo.org/net-dns/bind-tools/files/bind-tools-9.10.2-openssl.patch?rev=1.1
@vapier: Did you send your patch to upstream? It's at least not included in 9.10.4-P1 so I'd have to merge that by hand otherwise. Can you please forward your patch to the ISC guys? It's also not included in net-dns/bind (ebuild).
Upstream fixed it by unconditionally using libcrypto from pkg-config: https://gitlab.isc.org/isc-projects/bind9/commit/5d1e7be582a357256ee76fc31092a3236119268e --- AX_CHECK_OPENSSL([:],[AC_MSG_FAILURE([OpenSSL/LibreSSL not found])]) +++ PKG_CHECK_MODULES([OPENSSL], [libcrypto], [], +++ [AX_CHECK_OPENSSL([:],[AC_MSG_FAILURE([OpenSSL/LibreSSL not found])])])