From 629fb0560bffdf39a923c6ee794eddfb815db579 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Fri, 18 Oct 2019 07:46:54 +0100 Subject: [PATCH] sys-libs/glibc: avoid RESTRICT=strip and use 'dostrip -x /' RESTRICT=strip + 'dostrip /' does not have a desired effect of enabling (possibly selective) stripping in portage: https://bugs.gentoo.org/697960 Workaround it by using 'if foo && dostrip -x /' instead of RESTRICT=strip + 'if foo || dostrip /'. Reported-by: Arfrever Frehtes Taifersar Arahesis Fixed-by: Arfrever Frehtes Taifersar Arahesis Package-Manager: Portage-2.3.76, Repoman-2.3.17 Signed-off-by: Sergei Trofimovich --- sys-libs/glibc/glibc-9999.ebuild | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys-libs/glibc/glibc-9999.ebuild b/sys-libs/glibc/glibc-9999.ebuild index d1ad8e513fbb..08a4eba83b3e 100644 --- a/sys-libs/glibc/glibc-9999.ebuild +++ b/sys-libs/glibc/glibc-9999.ebuild @@ -80,7 +80,6 @@ fi # losing it's '.symtab' entries. # As Gentoo's strip does not allow us to pass less aggressive stripping # options and does not check the machine target we strip selectively. -RESTRICT=strip # We need a new-enough binutils/gcc to match upstream baseline. # Also we need to make sure our binutils/gcc supports TLS, @@ -1204,7 +1203,7 @@ glibc_do_src_install() { # Avoid stripping binaries not targeted by ${CHOST}. Or else # ${CHOST}-strip would break binaries build for ${CTARGET}. - is_crosscompile || dostrip / + is_crosscompile && dostrip -x / # gdb thread introspection relies on local libpthreas symbols. stripping breaks it # See Note [Disable automatic stripping] dostrip -x $(alt_libdir)/libpthread-${upstream_pv}.so -- 2.26.2