diff options
author | Mike Frysinger <vapier@gentoo.org> | 2013-01-12 16:53:56 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2013-01-12 16:53:56 +0000 |
commit | 4f198fd8777ba79537ea0640d0f763f655d03a4a (patch) | |
tree | 3bf45818a7f2a3dfcb598b6f142493f9b53c0681 /eclass | |
parent | add -j1 to the make install phase for bug #451500 (diff) | |
download | gentoo-2-4f198fd8777ba79537ea0640d0f763f655d03a4a.tar.gz gentoo-2-4f198fd8777ba79537ea0640d0f763f655d03a4a.tar.bz2 gentoo-2-4f198fd8777ba79537ea0640d0f763f655d03a4a.zip |
rewrite linker scripts and symlinks too when moving lib32
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/emul-linux-x86.eclass | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/eclass/emul-linux-x86.eclass b/eclass/emul-linux-x86.eclass index 91a02380d9f1..e0130aa0f5da 100644 --- a/eclass/emul-linux-x86.eclass +++ b/eclass/emul-linux-x86.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/emul-linux-x86.eclass,v 1.15 2012/11/25 07:19:51 pacho Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/emul-linux-x86.eclass,v 1.16 2013/01/12 16:53:56 vapier Exp $ # # Original Author: Mike Doty <kingtaco@gentoo.org> @@ -85,5 +85,21 @@ emul-linux-x86_src_install() { if [[ -d ${D}/lib32 ]] ; then mv "${D}"/lib32 "${D}"/${x86_libdir} || die fi + + pushd "${D}"/usr/${x86_libdir} >/dev/null + + # Fix linker script paths. + sed -i \ + -e "s:/lib32/:/${x86_libdir}/:" \ + $(grep -ls '^GROUP.*/lib32/' *.so) || die + + # Rewrite symlinks (if need be). + local sym tgt + while read sym ; do + tgt=$(readlink "${sym}") + ln -sf "${tgt/lib32/${x86_libdir}}" "${sym}" || die + done < <(find -xtype l) + + popd >/dev/null fi } |