summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-03-28 11:09:27 +0000
committerMike Frysinger <vapier@gentoo.org>2009-03-28 11:09:27 +0000
commit3ae3d18e30751f9ab0608d9515b983e635141330 (patch)
tree275ff2f71091c3c8c766a94c8fcae53e862e8e19 /eclass
parentVersion bump to 1.2.5, removed 1.2.4. (diff)
downloadgentoo-2-3ae3d18e30751f9ab0608d9515b983e635141330.tar.gz
gentoo-2-3ae3d18e30751f9ab0608d9515b983e635141330.tar.bz2
gentoo-2-3ae3d18e30751f9ab0608d9515b983e635141330.zip
support funk SONAMEs like libfoo.so -> libfoo-0.1.so
Diffstat (limited to 'eclass')
-rw-r--r--eclass/toolchain-funcs.eclass8
1 files changed, 6 insertions, 2 deletions
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass
index 4cd5cc6769c7..ca690cf97a0f 100644
--- a/eclass/toolchain-funcs.eclass
+++ b/eclass/toolchain-funcs.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.87 2009/03/01 08:09:44 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.88 2009/03/28 11:09:27 vapier Exp $
# @ECLASS: toolchain-funcs.eclass
# @MAINTAINER:
@@ -426,8 +426,12 @@ gen_usr_ldscript() {
local tlib
if ${auto} ; then
lib="lib${lib}${suffix}"
+ tlib=$(scanelf -qF'%S#F' "${D}"/usr/${libdir}/${lib})
mv "${D}"/usr/${libdir}/${lib}* "${D}"/${libdir}/ || die
- tlib=$(scanelf -qF'%S#F' "${D}"/${libdir}/${lib})
+ # some SONAMEs are funky: they encode a version before the .so
+ if [[ ${tlib} != ${lib}* ]] ; then
+ mv "${D}"/usr/${libdir}/${tlib}* "${D}"/${libdir}/ || die
+ fi
[[ -z ${tlib} ]] && die "unable to read SONAME from ${lib}"
rm -f "${D}"/${libdir}/${lib}
else