diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass index 4559894ca04a2..8fef764ad5973 100644 --- a/eclass/toolchain-funcs.eclass +++ b/eclass/toolchain-funcs.eclass @@ -534,10 +534,9 @@ tc-ld-force-bfd() { ewarn "Forcing usage of the BFD linker" # Set up LD to point directly to bfd if it's available. - local ld=$(tc-getLD "$@") - # We need to extract the first word in case there are flags appended - # to its value (like multilib), bug #545218. - local bfd_ld="${ld%% *}.bfd" + # Unset LD first so we get the default value from tc-getLD. + local ld=$(unset LD; tc-getLD "$@") + local bfd_ld="${ld}.bfd" local path_ld=$(type -P "${bfd_ld}" 2>/dev/null) [[ -e ${path_ld} ]] && export LD=${bfd_ld} diff --git a/sys-libs/db/db-4.8.30-r8.ebuild b/sys-libs/db/db-4.8.30-r8.ebuild index f5906a0c970e8..7d3883eeb3603 100644 --- a/sys-libs/db/db-4.8.30-r8.ebuild +++ b/sys-libs/db/db-4.8.30-r8.ebuild @@ -80,6 +80,12 @@ src_prepare() { -i configure || die } +src_configure() { + # Force bfd before calling multilib_toolchain_setup + tc-ld-force-bfd #470634 #729510 + multilib-minimal_src_configure +} + multilib_src_configure() { local myconf=( --enable-compat185 @@ -93,9 +99,6 @@ multilib_src_configure() { $(use_enable test) ) - # bug #470634 and bug #729510 - tc-ld-force-bfd - # compilation with -O0 fails on amd64, see bug #171231 if [[ ${ABI} == amd64 ]]; then local CFLAGS=${CFLAGS} CXXFLAGS=${CXXFLAGS} diff --git a/sys-libs/db/db-5.3.28-r9.ebuild b/sys-libs/db/db-5.3.28-r9.ebuild index 1d029d38e96b4..a86fe5ad0d1f8 100644 --- a/sys-libs/db/db-5.3.28-r9.ebuild +++ b/sys-libs/db/db-5.3.28-r9.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 EAPI=7 -inherit autotools db flag-o-matic multilib multilib-minimal toolchain-funcs +inherit autotools db flag-o-matic multilib-minimal toolchain-funcs #Number of official patches #PATCHNO=`echo ${PV}|sed -e "s,\(.*_p\)\([0-9]*\),\2,"` @@ -24,7 +24,7 @@ DESCRIPTION="Oracle Berkeley DB" HOMEPAGE="http://www.oracle.com/technetwork/database/database-technologies/berkeleydb/overview/index.html" SRC_URI="http://download.oracle.com/berkeley-db/${MY_P}.tar.gz" for (( i=1 ; i<=${PATCHNO} ; i++ )) ; do - export SRC_URI="${SRC_URI} http://www.oracle.com/technology/products/berkeley-db/db/update/${MY_PV}/patch.${MY_PV}.${i}" + SRC_URI+=" http://www.oracle.com/technology/products/berkeley-db/db/update/${MY_PV}/patch.${MY_PV}.${i}" done LICENSE="Sleepycat" @@ -111,6 +111,12 @@ src_prepare() { -i "${S_BASE}"/test/tcl/reputils.tcl || die } +src_configure() { + # Force bfd before calling multilib_toolchain_setup + tc-ld-force-bfd #470634 #729510 + multilib-minimal_src_configure +} + multilib_src_configure() { local myconf=( # sql_compat will cause a collision with sqlite3 @@ -132,8 +138,6 @@ multilib_src_configure() { $(use_enable test) ) - tc-ld-force-bfd #470634 #729510 - # compilation with -O0 fails on amd64, see bug #171231 if [[ ${ABI} == amd64 ]]; then local CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" diff --git a/sys-libs/db/db-6.0.35-r4.ebuild b/sys-libs/db/db-6.0.35-r4.ebuild index 20268a5c99966..422b7e8188a81 100644 --- a/sys-libs/db/db-6.0.35-r4.ebuild +++ b/sys-libs/db/db-6.0.35-r4.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 EAPI=7 -inherit autotools db flag-o-matic multilib multilib-minimal toolchain-funcs +inherit autotools db flag-o-matic multilib-minimal toolchain-funcs #Number of official patches #PATCHNO=`echo ${PV}|sed -e "s,\(.*_p\)\([0-9]*\),\2,"` @@ -24,7 +24,7 @@ DESCRIPTION="Oracle Berkeley DB" HOMEPAGE="http://www.oracle.com/technetwork/database/database-technologies/berkeleydb/overview/index.html" SRC_URI="http://download.oracle.com/berkeley-db/${MY_P}.tar.gz" for (( i=1 ; i<=${PATCHNO} ; i++ )) ; do - export SRC_URI="${SRC_URI} http://www.oracle.com/technology/products/berkeley-db/db/update/${MY_PV}/patch.${MY_PV}.${i}" + SRC_URI+=" http://www.oracle.com/technology/products/berkeley-db/db/update/${MY_PV}/patch.${MY_PV}.${i}" done LICENSE="AGPL-3" @@ -104,6 +104,12 @@ src_prepare() { -i "${S_BASE}"/test/tcl/reputils.tcl || die } +src_configure() { + # Force bfd before calling multilib_toolchain_setup + tc-ld-force-bfd #470634 #729510 + multilib-minimal_src_configure +} + multilib_src_configure() { local myconf=( --enable-compat185 @@ -121,8 +127,6 @@ multilib_src_configure() { $(use_enable test) ) - tc-ld-force-bfd #470634 #729510 - # compilation with -O0 fails on amd64, see bug #171231 if [[ ${ABI} == amd64 ]]; then local CFLAGS=${CFLAGS} CXXFLAGS=${CXXFLAGS}