summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2014-11-08 17:12:09 +0000
committerMike Frysinger <vapier@gentoo.org>2014-11-08 17:12:09 +0000
commit3b69516eb5aec5f8680c51b20529791e44006b54 (patch)
tree8c720180c98ade10a98fe32a9511e20e77645992 /eclass
parentCopy stable keywords from dev-lang/perl-5.18 provider, remove old (diff)
downloadgentoo-2-3b69516eb5aec5f8680c51b20529791e44006b54.tar.gz
gentoo-2-3b69516eb5aec5f8680c51b20529791e44006b54.tar.bz2
gentoo-2-3b69516eb5aec5f8680c51b20529791e44006b54.zip
refactor bugurl/pkgversion info so ebuilds can override them easily
Diffstat (limited to 'eclass')
-rw-r--r--eclass/toolchain-binutils.eclass17
1 files changed, 12 insertions, 5 deletions
diff --git a/eclass/toolchain-binutils.eclass b/eclass/toolchain-binutils.eclass
index e71fbd9740d7..e8ceca48a0a5 100644
--- a/eclass/toolchain-binutils.eclass
+++ b/eclass/toolchain-binutils.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-binutils.eclass,v 1.136 2014/11/02 19:36:36 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-binutils.eclass,v 1.137 2014/11/08 17:12:09 vapier Exp $
#
# Maintainer: Toolchain Ninjas <toolchain@gentoo.org>
#
@@ -220,6 +220,15 @@ _eprefix_init() {
has "${EAPI:-0}" 0 1 2 && ED=${D} EPREFIX= EROOT=${ROOT}
}
+# Intended for ebuilds to override to set their own versioning information.
+toolchain-binutils_bugurl() {
+ printf "http://bugs.gentoo.org/"
+}
+toolchain-binutils_pkgversion() {
+ printf "Gentoo ${BVER}"
+ [[ -n ${PATCHVER} ]] && printf " p${PATCHVER}"
+}
+
toolchain-binutils_src_configure() {
_eprefix_init
@@ -281,8 +290,6 @@ toolchain-binutils_src_configure() {
has_version ">=${CATEGORY}/glibc-2.5" && myconf+=( --enable-secureplt )
has_version ">=sys-libs/glibc-2.5" && myconf+=( --enable-secureplt )
- local pkgver="Gentoo ${BVER}"
- [[ -n ${PATCHVER} ]] && pkgver+=" p${PATCHVER}"
myconf+=(
--prefix="${EPREFIX}"/usr
--host=${CHOST}
@@ -300,8 +307,8 @@ toolchain-binutils_src_configure() {
# Newer versions (>=2.24) make this an explicit option. #497268
--enable-install-libiberty
--disable-werror
- --with-bugurl=http://bugs.gentoo.org/
- --with-pkgversion="${pkgver}"
+ --with-bugurl="$(toolchain-binutils_bugurl)"
+ --with-pkgversion="$(toolchain-binutils_pkgversion)"
$(use_enable static-libs static)
${EXTRA_ECONF}
# Disable modules that are in a combined binutils/gdb tree. #490566