summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys-devel/binutils-config/binutils-config-5-r2.ebuild (renamed from sys-devel/binutils-config/binutils-config-5-r1.ebuild)0
-rwxr-xr-xsys-devel/binutils-config/files/binutils-config-511
2 files changed, 10 insertions, 1 deletions
diff --git a/sys-devel/binutils-config/binutils-config-5-r1.ebuild b/sys-devel/binutils-config/binutils-config-5-r2.ebuild
index f3a4c32a1ee2..f3a4c32a1ee2 100644
--- a/sys-devel/binutils-config/binutils-config-5-r1.ebuild
+++ b/sys-devel/binutils-config/binutils-config-5-r2.ebuild
diff --git a/sys-devel/binutils-config/files/binutils-config-5 b/sys-devel/binutils-config/files/binutils-config-5
index 86f6abc8b273..2bdd07e1fcc0 100755
--- a/sys-devel/binutils-config/files/binutils-config-5
+++ b/sys-devel/binutils-config/files/binutils-config-5
@@ -149,7 +149,16 @@ switch_profile() {
mkdir -p "${dstlib}"
rm -rf "${ROOT}/${BINPATH_LINKS}"/ldscripts
atomic_ln "${LIBPATH}/ldscripts" "${dstlib}" "ldscripts"
- find -L "${dstlib}" -xtype l -name 'lib*' -exec rm -f {} +
+ find -L "${dstlib}" -xtype l -name 'lib*' -delete
+ # Detect older binutils w/broken rpaths. #562460
+ # We can hardcode the "/lib" part since that's what the binutils
+ # configure scripts have. They did not include any other path.
+ if [[ $(scanelf -qF '%r#F' "${ROOT}/${BINPATH}/as") == */lib ]] ; then
+ ewarn "Old cross-binutils detected; please re-emerge to fix (see bug #562460)."
+ for x in lib* ; do
+ atomic_ln "${LIBPATH}/${x}" "${dstlib}" "${x}"
+ done
+ fi
#
# Clean out old generated include symlinks