commit: 3616011f62a387d302fb4c753dfaa0cb34f78726 Author: James Le Cuirot <chewi <AT> gentoo <DOT> org> AuthorDate: Sat Jan 17 23:30:25 2026 +0000 Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org> CommitDate: Mon Jan 19 22:54:19 2026 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3616011f
dev-libs/glib: Fix USE="systemtap" when cross-compiling (including multilib) Use the new meson_add_machine_file helper to pick either --native-file or --cross-file as appropriate. Don't bother checking the dtrace-symlink USE flag because it's simpler to just invoke stap-dtrace unconditionally. Include systemtap in DEPEND because it's also needed for a header. Export CC because it's needed by systemtap when cross-compiling. Closes: https://bugs.gentoo.org/968718 Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org> dev-libs/glib/glib-2.84.4-r1.ebuild | 14 ++++++++------ dev-libs/glib/glib-2.84.4.ebuild | 14 ++++++++------ dev-libs/glib/glib-2.86.1.ebuild | 14 ++++++++------ 3 files changed, 24 insertions(+), 18 deletions(-) diff --git a/dev-libs/glib/glib-2.84.4-r1.ebuild b/dev-libs/glib/glib-2.84.4-r1.ebuild index f6f213fa087c..1d5745b49567 100644 --- a/dev-libs/glib/glib-2.84.4-r1.ebuild +++ b/dev-libs/glib/glib-2.84.4-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2025 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -52,7 +52,10 @@ RDEPEND=" elf? ( virtual/libelf:0= ) sysprof? ( >=dev-util/sysprof-capture-3.40.1:4[${MULTILIB_USEDEP}] ) " -DEPEND="${RDEPEND}" +DEPEND=" + ${RDEPEND} + systemtap? ( >=dev-debug/systemtap-1.3 ) +" # libxml2 used for optional tests that get automatically skipped BDEPEND=" app-text/docbook-xsl-stylesheets @@ -356,13 +359,12 @@ multilib_src_configure() { ) # Workaround for bug #938302 - if use systemtap && has_version "dev-debug/systemtap[-dtrace-symlink(+)]" ; then - local native_file="${T}"/meson.${CHOST}.ini.local - cat >> ${native_file} <<-EOF || die + if use systemtap; then + tc-export CC + meson_add_machine_file dtrace <<-EOF [binaries] dtrace='stap-dtrace' EOF - emesonargs+=( --native-file "${native_file}" ) fi meson_src_configure diff --git a/dev-libs/glib/glib-2.84.4.ebuild b/dev-libs/glib/glib-2.84.4.ebuild index 70f333647b66..ffd13bd1f740 100644 --- a/dev-libs/glib/glib-2.84.4.ebuild +++ b/dev-libs/glib/glib-2.84.4.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2025 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -52,7 +52,10 @@ RDEPEND=" elf? ( virtual/libelf:0= ) sysprof? ( >=dev-util/sysprof-capture-3.40.1:4[${MULTILIB_USEDEP}] ) " -DEPEND="${RDEPEND}" +DEPEND=" + ${RDEPEND} + systemtap? ( >=dev-debug/systemtap-1.3 ) +" # libxml2 used for optional tests that get automatically skipped BDEPEND=" app-text/docbook-xsl-stylesheets @@ -352,13 +355,12 @@ multilib_src_configure() { ) # Workaround for bug #938302 - if use systemtap && has_version "dev-debug/systemtap[-dtrace-symlink(+)]" ; then - local native_file="${T}"/meson.${CHOST}.ini.local - cat >> ${native_file} <<-EOF || die + if use systemtap; then + tc-export CC + meson_add_machine_file dtrace <<-EOF [binaries] dtrace='stap-dtrace' EOF - emesonargs+=( --native-file "${native_file}" ) fi meson_src_configure diff --git a/dev-libs/glib/glib-2.86.1.ebuild b/dev-libs/glib/glib-2.86.1.ebuild index dad63c11782c..146e98bef777 100644 --- a/dev-libs/glib/glib-2.86.1.ebuild +++ b/dev-libs/glib/glib-2.86.1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2025 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -52,7 +52,10 @@ RDEPEND=" elf? ( virtual/libelf:0= ) sysprof? ( >=dev-util/sysprof-capture-3.40.1:4[${MULTILIB_USEDEP}] ) " -DEPEND="${RDEPEND}" +DEPEND=" + ${RDEPEND} + systemtap? ( >=dev-debug/systemtap-1.3 ) +" # libxml2 used for optional tests that get automatically skipped BDEPEND=" app-text/docbook-xsl-stylesheets @@ -352,13 +355,12 @@ multilib_src_configure() { ) # Workaround for bug #938302 - if use systemtap && has_version "dev-debug/systemtap[-dtrace-symlink(+)]" ; then - local native_file="${T}"/meson.${CHOST}.ini.local - cat >> ${native_file} <<-EOF || die + if use systemtap; then + tc-export CC + meson_add_machine_file dtrace <<-EOF [binaries] dtrace='stap-dtrace' EOF - emesonargs+=( --native-file "${native_file}" ) fi meson_src_configure
