summaryrefslogtreecommitdiff
path: root/sys-devel/binutils
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-11-30 23:50:39 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-11-30 23:50:39 +0000
commit77819fe3944f22678c3bcdf1d773a095441f5140 (patch)
treeddc9dcd1edebe1e94204dfb4bf09ade2c9552f0f /sys-devel/binutils
parent826d1b3f488d3549cbd42ccc73ad90ea1ce88f0b (diff)
toolchain bump
Diffstat (limited to 'sys-devel/binutils')
-rw-r--r--sys-devel/binutils/Manifest4
-rw-r--r--sys-devel/binutils/binutils-2.35.1-r10.ebuild (renamed from sys-devel/binutils/binutils-2.34-r314.ebuild)106
-rw-r--r--sys-devel/binutils/files/binutils-2.33-gcc-10.patch39
3 files changed, 53 insertions, 96 deletions
diff --git a/sys-devel/binutils/Manifest b/sys-devel/binutils/Manifest
index 7cea1217..49d69a0b 100644
--- a/sys-devel/binutils/Manifest
+++ b/sys-devel/binutils/Manifest
@@ -1,2 +1,2 @@
-DIST binutils-2.34-patches-1.tar.xz 20388 BLAKE2B 8828505f62259a307de445357320827e7f6bc416a7f4c72140add505f62eef3928c7daec13be158b52c2a7a1d989f539025e4be6ec27ef80ede81477a42c5042 SHA512 951dffcc30ad5706dc48e71995217655c5d96472446ab66a357f19486b57d1868143a9809887eab7ba8c42c33124f8b37d3bab6618388ea8a08b4399d348a645
-DIST binutils-2.34.tar.xz 21637796 BLAKE2B 07dd23916a7d27f71c3f160c8c16abe2bd4fce294c738c665a012a3be6a87dbe8160d0c38740524f9025e01d438e99b2a94bcf9f9f79ee214f5dd033de8aad3d SHA512 2c7976939dcf5e8c5b7374cccd39bfe803b1bec73c6abfa0eb17c24e1942574c6bdb874c66a092a82adc443182eacd8a5a8001c19a76101f0c7ba40c27de0bbd
+DIST binutils-2.35.1-patches-2.tar.xz 72236 BLAKE2B 584cb3edbda28c69171ed64e941535f992150d86f25201cadd07b63daaa36bf76b07dc0aa8a4837da17d1672feb47a7b15f83efdeec5409e695965a10142147a SHA512 b704ebe82c4402f058f9c96991a89256a6b369d28f844bf020ed2c77766894d9a2ca0596cd609de7b389fa8cd52bfab674b6deb10ea2096e50aa57921be2083e
+DIST binutils-2.35.1.tar.xz 22031720 BLAKE2B d3468da90b75e9b5fa7fbd64d3fdb0a4bc445e4cb7da5ae058f73a1e9d948b3e9438bc9f1b5b351db369b76a25960c9c1f58f828fd2c7646f555de45fa3c052b SHA512 94ff72708403413b70b247f3af4099ebaa882b6659249869f1ed9941a0f1912e313f08357d470f9fd2359e7f5e5b0eb86285e5eaf883fa8187789d6b1bd304eb
diff --git a/sys-devel/binutils/binutils-2.34-r314.ebuild b/sys-devel/binutils/binutils-2.35.1-r10.ebuild
index 805c709d..57dc7a30 100644
--- a/sys-devel/binutils/binutils-2.34-r314.ebuild
+++ b/sys-devel/binutils/binutils-2.35.1-r10.ebuild
@@ -8,10 +8,10 @@ inherit eutils libtool flag-o-matic gnuconfig multilib toolchain-funcs
DESCRIPTION="Tools necessary to build programs"
HOMEPAGE="https://sourceware.org/binutils/"
LICENSE="GPL-3+"
-IUSE="default-gold doc +gold multitarget +nls +plugins static-libs test"
+IUSE="default-gold doc +gold multitarget +nls +plugins static-libs test vanilla"
REQUIRED_USE="default-gold? ( gold )"
-# Variables that can be set here:
+# Variables that can be set here (ignored for live ebuilds)
# PATCH_VER - the patchset version
# Default: empty, no patching
# PATCH_BINUTILS_VER - the binutils version in the patchset name
@@ -19,41 +19,22 @@ REQUIRED_USE="default-gold? ( gold )"
# PATCH_DEV - Use download URI https://dev.gentoo.org/~{PATCH_DEV}/distfiles/...
# for the patchsets
-PATCH_VER=1
-PATCH_DEV=slyfox
-
-case ${PV} in
- 9999)
- EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git"
- inherit git-r3
- S=${WORKDIR}/binutils
- EGIT_CHECKOUT_DIR=${S}
- SLOT=${PV}
- ;;
- *.9999)
- EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git"
- inherit git-r3
- S=${WORKDIR}/binutils
- EGIT_CHECKOUT_DIR=${S}
- EGIT_BRANCH=$(ver_cut 1-2)
- EGIT_BRANCH="binutils-${EGIT_BRANCH/./_}-branch"
- SLOT=$(ver_cut 1-2)
- ;;
- *)
- SRC_URI="mirror://gnu/binutils/binutils-${PV}.tar.xz"
- SLOT=$(ver_cut 1-2)
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
- ;;
-esac
-
-#
-# The Gentoo patchset
-#
-PATCH_BINUTILS_VER=${PATCH_BINUTILS_VER:-${PV}}
-PATCH_DEV=${PATCH_DEV:-slyfox}
-
-[[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI}
- https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz"
+PATCH_VER=2
+PATCH_DEV=dilfridge
+
+if [[ ${PV} == 9999* ]]; then
+ inherit git-r3
+ SLOT=${PV}
+else
+ PATCH_BINUTILS_VER=${PATCH_BINUTILS_VER:-${PV}}
+ PATCH_DEV=${PATCH_DEV:-slyfox}
+ SRC_URI="mirror://gnu/binutils/binutils-${PV}.tar.xz"
+ [[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI}
+ https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz"
+ SLOT=$(ver_cut 1-2)
+ # live ebuild
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+fi
#
# The cross-compile logic
@@ -84,31 +65,44 @@ BDEPEND="
RESTRICT="!test? ( test )"
-PATCHES=(
- "${FILESDIR}"/${PN}-2.33-gcc-10.patch
-)
-
MY_BUILDDIR=${WORKDIR}/build
src_unpack() {
- case ${PV} in
- *9999)
- git-r3_src_unpack
- ;;
- *)
- ;;
- esac
- default
- mkdir -p "${MY_BUILDDIR}"
+ if [[ ${PV} == 9999* ]] ; then
+ EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/toolchain/binutils-patches.git"
+ EGIT_CHECKOUT_DIR=${WORKDIR}/patches-git
+ git-r3_src_unpack
+ mv patches-git/9999 patch || die
+
+ EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git"
+ S=${WORKDIR}/binutils
+ EGIT_CHECKOUT_DIR=${S}
+ git-r3_src_unpack
+ else
+ unpack ${P}.tar.xz
+
+ cd "${WORKDIR}" || die
+ unpack binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz
+ fi
+
+ cd "${WORKDIR}" || die
+ mkdir -p "${MY_BUILDDIR}" || die
}
src_prepare() {
- if [[ ! -z ${PATCH_VER} ]] ; then
- # Use upstream patch to enable development mode
- rm -v "${WORKDIR}/patch"/0000-Gentoo-Git-is-development.patch || die
+ local patchsetname
+ if [[ ${PV} == 9999* ]] ; then
+ patchsetname="from git master"
+ else
+ patchsetname="${PATCH_BINUTILS_VER}-${PATCH_VER}"
+ fi
- einfo "Applying binutils-${PATCH_BINUTILS_VER} patchset ${PATCH_VER}"
- eapply "${WORKDIR}/patch"/*.patch
+ if [[ ! -z ${PATCH_VER} ]] || [[ ${PV} == 9999* ]] ; then
+ if ! use vanilla; then
+ einfo "Applying binutils patchset ${patchsetname}"
+ eapply "${WORKDIR}/patch"
+ einfo "Done."
+ fi
fi
# This check should probably go somewhere else, like pkg_pretend.
@@ -249,6 +243,8 @@ src_configure() {
--enable-relro
# Newer versions (>=2.24) make this an explicit option. #497268
--enable-install-libiberty
+ # Available from 2.35 on
+ --enable-textrel-check=warning
--disable-werror
--with-bugurl="$(toolchain-binutils_bugurl)"
--with-pkgversion="$(toolchain-binutils_pkgversion)"
diff --git a/sys-devel/binutils/files/binutils-2.33-gcc-10.patch b/sys-devel/binutils/files/binutils-2.33-gcc-10.patch
deleted file mode 100644
index 9e1a999b..00000000
--- a/sys-devel/binutils/files/binutils-2.33-gcc-10.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-binutils: drop redundant 'program_name' definition
-
-https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff;h=0b398d69acde3377dfbbeb8a4cfe87ae8c8562fa
---- a/binutils/coffdump.c
-+++ b/binutils/coffdump.c
-@@ -456,8 +456,6 @@ coff_dump (struct coff_ofile *ptr)
- dump_coff_section (ptr->sections + i);
- }
-
--char * program_name;
--
- static void
- show_usage (FILE *file, int status)
- {
---- a/binutils/srconv.c
-+++ b/binutils/srconv.c
-@@ -1687,8 +1687,6 @@ prescan (struct coff_ofile *otree)
- }
- }
-
--char *program_name;
--
- ATTRIBUTE_NORETURN static void
- show_usage (FILE *ffile, int status)
- {
---- a/binutils/sysdump.c
-+++ b/binutils/sysdump.c
-@@ -633,8 +633,6 @@ module (void)
- }
- }
-
--char *program_name;
--
- ATTRIBUTE_NORETURN static void
- show_usage (FILE *ffile, int status)
- {
---
-2.25.0
-