From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([69.77.167.62] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1LaefQ-0001im-3B for garchives@archives.gentoo.org; Fri, 20 Feb 2009 23:20:24 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 94E66E03C9; Fri, 20 Feb 2009 23:20:23 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 524E6E03C9 for ; Fri, 20 Feb 2009 23:20:23 +0000 (UTC) Received: from stork.gentoo.org (stork.gentoo.org [64.127.104.133]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id C7FF4B66F9 for ; Fri, 20 Feb 2009 23:20:22 +0000 (UTC) Received: from vapier by stork.gentoo.org with local (Exim 4.69) (envelope-from ) id 1LaefO-0001d5-Fl for gentoo-commits@lists.gentoo.org; Fri, 20 Feb 2009 23:20:22 +0000 From: "Mike Frysinger (vapier)" To: gentoo-commits@lists.gentoo.org Reply-To: gentoo-dev@lists.gentoo.org, vapier@gentoo.org Subject: [gentoo-commits] gentoo-x86 commit in eclass: multilib.eclass X-VCS-Repository: gentoo-x86 X-VCS-Files: multilib.eclass X-VCS-Directories: eclass X-VCS-Committer: vapier X-VCS-Committer-Name: Mike Frysinger Content-Type: text/plain; charset=utf8 Message-Id: Sender: Mike Frysinger Date: Fri, 20 Feb 2009 23:20:22 +0000 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: b9cf52de-6b15-4aab-a5e3-33a360fdef8d X-Archives-Hash: 507b1b72d8771d1dd98bd6533dda833f vapier 09/02/20 23:20:22 Modified: multilib.eclass Log: set each component explicitly and avoid requiring magic gcc-config beha= vior Revision Changes Path 1.72 eclass/multilib.eclass file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/multilib.ec= lass?rev=3D1.72&view=3Dmarkup plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/multilib.ec= lass?rev=3D1.72&content-type=3Dtext/plain diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/multilib.ec= lass?r1=3D1.71&r2=3D1.72 Index: multilib.eclass =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /var/cvsroot/gentoo-x86/eclass/multilib.eclass,v retrieving revision 1.71 retrieving revision 1.72 diff -u -r1.71 -r1.72 --- multilib.eclass 9 Feb 2009 19:53:14 -0000 1.71 +++ multilib.eclass 20 Feb 2009 23:20:22 -0000 1.72 @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/multilib.eclass,v 1.71 2009/02= /09 19:53:14 maekke Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/multilib.eclass,v 1.72 2009/02= /20 23:20:22 vapier Exp $ =20 # @ECLASS: multilib.eclass # @MAINTAINER: @@ -649,29 +649,34 @@ # Hide multilib details here for packages which are forced to be compile= d for a # specific ABI when run on another ABI (like x86-specific packages on am= d64) multilib_toolchain_setup() { + local v vv + export ABI=3D$1 =20 - # disable ccache for non-native builds #196243. this is because how - # we cram ABI related CFLAGS behind the back of the gcc frontend with - # the gcc-config wrapper. + # We want to avoid the behind-the-back magic of gcc-config as it + # screws up ccache and distcc. See #196243 for more info. if [[ ${ABI} !=3D ${DEFAULT_ABI} ]] ; then - : ${CCACHE_DISABLE:=3Dmultilib-disable} - else - if [[ ${CCACHE_DISABLE} =3D=3D "multilib-disable" ]] ; then - unset CCACHE_DISABLE + if [[ ${DEFAULT_ABI_SAVED} !=3D "true" ]] ; then + for v in CHOST CBUILD AS CC CXX LD ; do + export __abi_saved_${v}=3D"${!v}" + done + export DEFAULT_ABI_SAVED=3D"true" fi - fi - export CCACHE_DISABLE - - if has_version app-admin/eselect-compiler ; then - # Binutils doesn't have wrappers for ld and as (yet). Eventually it - # will, and all this can just be handled with CHOST. - export LD=3D"ld $(get_abi_LDFLAGS $1)" - export AS=3D"as $(get_abi_ASFLAGS $1)" =20 + # Set the CHOST native first so that we pick up the native + # toolchain and not a cross-compiler by accident #202811. + export CHOST=3D$(get_abi_CHOST ${DEFAULT_ABI}) + export AS=3D"$(tc-getAS) $(get_abi_ASFLAGS)" + export CC=3D"$(tc-getCC) $(get_abi_CFLAGS)" + export CXX=3D"$(tc-getCXX) $(get_abi_CFLAGS)" + export LD=3D"$(tc-getLD) $(get_abi_LDFLAGS)" export CHOST=3D$(get_abi_CHOST $1) export CBUILD=3D$(get_abi_CHOST $1) - else - tc-export CC + + elif [[ ${DEFAULT_ABI_SAVED} =3D=3D "true" ]] ; then + for v in CHOST CBUILD AS CC CXX LD ; do + vv=3D"__abi_saved_${v}" + export ${v}=3D${!vv} + done fi }