diff options
author | Fabian Groffen <grobian@gentoo.org> | 2016-09-10 16:38:28 +0200 |
---|---|---|
committer | Fabian Groffen <grobian@gentoo.org> | 2016-09-10 16:40:27 +0200 |
commit | 49925c0dd0a4ab8599c955244cee2d0764cc08e9 (patch) | |
tree | 212726b265d87b1ef67ecc7236a091efdbf6910c /sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild | |
parent | sys-devel/gcc-apple: bump to EAPI=5 and remove all conditional code from glob... (diff) | |
download | gentoo-49925c0dd0a4ab8599c955244cee2d0764cc08e9.tar.gz gentoo-49925c0dd0a4ab8599c955244cee2d0764cc08e9.tar.bz2 gentoo-49925c0dd0a4ab8599c955244cee2d0764cc08e9.zip |
sys-devel/binutils-apple: bump to EAPI=5 and remove all conditional code from global scope, bug #593392
Package-Manager: portage-2.2.28
Diffstat (limited to 'sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild')
-rw-r--r-- | sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild | 37 |
1 files changed, 19 insertions, 18 deletions
diff --git a/sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild b/sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild index 58c2d4ef98a3..682f644fc851 100644 --- a/sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild +++ b/sys-devel/binutils-apple/binutils-apple-5.1-r1.ebuild @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="3" +EAPI="5" inherit eutils flag-o-matic toolchain-funcs @@ -33,27 +33,12 @@ DEPEND="${RDEPEND} || ( >=sys-devel/gcc-apple-4.2.1 sys-devel/llvm ) libcxx? ( sys-devel/llvm )" -export CTARGET=${CTARGET:-${CHOST}} -if [[ ${CTARGET} == ${CHOST} ]] ; then - if [[ ${CATEGORY} == cross-* ]] ; then - export CTARGET=${CATEGORY#cross-} - fi -fi -is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } - SLOT="5" -LIBPATH=/usr/$(get_libdir)/binutils/${CTARGET}/${PV} -INCPATH=${LIBPATH}/include -DATAPATH=/usr/share/binutils-data/${CTARGET}/${PV} -if is_cross ; then - BINPATH=/usr/${CHOST}/${CTARGET}/binutils-bin/${PV} -else - BINPATH=/usr/${CTARGET}/binutils-bin/${PV} -fi - S=${WORKDIR} +is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } + src_prepare() { if use multitarget ; then ewarn "You have enabled support for non-standard target architectures" @@ -197,6 +182,22 @@ src_configure() { ENABLE_LTO=0 use lto && ENABLE_LTO=1 + export CTARGET=${CTARGET:-${CHOST}} + if [[ ${CTARGET} == ${CHOST} ]] ; then + if [[ ${CATEGORY} == cross-* ]] ; then + export CTARGET=${CATEGORY#cross-} + fi + fi + + LIBPATH=/usr/$(get_libdir)/binutils/${CTARGET}/${PV} + INCPATH=${LIBPATH}/include + DATAPATH=/usr/share/binutils-data/${CTARGET}/${PV} + if is_cross ; then + BINPATH=/usr/${CHOST}/${CTARGET}/binutils-bin/${PV} + else + BINPATH=/usr/${CTARGET}/binutils-bin/${PV} + fi + if [ "${CXX/*clang*/yes}" = "yes" ] ; then if use libcxx ; then append-cxxflags -stdlib=libc++ |