diff options
author | Mike Frysinger <vapier@gentoo.org> | 2015-04-13 05:38:17 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2015-04-13 05:38:17 +0000 |
commit | b959fb6c158d4727e85472b3a50af5af3f719972 (patch) | |
tree | 5bafe71ea081c69f2f28dfc0f1595041fbe5fc04 /eclass | |
parent | Use SSHD_CONFIG everywhere #546008 by Alexander Sulfrian. (diff) | |
download | gentoo-2-b959fb6c158d4727e85472b3a50af5af3f719972.tar.gz gentoo-2-b959fb6c158d4727e85472b3a50af5af3f719972.tar.bz2 gentoo-2-b959fb6c158d4727e85472b3a50af5af3f719972.zip |
tc-ld-disable-gold: handle LD having flags appended to it #545218
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/toolchain-funcs.eclass | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass index 4100a00d6f9b..387412c601e9 100644 --- a/eclass/toolchain-funcs.eclass +++ b/eclass/toolchain-funcs.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.136 2015/03/31 04:27:29 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.137 2015/04/13 05:38:17 vapier Exp $ # @ECLASS: toolchain-funcs.eclass # @MAINTAINER: @@ -352,7 +352,10 @@ tc-ld-disable-gold() { ewarn "Forcing usage of the BFD linker instead of GOLD" # Set up LD to point directly to bfd if it's available. - local bfd_ld="$(tc-getLD "$@").bfd" + # We need to extract the first word in case there are flags appended + # to its value (like multilib). #545218 + local ld=$(tc-getLD "$@") + local bfd_ld="${ld%% *}.bfd" local path_ld=$(which "${bfd_ld}" 2>/dev/null) [[ -e ${path_ld} ]] && export LD=${bfd_ld} |