From bdfd1f10d86cdbc4bf8ba820dba452dae9afd132 Mon Sep 17 00:00:00 2001 From: Sam James Date: Wed, 28 May 2025 17:17:07 +0100 Subject: [PATCH] net-dns/bind: fix automagic dtrace/systemtap use Noticed because it automagically tries to use DTrace and with LTO, that goes wrong (for now, but that's being worked on right now). Signed-off-by: Sam James --- net-dns/bind/bind-9.20.7-r1.ebuild | 11 ++++++++++- net-dns/bind/metadata.xml | 1 + 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/net-dns/bind/bind-9.20.7-r1.ebuild b/net-dns/bind/bind-9.20.7-r1.ebuild index 5e2ec26cf327f..010456b8ad3d4 100644 --- a/net-dns/bind/bind-9.20.7-r1.ebuild +++ b/net-dns/bind/bind-9.20.7-r1.ebuild @@ -16,7 +16,7 @@ S="${WORKDIR}/${PN}-${MY_PV}" LICENSE="MPL-2.0" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" -IUSE="dnstap doc doh fixed-rrset idn jemalloc geoip gssapi lmdb selinux static-libs test xml" +IUSE="dnstap doc doh fixed-rrset idn jemalloc geoip gssapi lmdb selinux static-libs systemtap test xml" RESTRICT="!test? ( test )" DEPEND=" @@ -54,6 +54,9 @@ BDEPEND=" test? ( dev-util/cmocka ) + systemtap? ( + dev-debug/systemtap + ) " src_prepare() { @@ -68,6 +71,11 @@ src_configure() { # are available. Force fallback to prebuilt ones. use doc || export ac_cv_path_SPHINX_BUILD= SPHINX_BUILD= + # Workaround for bug #938302 + if use systemtap && has_version "dev-debug/systemtap[-dtrace-symlink(+)]" ; then + export DTRACE="${BROOT}"/usr/bin/stap-dtrace + fi + local myeconfargs=( --prefix="${EPREFIX}"/usr --sysconfdir="${EPREFIX}"/etc/bind @@ -83,6 +91,7 @@ src_configure() { $(use_with doh libnghttp2) $(use_enable static-libs static) $(use_enable geoip) + $(use_enable systemtap tracing) $(use_with test cmocka) $(use_with geoip maxminddb) $(use_with gssapi) diff --git a/net-dns/bind/metadata.xml b/net-dns/bind/metadata.xml index 5dfa7226e586c..1f55c6ba27374 100644 --- a/net-dns/bind/metadata.xml +++ b/net-dns/bind/metadata.xml @@ -12,5 +12,6 @@ Enables fixed rrset-order option Enable gssapi support Enable LMDB support to store configuration for 'addzone' zones + Build support for profiling and tracing using dev-debug/systemtap