Gentoo Archives: gentoo-commits

From: Sergei Trofimovich <slyfox@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/binutils-libs/
Date: Sat, 16 Feb 2019 12:28:51
Message-Id: 1550320114.fbb23a8f0b5190c5987c233075c671c39761985e.slyfox@gentoo
1 commit: fbb23a8f0b5190c5987c233075c671c39761985e
2 Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
3 AuthorDate: Sat Feb 16 11:49:09 2019 +0000
4 Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
5 CommitDate: Sat Feb 16 12:28:34 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fbb23a8f
7
8 sys-libs/binutils-libs: bump up to 2.32, patchset 1
9
10 Initial patchset is based on current binutils-2.32 branch.
11
12 Reported-by: Lars Wendler
13 Bug: https://bugs.gentoo.org/677342
14 Package-Manager: Portage-2.3.60, Repoman-2.3.12
15 Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>
16
17 sys-libs/binutils-libs/Manifest | 2 +
18 sys-libs/binutils-libs/binutils-libs-2.32.ebuild | 119 +++++++++++++++++++++++
19 2 files changed, 121 insertions(+)
20
21 diff --git a/sys-libs/binutils-libs/Manifest b/sys-libs/binutils-libs/Manifest
22 index 92a5a944bea..5799012de6f 100644
23 --- a/sys-libs/binutils-libs/Manifest
24 +++ b/sys-libs/binutils-libs/Manifest
25 @@ -10,3 +10,5 @@ DIST binutils-2.30-patches-5.tar.xz 590864 BLAKE2B 71de4d08f92ab1898ad576a21763f
26 DIST binutils-2.30.tar.xz 20286700 BLAKE2B 2dd5436a15a601011a1950e6082ec00082f5916fb82ce95ceab424fd8dc19f6daa7ac32a149f222ccdcc603354165cc206fde070eaa44fe2cc5e57486efc7868 SHA512 e747ea20d8d79fcd21b9d9f6695059caa7189d60f19256da398e34b789fea9a133c32b192e9693b5828d27683739b0198431bf8b3e39fb3b04884cf89d9aa839
27 DIST binutils-2.31.1-patches-5.tar.xz 65896 BLAKE2B 7fb2c4c71336a77f3fef57a0430c511ef7326f8196d8f3a57a6d56aed464953172eeb0755f020387739cf27f709d0bc3de9c3c8b972a94f1480639465158e180 SHA512 c254f22b8ca662cf49cd5fc076d3e9b82d7f421420408c960c54310fc49462600325e7bc50f863cab7c8c49caebac3ac353dc24ab5947e8f01b98c11f43f57d2
28 DIST binutils-2.31.1.tar.xz 20467996 BLAKE2B 6b914df1fbb7cf54f2159f71b2c2b09f3f6a569b7a3cb4cf9790d0a3733a7548bc0ea32334a178ed3b56e8b97656ae99c7abaf212601beeaeae9a0884c0f6051 SHA512 0fca326feb1d5f5fe505a827b20237fe3ec9c13eaf7ec7e35847fd71184f605ba1cefe1314b1b8f8a29c0aa9d88162849ee1c1a3e70c2f7407d88339b17edb30
29 +DIST binutils-2.32-patches-1.tar.xz 93252 BLAKE2B 80d229be60c3377fe52ff3e74ee911b5dcfb9456d3f42a57662fbda3184ac1c63e698e592f804ac05c459527d0cd4bae7d8c9ef8caef02fdf4f17aa783f4ff81 SHA512 69999f60d89589dcf9e3cb18e50f153ab4ce05bdf3f3758fa322b5c4cb468aeda46c416da540995ddff1ea5e96354c264fa5ff0156c53685816d35117eb481e0
30 +DIST binutils-2.32.tar.xz 20774880 BLAKE2B d1bdbd9c8487c091665c197974ce4bdf520b7a67ed6997a81b87e6a0af9514a091458244f583acec5ae580ac2ee5e908f67f483b8e5263cd18ced794cb235da6 SHA512 d326408f12a03d9a61a9de56584c2af12f81c2e50d2d7e835d51565df8314df01575724afa1e43bd0db45cfc9916b41519b67dfce03232aa4978704492a6994a
31
32 diff --git a/sys-libs/binutils-libs/binutils-libs-2.32.ebuild b/sys-libs/binutils-libs/binutils-libs-2.32.ebuild
33 new file mode 100644
34 index 00000000000..cc1f0e62bee
35 --- /dev/null
36 +++ b/sys-libs/binutils-libs/binutils-libs-2.32.ebuild
37 @@ -0,0 +1,119 @@
38 +# Copyright 1999-2019 Gentoo Authors
39 +# Distributed under the terms of the GNU General Public License v2
40 +
41 +EAPI=6
42 +
43 +PATCH_VER=1
44 +PATCH_DEV=slyfox
45 +
46 +inherit eutils libtool toolchain-funcs multilib-minimal
47 +
48 +MY_PN="binutils"
49 +MY_P="${MY_PN}-${PV}"
50 +PATCH_BINUTILS_VER=${PATCH_BINUTILS_VER:-${PV}}
51 +PATCH_DEV=${PATCH_DEV:-slyfox}
52 +
53 +DESCRIPTION="Core binutils libraries (libbfd, libopcodes, libiberty) for external packages"
54 +HOMEPAGE="https://sourceware.org/binutils/"
55 +SRC_URI="mirror://gnu/binutils/${MY_P}.tar.xz
56 + https://dev.gentoo.org/~${PATCH_DEV}/distfiles/${MY_PN}-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz"
57 +
58 +LICENSE="|| ( GPL-3 LGPL-3 )"
59 +SLOT="0/${PV}"
60 +IUSE="64-bit-bfd multitarget nls static-libs"
61 +# no keywords yet. Needs some testing
62 +#KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
63 +
64 +COMMON_DEPEND="sys-libs/zlib[${MULTILIB_USEDEP}]"
65 +DEPEND="${COMMON_DEPEND}
66 + >=sys-apps/texinfo-4.7
67 + nls? ( sys-devel/gettext )"
68 +# Need a newer binutils-config that'll reset include/lib symlinks for us.
69 +RDEPEND="${COMMON_DEPEND}
70 + >=sys-devel/binutils-config-5
71 + nls? ( !<sys-devel/gdb-7.10-r1[nls] )"
72 +
73 +S="${WORKDIR}/${MY_P}"
74 +
75 +MULTILIB_WRAPPED_HEADERS=(
76 + /usr/include/bfd.h
77 +)
78 +
79 +src_prepare() {
80 + if [[ ! -z ${PATCH_VER} ]] ; then
81 + # Use upstream patch to enable development mode
82 + rm -v "${WORKDIR}/patch"/0000-Gentoo-Git-is-development.patch || die
83 +
84 + einfo "Applying binutils-${PATCH_BINUTILS_VER} patchset ${PATCH_VER}"
85 + eapply "${WORKDIR}/patch"/*.patch
86 + fi
87 +
88 + # Fix cross-compile relinking issue.
89 + elibtoolize
90 +
91 + default
92 +}
93 +
94 +pkgversion() {
95 + printf "Gentoo ${PVR}"
96 + [[ -n ${PATCHVER} ]] && printf " p${PATCHVER}"
97 +}
98 +
99 +multilib_src_configure() {
100 + local myconf=(
101 + --enable-obsolete
102 + --enable-shared
103 + --enable-threads
104 + # Newer versions (>=2.24) make this an explicit option. #497268
105 + --enable-install-libiberty
106 + --disable-werror
107 + --with-bugurl="https://bugs.gentoo.org/"
108 + --with-pkgversion="$(pkgversion)"
109 + $(use_enable static-libs static)
110 + # The binutils eclass enables this flag for all bi-arch builds,
111 + # but other tools often don't care about that support. Put it
112 + # beyond a flag if people really want it, but otherwise leave
113 + # it disabled as it can slow things down on 32bit arches. #438522
114 + $(use_enable 64-bit-bfd)
115 + # This only disables building in the zlib subdir.
116 + # For binutils itself, it'll use the system version. #591516
117 + --without-zlib
118 + --with-system-zlib
119 + # We only care about the libs, so disable programs. #528088
120 + --disable-{binutils,etc,ld,gas,gold,gprof}
121 + # Disable modules that are in a combined binutils/gdb tree. #490566
122 + --disable-{gdb,libdecnumber,readline,sim}
123 + # Strip out broken static link flags.
124 + # https://gcc.gnu.org/PR56750
125 + --without-stage1-ldflags
126 + # We pull in all USE-flags that change ABI in an incompatible
127 + # way. #666100
128 + # USE=multitarget change size of global arrays
129 + # USE=64-bit-bfd changes data structures of exported API
130 + --with-extra-soversion-suffix=gentoo-${CATEGORY}-${PN}-$(usex multitarget mt st)-$(usex 64-bit-bfd 64 def)
131 + )
132 +
133 + # mips can't do hash-style=gnu ...
134 + if [[ $(tc-arch) != mips ]] ; then
135 + myconf+=( --enable-default-hash-style=gnu )
136 + fi
137 +
138 + use multitarget && myconf+=( --enable-targets=all --enable-64-bit-bfd )
139 +
140 + use nls \
141 + && myconf+=( --without-included-gettext ) \
142 + || myconf+=( --disable-nls )
143 +
144 + ECONF_SOURCE=${S} \
145 + econf "${myconf[@]}"
146 +}
147 +
148 +multilib_src_install() {
149 + default
150 + # Provide libiberty.h directly.
151 + dosym libiberty/libiberty.h /usr/include/libiberty.h
152 +}
153 +
154 +multilib_src_install_all() {
155 + use static-libs || find "${ED}"/usr -name '*.la' -delete
156 +}