summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2005-11-18 03:59:31 +0000
committerMike Frysinger <vapier@gentoo.org>2005-11-18 03:59:31 +0000
commite842e626373f0058eca027e13d521c30eda23606 (patch)
tree8bb3e42333eaf3042c4113cab705fc481517aa71 /eclass/toolchain.eclass
parentadd an unpack function for 2.6 headers, unify duplicated env setups into one ... (diff)
downloadhistorical-e842e626373f0058eca027e13d521c30eda23606.tar.gz
historical-e842e626373f0058eca027e13d521c30eda23606.tar.bz2
historical-e842e626373f0058eca027e13d521c30eda23606.zip
add support for USE=mudflap (gcc4+), remove the cross-compile multilib hack for mips targets, and support building bootstrap C compiler with libc/kernel headers
Diffstat (limited to 'eclass/toolchain.eclass')
-rw-r--r--eclass/toolchain.eclass19
1 files changed, 11 insertions, 8 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index 508e5d6ef943..0d8bfb37f6b7 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.218 2005/11/16 05:21:35 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.219 2005/11/18 03:59:31 vapier Exp $
HOMEPAGE="http://www.gnu.org/software/gcc/gcc.html"
LICENSE="GPL-2 LGPL-2.1"
@@ -126,7 +126,7 @@ if [[ ${ETYPE} == "gcc-library" ]] ; then
IUSE="nls build"
SLOT="${CTARGET}-${SO_VERSION_SLOT:-5}"
else
- IUSE="altivec bootstrap build fortran gcj gtk hardened ip28 multilib multislot n32 n64 nls nocxx objc objc-gc vanilla"
+ IUSE="altivec bootstrap build fortran gcj gtk hardened ip28 multilib multislot n32 n64 nls nocxx objc objc-gc vanilla mudflap"
[[ -n ${PIE_VER} ]] && IUSE="${IUSE} nopie"
[[ -n ${PP_VER} ]] && IUSE="${IUSE} nossp"
[[ -n ${HTB_VER} ]] && IUSE="${IUSE} boundschecking"
@@ -1047,6 +1047,8 @@ gcc-compiler-configure() {
confgcc="${confgcc} --disable-multilib"
fi
+ confgcc="${confgcc} $(use_enable mudflap libmudflap)"
+
# GTK+ is preferred over xlib in 3.4.x (xlib is unmaintained
# right now). Much thanks to <csm@gnu.org> for the heads up.
# Travis Tilley <lv@gentoo.org> (11 Jul 2004)
@@ -1059,9 +1061,9 @@ gcc-compiler-configure() {
case $(tc-arch) in
# Add --with-abi flags to enable respective MIPS ABIs
mips)
- if is_crosscompile && is_multilib; then
+ if is_multilib; then
confgcc="${confgcc} --with-abi=32 --with-abi=64 --with-abi=n32"
- else
+ elif ! is_crosscompile ; then
is_multilib && confgcc="${confgcc} --with-abi=32"
use n64 && confgcc="${confgcc} --with-abi=64"
use n32 && confgcc="${confgcc} --with-abi=n32"
@@ -1176,9 +1178,10 @@ gcc_do_configure() {
avr) confgcc="${confgcc} --enable-shared --disable-threads";;
esac
if [[ -n ${needed_libc} ]] ; then
- if ! has_version ${CATEGORY}/${needed_libc} && \
- ! has_version ${CATEGORY}/${needed_libc}-headers ; then
- confgcc="${confgcc} --disable-shared --disable-threads --without-headers --disable-libmudflap"
+ if ! has_version ${CATEGORY}/${needed_libc} ; then
+ confgcc="${confgcc} --disable-shared --disable-threads --without-headers"
+ elif built_with_use ${CATEGORY}/${needed_libc} _E_CROSS_HEADERS_ONLY ; then
+ confgcc="${confgcc} --disable-shared --with-sysroot=${PREFIX}/${CTARGET}"
else
confgcc="${confgcc} --with-sysroot=${PREFIX}/${CTARGET}"
fi
@@ -1534,7 +1537,7 @@ gcc-compiler_src_install() {
fi
# Move the libraries to the proper location
- gcc_movelibs &> /dev/null
+ gcc_movelibs
# Make sure we dont have stuff lying around that
# can nuke multiple versions of gcc