diff options
author | Kevin F. Quinn <kevquinn@gentoo.org> | 2006-03-28 21:25:14 +0000 |
---|---|---|
committer | Kevin F. Quinn <kevquinn@gentoo.org> | 2006-03-28 21:25:14 +0000 |
commit | ef13f6e79358c25c14235bbffcbc818406cdbee5 (patch) | |
tree | 72eafc97f31e5a3a2b72c11211484dc588a073ba /eclass | |
parent | Apply sed from Ed Catmur so that apmd compiles against system headers, instea... (diff) | |
download | gentoo-2-ef13f6e79358c25c14235bbffcbc818406cdbee5.tar.gz gentoo-2-ef13f6e79358c25c14235bbffcbc818406cdbee5.tar.bz2 gentoo-2-ef13f6e79358c25c14235bbffcbc818406cdbee5.zip |
Make gcc-specs-directive work on non-English locales, bug #127742
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/toolchain-funcs.eclass | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass index 5b16e61c4a81..e143b2068838 100644 --- a/eclass/toolchain-funcs.eclass +++ b/eclass/toolchain-funcs.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.56 2006/02/17 22:18:20 swegener Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.57 2006/03/28 21:25:14 kevquinn Exp $ # # Author: Toolchain Ninjas <toolchain@gentoo.org> # @@ -197,8 +197,9 @@ gcc-micro-version() { # gcc -dumpspecs is parsed first, followed by files listed by "gcc -v" # as "Reading <file>", in order. gcc-specs-directive() { - local specfiles=$($(tc-getCC) -v 2>&1 | awk '$1=="Reading" {print $NF}') - $(tc-getCC) -dumpspecs 2> /dev/null | cat - ${specfiles} | awk -v directive=$1 \ + local cc=$(tc-getCC) + local specfiles=$(LC_ALL=C ${cc} -v 2>&1 | awk '$1=="Reading" {print $NF}') + ${cc} -dumpspecs 2> /dev/null | cat - ${specfiles} | awk -v directive=$1 \ 'BEGIN { pspec=""; spec=""; outside=1 } $1=="*"directive":" { pspec=spec; spec=""; outside=0; next } outside || NF==0 || ( substr($1,1,1)=="*" && substr($1,length($1),1)==":" ) { outside=1; next } |