From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1R8F35-0005wL-3N for garchives@archives.gentoo.org; Mon, 26 Sep 2011 17:32:59 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id EBEB221C0AD; Mon, 26 Sep 2011 17:32:46 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id AE0F121C0AD for ; Mon, 26 Sep 2011 17:32:46 +0000 (UTC) Received: from flycatcher.gentoo.org (flycatcher.gentoo.org [81.93.255.6]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id F26BD1B4001 for ; Mon, 26 Sep 2011 17:32:45 +0000 (UTC) Received: by flycatcher.gentoo.org (Postfix, from userid 559) id C1D6F2004C; Mon, 26 Sep 2011 17:32:44 +0000 (UTC) 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: toolchain.eclass X-VCS-Repository: gentoo-x86 X-VCS-Files: toolchain.eclass X-VCS-Directories: eclass X-VCS-Committer: vapier X-VCS-Committer-Name: Mike Frysinger Content-Type: text/plain; charset=utf8 Message-Id: <20110926173244.C1D6F2004C@flycatcher.gentoo.org> Date: Mon, 26 Sep 2011 17:32:44 +0000 (UTC) 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: X-Archives-Hash: 27c21888b25634a5212e3db16fb19565 vapier 11/09/26 17:32:44 Modified: toolchain.eclass Log: scrub more ETYPE logic Revision Changes Path 1.470 eclass/toolchain.eclass file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/toolchain.e= class?rev=3D1.470&view=3Dmarkup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/toolchain.e= class?rev=3D1.470&content-type=3Dtext/plain diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/toolchain.e= class?r1=3D1.469&r2=3D1.470 Index: toolchain.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/toolchain.eclass,v retrieving revision 1.469 retrieving revision 1.470 diff -u -r1.469 -r1.470 --- toolchain.eclass 22 Sep 2011 23:08:28 -0000 1.469 +++ toolchain.eclass 26 Sep 2011 17:32:44 -0000 1.470 @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.469 2011/= 09/22 23:08:28 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.470 2011/= 09/26 17:32:44 vapier Exp $ # # Maintainer: Toolchain Ninjas =20 @@ -719,25 +719,21 @@ =20 #---->> pkg_* <<---- toolchain_pkg_setup() { - [[ -z ${ETYPE} ]] && die "Your ebuild needs to set the ETYPE variable" - - if [[ ${ETYPE} =3D=3D "gcc-compiler" ]] ; then - # Setup variables which would normally be in the profile - if is_crosscompile ; then - multilib_env ${CTARGET} - if ! is_multilib ; then - MULTILIB_ABIS=3D${DEFAULT_ABI} - fi + # Setup variables which would normally be in the profile + if is_crosscompile ; then + multilib_env ${CTARGET} + if ! is_multilib ; then + MULTILIB_ABIS=3D${DEFAULT_ABI} fi + fi =20 - # we dont want to use the installed compiler's specs to build gcc! - unset GCC_SPECS + # we dont want to use the installed compiler's specs to build gcc! + unset GCC_SPECS =20 - if use nocxx ; then - use go && ewarn 'Go requires a C++ compiler, disabled due to USE=3D"n= ocxx"' - use objc++ && ewarn 'Obj-C++ requires a C++ compiler, disabled due to= USE=3D"nocxx"' - use gcj && ewarn 'GCJ requires a C++ compiler, disabled due to USE=3D= "nocxx"' - fi + if use nocxx ; then + use go && ewarn 'Go requires a C++ compiler, disabled due to USE=3D"no= cxx"' + use objc++ && ewarn 'Obj-C++ requires a C++ compiler, disabled due to = USE=3D"nocxx"' + use gcj && ewarn 'GCJ requires a C++ compiler, disabled due to USE=3D"= nocxx"' fi =20 want_libssp && libc_has_ssp && \ @@ -847,36 +843,6 @@ =20 #---->> src_* <<---- =20 -# generic GCC src_unpack, to be called from the ebuild's src_unpack. -# BIG NOTE regarding hardened support: ebuilds with support for hardened= are -# expected to export the following variable: -# -# HARDENED_GCC_WORKS -# This variable should be set to the archs on which hardened should -# be allowed. For example: HARDENED_GCC_WORKS=3D"x86 sparc amd64" -# This allows for additional archs to be supported by hardened when -# ready. -# -# Travis Tilley (03 Sep 2004) -# -gcc-compiler_src_unpack() { - # fail if using pie patches, building hardened, and glibc doesnt have - # the necessary support - want_pie && use hardened && glibc_have_pie - - if use hardened ; then - einfo "updating configuration to build hardened GCC" - make_gcc_hard || die "failed to make gcc hard" - fi - - if is_libffi ; then - # move the libffi target out of gcj and into all - sed -i \ - -e '/^libgcj=3D/s:target-libffi::' \ - -e '/^target_lib/s:=3D":=3D"target-libffi :' \ - "${S}"/configure || die - fi -} guess_patch_type_in_dir() { [[ -n $(ls "$1"/*.bz2 2>/dev/null) ]] \ && EPATCH_SUFFIX=3D"patch.bz2" \ @@ -944,7 +910,22 @@ do_gcc_PIE_patches epatch_user =20 - ${ETYPE}_src_unpack || die "failed to ${ETYPE}_src_unpack" + # fail if using pie patches, building hardened, and glibc doesnt have + # the necessary support + want_pie && use hardened && glibc_have_pie + + if use hardened ; then + einfo "updating configuration to build hardened GCC" + make_gcc_hard || die "failed to make gcc hard" + fi + + if is_libffi ; then + # move the libffi target out of gcj and into all + sed -i \ + -e '/^libgcj=3D/s:target-libffi::' \ + -e '/^target_lib/s:=3D":=3D"target-libffi :' \ + "${S}"/configure || die + fi =20 # protoize don't build on FreeBSD, skip it ## removed in 4.5, bug #270558 --de. @@ -1298,9 +1279,7 @@ --disable-werror \ --enable-secureplt" =20 - # etype specific configuration - einfo "running ${ETYPE}-configure" - ${ETYPE}-configure || die + gcc-compiler-configure || die =20 # if not specified, assume we are building for a target that only # requires C support @@ -1617,7 +1596,7 @@ =20 # Do not create multiple specs files for PIE+SSP if boundschecking is i= n # USE, as we disable PIE+SSP when it is. - if [[ ${ETYPE} =3D=3D "gcc-compiler" ]] && want_split_specs && ! want_m= inispecs; then + if want_split_specs && ! want_minispecs; then split_out_specs_files || die "failed to split out specs" fi =20