From 0a332ebfc381b406c308baa37cde8e4b9e7573c7 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Sat, 10 Sep 2016 16:27:25 +0200 Subject: sys-devel/gcc-apple: bump to EAPI=5 and remove all conditional code from global scope, bug #593392 Package-Manager: portage-2.2.28 --- sys-devel/gcc-apple/gcc-apple-4.0.1_p5493.ebuild | 18 +++++----- sys-devel/gcc-apple/gcc-apple-4.2.1_p5664.ebuild | 39 +++++++++++----------- .../gcc-apple/gcc-apple-4.2.1_p5666-r1.ebuild | 39 +++++++++++----------- .../gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild | 39 +++++++++++----------- 4 files changed, 66 insertions(+), 69 deletions(-) (limited to 'sys-devel/gcc-apple') diff --git a/sys-devel/gcc-apple/gcc-apple-4.0.1_p5493.ebuild b/sys-devel/gcc-apple/gcc-apple-4.0.1_p5493.ebuild index 282007329d0a..fb49629428cf 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.0.1_p5493.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.0.1_p5493.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="3" +EAPI="5" inherit eutils toolchain prefix @@ -30,14 +30,6 @@ S=${WORKDIR}/gcc-${APPLE_VERS} # TPREFIX is the prefix of the CTARGET installation export TPREFIX=${TPREFIX:-${EPREFIX}} -LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} -if is_crosscompile ; then - BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} -else - BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} -fi -STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} - src_unpack() { # override toolchain.eclass func unpack ${A} @@ -68,6 +60,14 @@ src_configure() { use objc && langs="${langs},objc" use objc++ && langs="${langs/,objc/},objc,obj-c++" # need objc with objc++ + LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} + if is_crosscompile ; then + BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} + else + BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} + fi + STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} + local myconf="${myconf} \ --prefix=${EPREFIX}/usr \ --bindir=${BINPATH} \ diff --git a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5664.ebuild b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5664.ebuild index 818bc378d7c9..aaf9307382ed 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5664.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5664.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="3" +EAPI="5" inherit eutils toolchain flag-o-matic autotools prefix @@ -16,17 +16,6 @@ SRC_URI="http://www.opensource.apple.com/darwinsource/tarballs/other/gcc-${APPLE fortran? ( mirror://gnu/gcc/gcc-4.2.4/gcc-fortran-4.2.4.tar.bz2 )" LICENSE="GPL-2 GPL-3" -case ${CHOST} in - *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) - LIBSTDCXX_APPLE_VERSION=39 - ;; - *) - # pre Leopard has no dtrace, which is required by 37.11 and above - # Leopard only has 32-bits version of dtrace - LIBSTDCXX_APPLE_VERSION=16 - ;; -esac - SLOT="42" KEYWORDS="~ppc-macos ~x64-macos ~x86-macos" IUSE="fortran nls +openmp objc objc++ +cxx" @@ -50,14 +39,6 @@ S=${WORKDIR}/gcc-${APPLE_VERS} # TPREFIX is the prefix of the CTARGET installation export TPREFIX=${TPREFIX:-${EPREFIX}} -LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} -if is_crosscompile ; then - BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} -else - BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} -fi -STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} - src_unpack() { # override toolchain.eclass func unpack ${A} @@ -73,6 +54,16 @@ src_prepare() { fi # move in libstdc++ + case ${CHOST} in + *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) + LIBSTDCXX_APPLE_VERSION=39 + ;; + *) + # pre Leopard has no dtrace, which is required by 37.11 and above + # Leopard only has 32-bits version of dtrace + LIBSTDCXX_APPLE_VERSION=16 + ;; + esac mv "${WORKDIR}"/libstdcxx-${LIBSTDCXX_APPLE_VERSION}/libstdcxx/libstdc++-v3 . if [[ ${LIBSTDCXX_APPLE_VERSION} == 16 ]] ; then epatch "${FILESDIR}"/libstdc++-${LIBSTDCXX_APPLE_VERSION}.patch # does it apply on 37? @@ -140,6 +131,14 @@ src_configure() { use objc++ && langs="${langs/,objc/},objc,obj-c++" # need objc with objc++ use fortran && langs="${langs},fortran" + LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} + if is_crosscompile ; then + BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} + else + BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} + fi + STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} + local myconf="${myconf} \ --prefix=${EPREFIX}/usr \ --bindir=${BINPATH} \ diff --git a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r1.ebuild b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r1.ebuild index aca327a8daf9..a180a2df21b5 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r1.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r1.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="3" +EAPI="5" inherit eutils toolchain flag-o-matic autotools prefix @@ -16,17 +16,6 @@ SRC_URI="http://www.opensource.apple.com/darwinsource/tarballs/other/gcc-${APPLE fortran? ( mirror://gnu/gcc/gcc-4.2.4/gcc-fortran-4.2.4.tar.bz2 )" LICENSE="GPL-2 GPL-3" -case ${CHOST} in - *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) - LIBSTDCXX_APPLE_VERSION=39 - ;; - *) - # pre Leopard has no dtrace, which is required by 37.11 and above - # Leopard only has 32-bits version of dtrace - LIBSTDCXX_APPLE_VERSION=16 - ;; -esac - SLOT="42" KEYWORDS="~ppc-macos ~x64-macos ~x86-macos" IUSE="fortran nls +openmp objc objc++ +cxx" @@ -51,14 +40,6 @@ S=${WORKDIR}/gcc-${APPLE_VERS} # TPREFIX is the prefix of the CTARGET installation export TPREFIX=${TPREFIX:-${EPREFIX}} -LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} -if is_crosscompile ; then - BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} -else - BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} -fi -STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} - src_unpack() { # override toolchain.eclass func unpack ${A} @@ -74,6 +55,16 @@ src_prepare() { fi # move in libstdc++ + case ${CHOST} in + *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) + LIBSTDCXX_APPLE_VERSION=39 + ;; + *) + # pre Leopard has no dtrace, which is required by 37.11 and above + # Leopard only has 32-bits version of dtrace + LIBSTDCXX_APPLE_VERSION=16 + ;; + esac mv "${WORKDIR}"/libstdcxx-${LIBSTDCXX_APPLE_VERSION}/libstdcxx/libstdc++-v3 . if [[ ${LIBSTDCXX_APPLE_VERSION} == 16 ]] ; then epatch "${FILESDIR}"/libstdc++-${LIBSTDCXX_APPLE_VERSION}.patch # does it apply on 37? @@ -152,6 +143,14 @@ src_configure() { use objc++ && langs="${langs/,objc/},objc,obj-c++" # need objc with objc++ use fortran && langs="${langs},fortran" + LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} + if is_crosscompile ; then + BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} + else + BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} + fi + STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} + local myconf="${myconf} \ --prefix=${EPREFIX}/usr \ --bindir=${BINPATH} \ diff --git a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild index 1f088b901215..3540664d68cc 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="3" +EAPI="5" inherit eutils toolchain flag-o-matic autotools prefix @@ -16,17 +16,6 @@ SRC_URI="http://www.opensource.apple.com/darwinsource/tarballs/other/gcc-${APPLE fortran? ( mirror://gnu/gcc/gcc-4.2.4/gcc-fortran-4.2.4.tar.bz2 )" LICENSE="GPL-2 GPL-3" -case ${CHOST} in - *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) - LIBSTDCXX_APPLE_VERSION=39 - ;; - *) - # pre Leopard has no dtrace, which is required by 37.11 and above - # Leopard only has 32-bits version of dtrace - LIBSTDCXX_APPLE_VERSION=16 - ;; -esac - SLOT="42" KEYWORDS="~ppc-macos ~x64-macos ~x86-macos" IUSE="fortran nls +openmp objc objc++ +cxx" @@ -52,14 +41,6 @@ S=${WORKDIR}/gcc-${APPLE_VERS} # TPREFIX is the prefix of the CTARGET installation export TPREFIX=${TPREFIX:-${EPREFIX}} -LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} -if is_crosscompile ; then - BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} -else - BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} -fi -STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} - do_bootstrap() { is_crosscompile && return 1 [[ ${CHOST} != ${CBUILD} ]] && return 1 @@ -82,6 +63,16 @@ src_prepare() { fi # move in libstdc++ + case ${CHOST} in + *-darwin1*|i?86-*-darwin9|powerpc-*-darwin9) + LIBSTDCXX_APPLE_VERSION=39 + ;; + *) + # pre Leopard has no dtrace, which is required by 37.11 and above + # Leopard only has 32-bits version of dtrace + LIBSTDCXX_APPLE_VERSION=16 + ;; + esac mv "${WORKDIR}"/libstdcxx-${LIBSTDCXX_APPLE_VERSION}/libstdcxx/libstdc++-v3 . if [[ ${LIBSTDCXX_APPLE_VERSION} == 16 ]] ; then epatch "${FILESDIR}"/libstdc++-${LIBSTDCXX_APPLE_VERSION}.patch # does it apply on 37? @@ -167,6 +158,14 @@ src_configure() { use objc++ && langs="${langs/,objc/},objc,obj-c++" # need objc with objc++ use fortran && langs="${langs},fortran" + LIBPATH=${EPREFIX}/usr/lib/gcc/${CTARGET}/${GCC_VERS} + if is_crosscompile ; then + BINPATH=${EPREFIX}/usr/${CHOST}/${CTARGET}/gcc-bin/${GCC_VERS} + else + BINPATH=${EPREFIX}/usr/${CTARGET}/gcc-bin/${GCC_VERS} + fi + STDCXX_INCDIR=${LIBPATH}/include/g++-v${GCC_VERS/\.*/} + local myconf="${myconf} \ --prefix=${EPREFIX}/usr \ --bindir=${BINPATH} \ -- cgit v1.2.3-65-gdbad