summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2007-12-27 19:01:06 +0000
committerMike Frysinger <vapier@gentoo.org>2007-12-27 19:01:06 +0000
commit3b5e199eadc9ba658e3f7a49662420c461fef7e7 (patch)
treebd8bb544f5c04bec650eff3c345045b27f05d7df /sys-devel/gcc-config
parentVersion bump (diff)
downloadgentoo-2-3b5e199eadc9ba658e3f7a49662420c461fef7e7.tar.gz
gentoo-2-3b5e199eadc9ba658e3f7a49662420c461fef7e7.tar.bz2
gentoo-2-3b5e199eadc9ba658e3f7a49662420c461fef7e7.zip
Fix fallback CHOST detection when python is broken #203387 by Ambroz BIzjak.
(Portage version: 2.1.4_rc11)
Diffstat (limited to 'sys-devel/gcc-config')
-rw-r--r--sys-devel/gcc-config/ChangeLog5
-rwxr-xr-xsys-devel/gcc-config/files/gcc-config-1.4.06
2 files changed, 7 insertions, 4 deletions
diff --git a/sys-devel/gcc-config/ChangeLog b/sys-devel/gcc-config/ChangeLog
index d1e701be36ca..d539bc3290a8 100644
--- a/sys-devel/gcc-config/ChangeLog
+++ b/sys-devel/gcc-config/ChangeLog
@@ -1,6 +1,9 @@
# ChangeLog for sys-devel/gcc-config
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.168 2007/10/11 05:27:56 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.169 2007/12/27 19:01:05 vapier Exp $
+
+ 27 Dec 2007; Mike Frysinger <vapier@gentoo.org> files/gcc-config-1.4.0:
+ Fix fallback CHOST detection when python is broken #203387 by Ambroz BIzjak.
*gcc-config-1.4.0-r4 (11 Oct 2007)
diff --git a/sys-devel/gcc-config/files/gcc-config-1.4.0 b/sys-devel/gcc-config/files/gcc-config-1.4.0
index e9dfe5d9dcbb..65a22dfbcf8c 100755
--- a/sys-devel/gcc-config/files/gcc-config-1.4.0
+++ b/sys-devel/gcc-config/files/gcc-config-1.4.0
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.4.0,v 1.23 2007/10/11 05:27:57 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.4.0,v 1.24 2007/12/27 19:01:06 vapier Exp $
trap ":" INT QUIT TSTP
@@ -54,7 +54,7 @@ try_real_hard_to_find_CHOST() {
# First we read make.conf
#
- local varname=$1
+ local varname=${1:-CHOST}
local conf=${ROOT}/etc/make.conf
local ret=$(source "${conf}" 2>/dev/null ; echo ${!varname})
if [[ -z ${ret} ]] ; then
@@ -63,7 +63,7 @@ try_real_hard_to_find_CHOST() {
ret=$(eval $(
sed -n \
-e 's:[[:space:]]::g' \
- -e '/^CHOST=/p' \
+ -e "/^${varname}=/p" \
"${conf}"
) ; echo ${!varname}
)