commit: bcf3b906fdf9380837d462e56aca0da1f2388f2c Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> AuthorDate: Tue Feb 12 23:01:16 2019 +0000 Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> CommitDate: Tue Feb 12 23:01:33 2019 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bcf3b906
sys-devel/binutils: add USE=default-gold, bug #496760 binutils allows you to set ld=ld.bfd (default) and ld=ld.gold. Expose this override as USE=default-gold. Reported-by: Marcin Mirosław Bug: https://bugs.gentoo.org/496760 Package-Manager: Portage-2.3.60, Repoman-2.3.12 Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org> sys-devel/binutils/binutils-2.31.1-r3.ebuild | 8 ++++++-- sys-devel/binutils/binutils-9999.ebuild | 5 ++++- sys-devel/binutils/metadata.xml | 1 + 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/sys-devel/binutils/binutils-2.31.1-r3.ebuild b/sys-devel/binutils/binutils-2.31.1-r3.ebuild index 0ba64dc35a0..ef47b02deaf 100644 --- a/sys-devel/binutils/binutils-2.31.1-r3.ebuild +++ b/sys-devel/binutils/binutils-2.31.1-r3.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Authors +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -8,7 +8,8 @@ inherit eutils libtool flag-o-matic gnuconfig multilib versionator DESCRIPTION="Tools necessary to build programs" HOMEPAGE="https://sourceware.org/binutils/" LICENSE="GPL-3+" -IUSE="+cxx doc multitarget +nls static-libs test" +IUSE="+cxx default-gold doc multitarget +nls static-libs test" +REQUIRED_USE="default-gold? ( cxx )" # Variables that can be set here: # PATCH_VER - the patchset version @@ -179,6 +180,9 @@ src_configure() { if use cxx ; then myconf+=( --enable-gold ) myconf+=( --enable-plugins ) + if use default-gold; then + myconf+=( --enable-gold=default ) + fi fi if use nls ; then diff --git a/sys-devel/binutils/binutils-9999.ebuild b/sys-devel/binutils/binutils-9999.ebuild index 5e72d97d140..4e2bb0f4ec7 100644 --- a/sys-devel/binutils/binutils-9999.ebuild +++ b/sys-devel/binutils/binutils-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Authors +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -178,6 +178,9 @@ src_configure() { if use cxx ; then myconf+=( --enable-gold ) myconf+=( --enable-plugins ) + if use default-gold; then + myconf+=( --enable-gold=default ) + fi fi if use nls ; then diff --git a/sys-devel/binutils/metadata.xml b/sys-devel/binutils/metadata.xml index cd119b3491c..98c985e11c4 100644 --- a/sys-devel/binutils/metadata.xml +++ b/sys-devel/binutils/metadata.xml @@ -6,6 +6,7 @@ <name>Gentoo Toolchain Project</name> </maintainer> <use> + <flag name="default-gold">Set ld to point to ld.gold instead of ld.bfd</flag> <flag name="multitarget">Adds support to binutils for cross compiling (does not work with gas)</flag> </use> <upstream>