commit:     08794e8f284e2f5555493a0e4061c294d0089ba9
Author:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 30 23:29:10 2024 +0000
Commit:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Wed Jan  1 10:06:03 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=08794e8f

toolchain.eclass: Fix strip exclusion for prefixed cross-compilers

dostrip limitations mean that we cannot strip the CTARGET binaries in a
cross-compiler. There is already a `dostrip -x` call to exclude such
binaries from stripping, but it expects the argument to be unprefixed,
and the argument given was prefixed.

Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>

 eclass/toolchain.eclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index 602f99437145..c605c437f355 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2024 Gentoo Authors
+# Copyright 1999-2025 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 # @ECLASS: toolchain.eclass
@@ -2641,7 +2641,7 @@ toolchain_src_install() {
        #  - "${D}${LIBPATH}"
        # As dostrip does not specify host to override ${CHOST} tools just skip
        # non-native binary stripping.
-       is_crosscompile && dostrip -x "${LIBPATH}"
+       is_crosscompile && dostrip -x "${LIBPATH#"${EPREFIX}"}"
 
        cd "${S}" || die
        if is_crosscompile; then

Reply via email to