diff options
author | Jeremy Huddleston <eradicator@gentoo.org> | 2005-03-10 22:43:11 +0000 |
---|---|---|
committer | Jeremy Huddleston <eradicator@gentoo.org> | 2005-03-10 22:43:11 +0000 |
commit | 2b162a48465af71e93fc58aa5f1ade32a4f41717 (patch) | |
tree | 9710d7154ae5641309f8f1b1d62e7ceb63af932e /eclass/toolchain-funcs.eclass | |
parent | More a11y stuff for Gnome 2.10 (diff) | |
download | historical-2b162a48465af71e93fc58aa5f1ade32a4f41717.tar.gz historical-2b162a48465af71e93fc58aa5f1ade32a4f41717.tar.bz2 historical-2b162a48465af71e93fc58aa5f1ade32a4f41717.zip |
Add support for using get_abi_CHOST as a prefix before CHOST.
Diffstat (limited to 'eclass/toolchain-funcs.eclass')
-rw-r--r-- | eclass/toolchain-funcs.eclass | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass index 4c0df182dd81..4357651aba5c 100644 --- a/eclass/toolchain-funcs.eclass +++ b/eclass/toolchain-funcs.eclass @@ -1,12 +1,14 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.33 2005/03/04 13:46:55 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.34 2005/03/10 22:43:11 eradicator Exp $ # # Author: Toolchain Ninjas <ninjas@gentoo.org> # # This eclass contains (or should) functions to get common info # about the toolchain (libc/compiler/binutils/etc...) +inherit multilib + ECLASS=toolchain-funcs INHERITED="$INHERITED $ECLASS" @@ -21,11 +23,12 @@ tc-getPROG() { return 0 fi - if [[ -n $3 ]] ; then - local search=$(type -p "$3-${prog}") - [[ -n ${search} ]] && prog=${search##*/} - elif [[ -n ${CHOST} ]] ; then - local search=$(type -p "${CHOST}-${prog}") + local chost=$3 + [[ -z ${chost} ]] && chost=$(get_abi_CHOST) + [[ -z ${chost} ]] && chost=${CHOST} + + if [[ -n ${chost} ]] ; then + local search=$(type -p "${chost}-${prog}") [[ -n ${search} ]] && prog=${search##*/} fi |