1 |
commit: ee9de902c82c81f6c72314e533471e2bedf743d2 |
2 |
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Sep 5 18:52:14 2018 +0000 |
4 |
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Sep 5 18:53:17 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ee9de902 |
7 |
|
8 |
sys-devel/gdb: drop old |
9 |
|
10 |
Package-Manager: Portage-2.3.49, Repoman-2.3.10 |
11 |
|
12 |
sys-devel/gdb/Manifest | 3 - |
13 |
sys-devel/gdb/gdb-8.0.1-r1.ebuild | 250 ------------------------------------- |
14 |
sys-devel/gdb/gdb-8.0.1.ebuild | 250 ------------------------------------- |
15 |
sys-devel/gdb/gdb-8.0.ebuild | 242 ------------------------------------ |
16 |
sys-devel/gdb/gdb-8.1.ebuild | 254 -------------------------------------- |
17 |
5 files changed, 999 deletions(-) |
18 |
|
19 |
diff --git a/sys-devel/gdb/Manifest b/sys-devel/gdb/Manifest |
20 |
index 6d260ae06f6..11d26cdf51c 100644 |
21 |
--- a/sys-devel/gdb/Manifest |
22 |
+++ b/sys-devel/gdb/Manifest |
23 |
@@ -1,9 +1,6 @@ |
24 |
DIST gdb-7.10.1.tar.xz 18531436 BLAKE2B b50a1b6b5b867e4a52943fdc4992c654ceec180099771381df78de5ba79086e822264356a762c61b89e986407d6f0cce336be216276545591e637131dc02f4a8 SHA512 17a5138277a31685a5c2a841cb47ed9bc4626ea617b8ca77750513b300299f4fbbffe504958b5372de610dcb952c679cf8fa9c1bdadd380294fbf59b6e366010 |
25 |
DIST gdb-7.12.1.tar.xz 19225392 BLAKE2B 2e4b7fe69c3cb11c04b505d1e110bf0a9ca65b6178f3e6a6ccc11fde1e8750b595016baf64adb2c22903d346cec1dab15574681de812ac8d260aebf4152a3027 SHA512 0ac8d0a495103611ef41167a08313a010dce6ca4c6d827cbe8558a0c1a1a8a6bfa53f1b7704251289cababbfaaf9e075550cdf741a54d6cd9ca3433d910efcd8 |
26 |
DIST gdb-7.9.1.tar.xz 17867692 BLAKE2B f5de07a4ebf1a5112a1b40341b217d08f1eb6820eb2237a4be2cd289f832600b81b3c14f4632a762fdc13945a2fb65ffb58f13eb330f3d48892799e27bb62c87 SHA512 eebdf88b24e52e792b8a4b89ea85790de72b462a7810b44975fdf4232c068f353b15506071f450102a9d4bcecdde8e93dc3748a10699b7f73f3e04fb2d9d8414 |
27 |
-DIST gdb-8.0.1-patches-1.tar.xz 8620 BLAKE2B 8595017a881c41cbe78846fae9f50460aa6a4aa8d3863b17e4b9119d886600ee086b642c44b427a2de29c5f3fd4697df838e85e23aafeac05a6ce3291546f099 SHA512 912ad1a51207ca1ec9d3c46e32b07d78a5d3368b617f277532f8a81e40875cc9ec5af8b62f9b1de67aa6d09520c6cc6ad32f48bd44415985d8ad03aa4a1bca7d |
28 |
-DIST gdb-8.0.1.tar.xz 19583920 BLAKE2B c22e314a0fe3ccb84cef6eca66c51af60914160ac9760cbe517628079dfb15ec73a623badf070b3162d4bd9e44937f717fd44e1d569edba4532853c82b31ac1d SHA512 5eb328910033f0918058be2f92caebf1e8dfc6caa3c730d99d621627e53de3c1b43761c2f683d53555893253c2f06768cbf56cdea051a3d291ffb6cfae87b5e1 |
29 |
-DIST gdb-8.0.tar.xz 19588616 BLAKE2B 148965e33a42787b5fa39650c2b6c48e28895930e36f11b44e8391366be1cc3bd4265ea7df932a7d650291fb20e3f66956c7dff1923025f889e5c035d3bf4207 SHA512 e4044bdd162cbf95044ec1eaa44d2fa62a33e051bdbbacbc97afd4dfb07bae1bea514381fc1966aede89d6796ef2377a15748a93d95e2ad494c8497db489e886 |
30 |
DIST gdb-8.1-patches-1.tar.xz 8768 BLAKE2B 792ceddcb8eafd028db23d69ad5d9eb00223722520c6ff0a23a24fee1a33dceb02f05e61a1d6c3700835c480b38d66f43f71ef3c4af406d4ae1147eaaf8f311e SHA512 87a5c9d9207817245e1ffd07fdad2cb566de4fc11725aa0e49e58268c3ab1ae3b4b9f4b9faa55acc8cb4c3c7cb5a3875ea7da02abeb8f775953a8aed2e2c6403 |
31 |
DIST gdb-8.1.1.tar.xz 20064728 BLAKE2B bd17a27a3974a34b94aa5898a97cf26dba9e91b815f25e6a0d67a7b4bc718ed2701a38cddbbfddce087c5d2d24c596daee4f06ea1acfe662f47a909409815311 SHA512 7dcd5e8c90de92f577834d887b5f54edb93a07083bfe661bc46c270a6cc4919f0b348e7e2fe8ae4511298a570ef150eeefdc667ef7cf527f0cf60943177ab6c9 |
32 |
DIST gdb-8.1.tar.xz 20095080 BLAKE2B 9332058b8b723261ba215124f42a2d6ba916219efdfb3c23ae1f48fecf131c801bbd31b345f2c8339b23d74da690be0260ac31f8f2e79549b62f0880199bfdec SHA512 ffd82f415d7652d62dad1716c307836f594217a363429609beb7d70239e8bf06b73b393345b0e000796228e56681ed7656ac3c8be05e91d6d652ab0d5b1dc357 |
33 |
|
34 |
diff --git a/sys-devel/gdb/gdb-8.0.1-r1.ebuild b/sys-devel/gdb/gdb-8.0.1-r1.ebuild |
35 |
deleted file mode 100644 |
36 |
index 69645e9ea72..00000000000 |
37 |
--- a/sys-devel/gdb/gdb-8.0.1-r1.ebuild |
38 |
+++ /dev/null |
39 |
@@ -1,250 +0,0 @@ |
40 |
-# Copyright 1999-2018 Gentoo Foundation |
41 |
-# Distributed under the terms of the GNU General Public License v2 |
42 |
- |
43 |
-EAPI=6 |
44 |
-PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} ) |
45 |
- |
46 |
-inherit epatch eutils flag-o-matic python-single-r1 |
47 |
- |
48 |
-export CTARGET=${CTARGET:-${CHOST}} |
49 |
-if [[ ${CTARGET} == ${CHOST} ]] ; then |
50 |
- if [[ ${CATEGORY} == cross-* ]] ; then |
51 |
- export CTARGET=${CATEGORY#cross-} |
52 |
- fi |
53 |
-fi |
54 |
-is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } |
55 |
- |
56 |
-RPM= |
57 |
-MY_PV=${PV} |
58 |
-case ${PV} in |
59 |
-9999*) |
60 |
- # live git tree |
61 |
- EGIT_REPO_URI="git://sourceware.org/git/binutils-gdb.git" |
62 |
- inherit git-r3 |
63 |
- SRC_URI="" |
64 |
- ;; |
65 |
-*.*.50.2???????) |
66 |
- # weekly snapshots |
67 |
- SRC_URI="ftp://sourceware.org/pub/gdb/snapshots/current/gdb-weekly-${PV}.tar.xz" |
68 |
- ;; |
69 |
-*.*.*.*.*.*) |
70 |
- # fedora versions; note we swap the rpm & fedora core versions. |
71 |
- # gdb-6.8.50.20090302-8.fc11.src.rpm -> gdb-6.8.50.20090302.11.8.ebuild |
72 |
- # gdb-7.9-11.fc23.src.rpm -> gdb-7.9.23.11.ebuild |
73 |
- inherit versionator rpm |
74 |
- gvcr() { get_version_component_range "$@"; } |
75 |
- parse_fedora_ver() { |
76 |
- set -- $(get_version_components) |
77 |
- MY_PV=$(gvcr 1-$(( $# - 2 ))) |
78 |
- RPM="${PN}-${MY_PV}-$(gvcr $#).fc$(gvcr $(( $# - 1 ))).src.rpm" |
79 |
- } |
80 |
- parse_fedora_ver |
81 |
- SRC_URI="mirror://fedora-dev/development/rawhide/source/SRPMS/g/${RPM}" |
82 |
- ;; |
83 |
-*) |
84 |
- # Normal upstream release |
85 |
- SRC_URI="mirror://gnu/gdb/${P}.tar.xz |
86 |
- ftp://sourceware.org/pub/gdb/releases/${P}.tar.xz" |
87 |
- ;; |
88 |
-esac |
89 |
- |
90 |
-PATCH_VER="1" |
91 |
-PATCH_DEV="slyfox" |
92 |
-DESCRIPTION="GNU debugger" |
93 |
-HOMEPAGE="https://sourceware.org/gdb/" |
94 |
-SRC_URI="${SRC_URI} |
95 |
- ${PATCH_DEV:+https://dev.gentoo.org/~${PATCH_DEV}/distfiles/${PN}-8.0.1-patches-${PATCH_VER}.tar.xz} |
96 |
- ${PATCH_VER:+mirror://gentoo/${PN}-8.0.1-patches-${PATCH_VER}.tar.xz} |
97 |
-" |
98 |
- |
99 |
-LICENSE="GPL-2 LGPL-2" |
100 |
-SLOT="0" |
101 |
-if [[ ${PV} != 9999* ]] ; then |
102 |
- # alpha #562128 |
103 |
- KEYWORDS="-alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
104 |
-fi |
105 |
-IUSE="+client lzma multitarget nls +python +server test vanilla xml" |
106 |
-REQUIRED_USE=" |
107 |
- python? ( ${PYTHON_REQUIRED_USE} ) |
108 |
- || ( client server ) |
109 |
-" |
110 |
- |
111 |
-RDEPEND="server? ( !dev-util/gdbserver ) |
112 |
- client? ( |
113 |
- >=sys-libs/ncurses-5.2-r2:0= |
114 |
- sys-libs/readline:0= |
115 |
- lzma? ( app-arch/xz-utils ) |
116 |
- python? ( ${PYTHON_DEPS} ) |
117 |
- xml? ( dev-libs/expat ) |
118 |
- sys-libs/zlib |
119 |
- )" |
120 |
-DEPEND="${RDEPEND} |
121 |
- app-arch/xz-utils |
122 |
- sys-apps/texinfo |
123 |
- client? ( |
124 |
- virtual/yacc |
125 |
- test? ( dev-util/dejagnu ) |
126 |
- nls? ( sys-devel/gettext ) |
127 |
- )" |
128 |
- |
129 |
-S=${WORKDIR}/${PN}-${MY_PV} |
130 |
- |
131 |
-pkg_setup() { |
132 |
- use python && python-single-r1_pkg_setup |
133 |
-} |
134 |
- |
135 |
-src_prepare() { |
136 |
- [[ -n ${RPM} ]] && rpm_spec_epatch "${WORKDIR}"/gdb.spec |
137 |
- ! use vanilla && [[ -n ${PATCH_VER} ]] && EPATCH_SUFFIX="patch" epatch "${WORKDIR}"/patch |
138 |
- |
139 |
- default |
140 |
- |
141 |
- strip-linguas -u bfd/po opcodes/po |
142 |
-} |
143 |
- |
144 |
-gdb_branding() { |
145 |
- printf "Gentoo ${PV} " |
146 |
- if ! use vanilla && [[ -n ${PATCH_VER} ]] ; then |
147 |
- printf "p${PATCH_VER}" |
148 |
- else |
149 |
- printf "vanilla" |
150 |
- fi |
151 |
- [[ -n ${EGIT_COMMIT} ]] && printf " ${EGIT_COMMIT}" |
152 |
-} |
153 |
- |
154 |
-src_configure() { |
155 |
- strip-unsupported-flags |
156 |
- |
157 |
- local myconf=( |
158 |
- --with-pkgversion="$(gdb_branding)" |
159 |
- --with-bugurl='https://bugs.gentoo.org/' |
160 |
- --disable-werror |
161 |
- # Disable modules that are in a combined binutils/gdb tree. #490566 |
162 |
- --disable-{binutils,etc,gas,gold,gprof,ld} |
163 |
- ) |
164 |
- local sysroot="${EPREFIX}/usr/${CTARGET}" |
165 |
- is_cross && myconf+=( |
166 |
- --with-sysroot="${sysroot}" |
167 |
- --includedir="${sysroot}/usr/include" |
168 |
- --with-gdb-datadir="\${datadir}/gdb/${CTARGET}" |
169 |
- ) |
170 |
- |
171 |
- if use server && ! use client ; then |
172 |
- # just configure+build in the gdbserver subdir to speed things up |
173 |
- cd gdb/gdbserver |
174 |
- myconf+=( --program-transform-name='' ) |
175 |
- else |
176 |
- # gdbserver only works for native targets (CHOST==CTARGET). |
177 |
- # it also doesn't support all targets, so rather than duplicate |
178 |
- # the target list (which changes between versions), use the |
179 |
- # "auto" value when things are turned on. |
180 |
- is_cross \ |
181 |
- && myconf+=( --disable-gdbserver ) \ |
182 |
- || myconf+=( $(use_enable server gdbserver auto) ) |
183 |
- fi |
184 |
- |
185 |
- if ! ( use server && ! use client ) ; then |
186 |
- # if we are configuring in the top level, then use all |
187 |
- # the additional global options |
188 |
- myconf+=( |
189 |
- --enable-64-bit-bfd |
190 |
- --disable-install-libbfd |
191 |
- --disable-install-libiberty |
192 |
- # Disable guile for now as it requires guile-2.x #562902 |
193 |
- --without-guile |
194 |
- # This only disables building in the readline subdir. |
195 |
- # For gdb itself, it'll use the system version. |
196 |
- --disable-readline |
197 |
- --with-system-readline |
198 |
- # This only disables building in the zlib subdir. |
199 |
- # For gdb itself, it'll use the system version. |
200 |
- --without-zlib |
201 |
- --with-system-zlib |
202 |
- --with-separate-debug-dir="${EPREFIX}"/usr/lib/debug |
203 |
- $(use_with xml expat) |
204 |
- $(use_with lzma) |
205 |
- $(use_enable nls) |
206 |
- $(use multitarget && echo --enable-targets=all) |
207 |
- $(use_with python python "${EPYTHON}") |
208 |
- ) |
209 |
- fi |
210 |
- if use sparc-solaris || use x86-solaris ; then |
211 |
- # disable largefile support |
212 |
- # https://sourceware.org/ml/gdb-patches/2014-12/msg00058.html |
213 |
- myconf+=( --disable-largefile ) |
214 |
- fi |
215 |
- |
216 |
- econf "${myconf[@]}" |
217 |
-} |
218 |
- |
219 |
-src_test() { |
220 |
- nonfatal emake check || ewarn "tests failed" |
221 |
-} |
222 |
- |
223 |
-src_install() { |
224 |
- if use server && ! use client; then |
225 |
- cd gdb/gdbserver || die |
226 |
- fi |
227 |
- default |
228 |
- if use client; then |
229 |
- find "${ED}"/usr -name libiberty.a -delete || die |
230 |
- fi |
231 |
- cd "${S}" || die |
232 |
- |
233 |
- # Delete translations that conflict with binutils-libs. #528088 |
234 |
- # Note: Should figure out how to store these in an internal gdb dir. |
235 |
- if use nls ; then |
236 |
- find "${ED}" \ |
237 |
- -regextype posix-extended -regex '.*/(bfd|opcodes)[.]g?mo$' \ |
238 |
- -delete || die |
239 |
- fi |
240 |
- |
241 |
- # Don't install docs when building a cross-gdb |
242 |
- if [[ ${CTARGET} != ${CHOST} ]] ; then |
243 |
- rm -rf "${ED}"/usr/share/{doc,info,locale} || die |
244 |
- local f |
245 |
- for f in "${ED}"/usr/share/man/*/* ; do |
246 |
- if [[ ${f##*/} != ${CTARGET}-* ]] ; then |
247 |
- mv "${f}" "${f%/*}/${CTARGET}-${f##*/}" || die |
248 |
- fi |
249 |
- done |
250 |
- return 0 |
251 |
- fi |
252 |
- # Install it by hand for now: |
253 |
- # https://sourceware.org/ml/gdb-patches/2011-12/msg00915.html |
254 |
- # Only install if it exists due to the twisted behavior (see |
255 |
- # notes in src_configure above). |
256 |
- [[ -e gdb/gdbserver/gdbreplay ]] && dobin gdb/gdbserver/gdbreplay |
257 |
- |
258 |
- if use client ; then |
259 |
- docinto gdb |
260 |
- dodoc gdb/CONTRIBUTE gdb/README gdb/MAINTAINERS \ |
261 |
- gdb/NEWS gdb/ChangeLog gdb/PROBLEMS |
262 |
- fi |
263 |
- docinto sim |
264 |
- dodoc sim/{ChangeLog,MAINTAINERS,README-HACKING} |
265 |
- if use server ; then |
266 |
- docinto gdbserver |
267 |
- dodoc gdb/gdbserver/{ChangeLog,README} |
268 |
- fi |
269 |
- |
270 |
- if [[ -n ${PATCH_VER} ]] ; then |
271 |
- dodoc "${WORKDIR}"/extra/gdbinit.sample |
272 |
- fi |
273 |
- |
274 |
- # Remove shared info pages |
275 |
- rm -f "${ED}"/usr/share/info/{annotate,bfd,configure,standards}.info* |
276 |
-} |
277 |
- |
278 |
-pkg_postinst() { |
279 |
- # portage sucks and doesnt unmerge files in /etc |
280 |
- rm -vf "${EROOT}"/etc/skel/.gdbinit |
281 |
- |
282 |
- if use prefix && [[ ${CHOST} == *-darwin* ]] ; then |
283 |
- ewarn "gdb is unable to get a mach task port when installed by Prefix" |
284 |
- ewarn "Portage, unprivileged. To make gdb fully functional you'll" |
285 |
- ewarn "have to perform the following steps:" |
286 |
- ewarn " % sudo chgrp procmod ${EPREFIX}/usr/bin/gdb" |
287 |
- ewarn " % sudo chmod g+s ${EPREFIX}/usr/bin/gdb" |
288 |
- fi |
289 |
-} |
290 |
|
291 |
diff --git a/sys-devel/gdb/gdb-8.0.1.ebuild b/sys-devel/gdb/gdb-8.0.1.ebuild |
292 |
deleted file mode 100644 |
293 |
index 4d44cbf1e70..00000000000 |
294 |
--- a/sys-devel/gdb/gdb-8.0.1.ebuild |
295 |
+++ /dev/null |
296 |
@@ -1,250 +0,0 @@ |
297 |
-# Copyright 1999-2018 Gentoo Foundation |
298 |
-# Distributed under the terms of the GNU General Public License v2 |
299 |
- |
300 |
-EAPI=6 |
301 |
-PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} ) |
302 |
- |
303 |
-inherit epatch eutils flag-o-matic python-single-r1 |
304 |
- |
305 |
-export CTARGET=${CTARGET:-${CHOST}} |
306 |
-if [[ ${CTARGET} == ${CHOST} ]] ; then |
307 |
- if [[ ${CATEGORY} == cross-* ]] ; then |
308 |
- export CTARGET=${CATEGORY#cross-} |
309 |
- fi |
310 |
-fi |
311 |
-is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } |
312 |
- |
313 |
-RPM= |
314 |
-MY_PV=${PV} |
315 |
-case ${PV} in |
316 |
-9999*) |
317 |
- # live git tree |
318 |
- EGIT_REPO_URI="git://sourceware.org/git/binutils-gdb.git" |
319 |
- inherit git-r3 |
320 |
- SRC_URI="" |
321 |
- ;; |
322 |
-*.*.50.2???????) |
323 |
- # weekly snapshots |
324 |
- SRC_URI="ftp://sourceware.org/pub/gdb/snapshots/current/gdb-weekly-${PV}.tar.xz" |
325 |
- ;; |
326 |
-*.*.*.*.*.*) |
327 |
- # fedora versions; note we swap the rpm & fedora core versions. |
328 |
- # gdb-6.8.50.20090302-8.fc11.src.rpm -> gdb-6.8.50.20090302.11.8.ebuild |
329 |
- # gdb-7.9-11.fc23.src.rpm -> gdb-7.9.23.11.ebuild |
330 |
- inherit versionator rpm |
331 |
- gvcr() { get_version_component_range "$@"; } |
332 |
- parse_fedora_ver() { |
333 |
- set -- $(get_version_components) |
334 |
- MY_PV=$(gvcr 1-$(( $# - 2 ))) |
335 |
- RPM="${PN}-${MY_PV}-$(gvcr $#).fc$(gvcr $(( $# - 1 ))).src.rpm" |
336 |
- } |
337 |
- parse_fedora_ver |
338 |
- SRC_URI="mirror://fedora-dev/development/rawhide/source/SRPMS/g/${RPM}" |
339 |
- ;; |
340 |
-*) |
341 |
- # Normal upstream release |
342 |
- SRC_URI="mirror://gnu/gdb/${P}.tar.xz |
343 |
- ftp://sourceware.org/pub/gdb/releases/${P}.tar.xz" |
344 |
- ;; |
345 |
-esac |
346 |
- |
347 |
-PATCH_VER="" |
348 |
-PATCH_DEV="" |
349 |
-DESCRIPTION="GNU debugger" |
350 |
-HOMEPAGE="https://sourceware.org/gdb/" |
351 |
-SRC_URI="${SRC_URI} |
352 |
- ${PATCH_DEV:+https://dev.gentoo.org/~${PATCH_DEV}/distfiles/${PN}-8.0.1-patches-${PATCH_VER}.tar.xz} |
353 |
- ${PATCH_VER:+mirror://gentoo/${PN}-8.0.1-patches-${PATCH_VER}.tar.xz} |
354 |
-" |
355 |
- |
356 |
-LICENSE="GPL-2 LGPL-2" |
357 |
-SLOT="0" |
358 |
-if [[ ${PV} != 9999* ]] ; then |
359 |
- # alpha #562128 |
360 |
- KEYWORDS="-alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
361 |
-fi |
362 |
-IUSE="+client lzma multitarget nls +python +server test vanilla xml" |
363 |
-REQUIRED_USE=" |
364 |
- python? ( ${PYTHON_REQUIRED_USE} ) |
365 |
- || ( client server ) |
366 |
-" |
367 |
- |
368 |
-RDEPEND="server? ( !dev-util/gdbserver ) |
369 |
- client? ( |
370 |
- >=sys-libs/ncurses-5.2-r2:0= |
371 |
- sys-libs/readline:0= |
372 |
- lzma? ( app-arch/xz-utils ) |
373 |
- python? ( ${PYTHON_DEPS} ) |
374 |
- xml? ( dev-libs/expat ) |
375 |
- sys-libs/zlib |
376 |
- )" |
377 |
-DEPEND="${RDEPEND} |
378 |
- app-arch/xz-utils |
379 |
- sys-apps/texinfo |
380 |
- client? ( |
381 |
- virtual/yacc |
382 |
- test? ( dev-util/dejagnu ) |
383 |
- nls? ( sys-devel/gettext ) |
384 |
- )" |
385 |
- |
386 |
-S=${WORKDIR}/${PN}-${MY_PV} |
387 |
- |
388 |
-pkg_setup() { |
389 |
- use python && python-single-r1_pkg_setup |
390 |
-} |
391 |
- |
392 |
-src_prepare() { |
393 |
- [[ -n ${RPM} ]] && rpm_spec_epatch "${WORKDIR}"/gdb.spec |
394 |
- ! use vanilla && [[ -n ${PATCH_VER} ]] && EPATCH_SUFFIX="patch" epatch "${WORKDIR}"/patch |
395 |
- |
396 |
- default |
397 |
- |
398 |
- strip-linguas -u bfd/po opcodes/po |
399 |
-} |
400 |
- |
401 |
-gdb_branding() { |
402 |
- printf "Gentoo ${PV} " |
403 |
- if ! use vanilla && [[ -n ${PATCH_VER} ]] ; then |
404 |
- printf "p${PATCH_VER}" |
405 |
- else |
406 |
- printf "vanilla" |
407 |
- fi |
408 |
- [[ -n ${EGIT_COMMIT} ]] && printf " ${EGIT_COMMIT}" |
409 |
-} |
410 |
- |
411 |
-src_configure() { |
412 |
- strip-unsupported-flags |
413 |
- |
414 |
- local myconf=( |
415 |
- --with-pkgversion="$(gdb_branding)" |
416 |
- --with-bugurl='https://bugs.gentoo.org/' |
417 |
- --disable-werror |
418 |
- # Disable modules that are in a combined binutils/gdb tree. #490566 |
419 |
- --disable-{binutils,etc,gas,gold,gprof,ld} |
420 |
- ) |
421 |
- local sysroot="${EPREFIX}/usr/${CTARGET}" |
422 |
- is_cross && myconf+=( |
423 |
- --with-sysroot="${sysroot}" |
424 |
- --includedir="${sysroot}/usr/include" |
425 |
- --with-gdb-datadir="\${datadir}/gdb/${CTARGET}" |
426 |
- ) |
427 |
- |
428 |
- if use server && ! use client ; then |
429 |
- # just configure+build in the gdbserver subdir to speed things up |
430 |
- cd gdb/gdbserver |
431 |
- myconf+=( --program-transform-name='' ) |
432 |
- else |
433 |
- # gdbserver only works for native targets (CHOST==CTARGET). |
434 |
- # it also doesn't support all targets, so rather than duplicate |
435 |
- # the target list (which changes between versions), use the |
436 |
- # "auto" value when things are turned on. |
437 |
- is_cross \ |
438 |
- && myconf+=( --disable-gdbserver ) \ |
439 |
- || myconf+=( $(use_enable server gdbserver auto) ) |
440 |
- fi |
441 |
- |
442 |
- if ! ( use server && ! use client ) ; then |
443 |
- # if we are configuring in the top level, then use all |
444 |
- # the additional global options |
445 |
- myconf+=( |
446 |
- --enable-64-bit-bfd |
447 |
- --disable-install-libbfd |
448 |
- --disable-install-libiberty |
449 |
- # Disable guile for now as it requires guile-2.x #562902 |
450 |
- --without-guile |
451 |
- # This only disables building in the readline subdir. |
452 |
- # For gdb itself, it'll use the system version. |
453 |
- --disable-readline |
454 |
- --with-system-readline |
455 |
- # This only disables building in the zlib subdir. |
456 |
- # For gdb itself, it'll use the system version. |
457 |
- --without-zlib |
458 |
- --with-system-zlib |
459 |
- --with-separate-debug-dir="${EPREFIX}"/usr/lib/debug |
460 |
- $(use_with xml expat) |
461 |
- $(use_with lzma) |
462 |
- $(use_enable nls) |
463 |
- $(use multitarget && echo --enable-targets=all) |
464 |
- $(use_with python python "${EPYTHON}") |
465 |
- ) |
466 |
- fi |
467 |
- if use sparc-solaris || use x86-solaris ; then |
468 |
- # disable largefile support |
469 |
- # https://sourceware.org/ml/gdb-patches/2014-12/msg00058.html |
470 |
- myconf+=( --disable-largefile ) |
471 |
- fi |
472 |
- |
473 |
- econf "${myconf[@]}" |
474 |
-} |
475 |
- |
476 |
-src_test() { |
477 |
- nonfatal emake check || ewarn "tests failed" |
478 |
-} |
479 |
- |
480 |
-src_install() { |
481 |
- if use server && ! use client; then |
482 |
- cd gdb/gdbserver || die |
483 |
- fi |
484 |
- default |
485 |
- if use client; then |
486 |
- find "${ED}"/usr -name libiberty.a -delete || die |
487 |
- fi |
488 |
- cd "${S}" || die |
489 |
- |
490 |
- # Delete translations that conflict with binutils-libs. #528088 |
491 |
- # Note: Should figure out how to store these in an internal gdb dir. |
492 |
- if use nls ; then |
493 |
- find "${ED}" \ |
494 |
- -regextype posix-extended -regex '.*/(bfd|opcodes)[.]g?mo$' \ |
495 |
- -delete || die |
496 |
- fi |
497 |
- |
498 |
- # Don't install docs when building a cross-gdb |
499 |
- if [[ ${CTARGET} != ${CHOST} ]] ; then |
500 |
- rm -rf "${ED}"/usr/share/{doc,info,locale} || die |
501 |
- local f |
502 |
- for f in "${ED}"/usr/share/man/*/* ; do |
503 |
- if [[ ${f##*/} != ${CTARGET}-* ]] ; then |
504 |
- mv "${f}" "${f%/*}/${CTARGET}-${f##*/}" || die |
505 |
- fi |
506 |
- done |
507 |
- return 0 |
508 |
- fi |
509 |
- # Install it by hand for now: |
510 |
- # https://sourceware.org/ml/gdb-patches/2011-12/msg00915.html |
511 |
- # Only install if it exists due to the twisted behavior (see |
512 |
- # notes in src_configure above). |
513 |
- [[ -e gdb/gdbserver/gdbreplay ]] && dobin gdb/gdbserver/gdbreplay |
514 |
- |
515 |
- if use client ; then |
516 |
- docinto gdb |
517 |
- dodoc gdb/CONTRIBUTE gdb/README gdb/MAINTAINERS \ |
518 |
- gdb/NEWS gdb/ChangeLog gdb/PROBLEMS |
519 |
- fi |
520 |
- docinto sim |
521 |
- dodoc sim/{ChangeLog,MAINTAINERS,README-HACKING} |
522 |
- if use server ; then |
523 |
- docinto gdbserver |
524 |
- dodoc gdb/gdbserver/{ChangeLog,README} |
525 |
- fi |
526 |
- |
527 |
- if [[ -n ${PATCH_VER} ]] ; then |
528 |
- dodoc "${WORKDIR}"/extra/gdbinit.sample |
529 |
- fi |
530 |
- |
531 |
- # Remove shared info pages |
532 |
- rm -f "${ED}"/usr/share/info/{annotate,bfd,configure,standards}.info* |
533 |
-} |
534 |
- |
535 |
-pkg_postinst() { |
536 |
- # portage sucks and doesnt unmerge files in /etc |
537 |
- rm -vf "${EROOT}"/etc/skel/.gdbinit |
538 |
- |
539 |
- if use prefix && [[ ${CHOST} == *-darwin* ]] ; then |
540 |
- ewarn "gdb is unable to get a mach task port when installed by Prefix" |
541 |
- ewarn "Portage, unprivileged. To make gdb fully functional you'll" |
542 |
- ewarn "have to perform the following steps:" |
543 |
- ewarn " % sudo chgrp procmod ${EPREFIX}/usr/bin/gdb" |
544 |
- ewarn " % sudo chmod g+s ${EPREFIX}/usr/bin/gdb" |
545 |
- fi |
546 |
-} |
547 |
|
548 |
diff --git a/sys-devel/gdb/gdb-8.0.ebuild b/sys-devel/gdb/gdb-8.0.ebuild |
549 |
deleted file mode 100644 |
550 |
index 00cf26e3bc6..00000000000 |
551 |
--- a/sys-devel/gdb/gdb-8.0.ebuild |
552 |
+++ /dev/null |
553 |
@@ -1,242 +0,0 @@ |
554 |
-# Copyright 1999-2018 Gentoo Foundation |
555 |
-# Distributed under the terms of the GNU General Public License v2 |
556 |
- |
557 |
-EAPI=6 |
558 |
-PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} ) |
559 |
- |
560 |
-inherit epatch eutils flag-o-matic python-single-r1 |
561 |
- |
562 |
-export CTARGET=${CTARGET:-${CHOST}} |
563 |
-if [[ ${CTARGET} == ${CHOST} ]] ; then |
564 |
- if [[ ${CATEGORY} == cross-* ]] ; then |
565 |
- export CTARGET=${CATEGORY#cross-} |
566 |
- fi |
567 |
-fi |
568 |
-is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } |
569 |
- |
570 |
-RPM= |
571 |
-MY_PV=${PV} |
572 |
-case ${PV} in |
573 |
-9999*) |
574 |
- # live git tree |
575 |
- EGIT_REPO_URI="git://sourceware.org/git/binutils-gdb.git" |
576 |
- inherit git-r3 |
577 |
- SRC_URI="" |
578 |
- ;; |
579 |
-*.*.50.2???????) |
580 |
- # weekly snapshots |
581 |
- SRC_URI="ftp://sourceware.org/pub/gdb/snapshots/current/gdb-weekly-${PV}.tar.xz" |
582 |
- ;; |
583 |
-*.*.*.*.*.*) |
584 |
- # fedora versions; note we swap the rpm & fedora core versions. |
585 |
- # gdb-6.8.50.20090302-8.fc11.src.rpm -> gdb-6.8.50.20090302.11.8.ebuild |
586 |
- # gdb-7.9-11.fc23.src.rpm -> gdb-7.9.23.11.ebuild |
587 |
- inherit versionator rpm |
588 |
- gvcr() { get_version_component_range "$@"; } |
589 |
- parse_fedora_ver() { |
590 |
- set -- $(get_version_components) |
591 |
- MY_PV=$(gvcr 1-$(( $# - 2 ))) |
592 |
- RPM="${PN}-${MY_PV}-$(gvcr $#).fc$(gvcr $(( $# - 1 ))).src.rpm" |
593 |
- } |
594 |
- parse_fedora_ver |
595 |
- SRC_URI="mirror://fedora-dev/development/rawhide/source/SRPMS/g/${RPM}" |
596 |
- ;; |
597 |
-*) |
598 |
- # Normal upstream release |
599 |
- SRC_URI="mirror://gnu/gdb/${P}.tar.xz |
600 |
- ftp://sourceware.org/pub/gdb/releases/${P}.tar.xz" |
601 |
- ;; |
602 |
-esac |
603 |
- |
604 |
-PATCH_VER="" |
605 |
-DESCRIPTION="GNU debugger" |
606 |
-HOMEPAGE="https://sourceware.org/gdb/" |
607 |
-SRC_URI="${SRC_URI} ${PATCH_VER:+mirror://gentoo/${P}-patches-${PATCH_VER}.tar.xz}" |
608 |
- |
609 |
-LICENSE="GPL-2 LGPL-2" |
610 |
-SLOT="0" |
611 |
-if [[ ${PV} != 9999* ]] ; then |
612 |
- # alpha #562128 |
613 |
- KEYWORDS="-alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
614 |
-fi |
615 |
-IUSE="+client lzma multitarget nls +python +server test vanilla xml" |
616 |
-REQUIRED_USE=" |
617 |
- python? ( ${PYTHON_REQUIRED_USE} ) |
618 |
- || ( client server ) |
619 |
-" |
620 |
- |
621 |
-RDEPEND="server? ( !dev-util/gdbserver ) |
622 |
- client? ( |
623 |
- >=sys-libs/ncurses-5.2-r2:0= |
624 |
- sys-libs/readline:0= |
625 |
- lzma? ( app-arch/xz-utils ) |
626 |
- python? ( ${PYTHON_DEPS} ) |
627 |
- xml? ( dev-libs/expat ) |
628 |
- sys-libs/zlib |
629 |
- )" |
630 |
-DEPEND="${RDEPEND} |
631 |
- app-arch/xz-utils |
632 |
- sys-apps/texinfo |
633 |
- client? ( |
634 |
- virtual/yacc |
635 |
- test? ( dev-util/dejagnu ) |
636 |
- nls? ( sys-devel/gettext ) |
637 |
- )" |
638 |
- |
639 |
-S=${WORKDIR}/${PN}-${MY_PV} |
640 |
- |
641 |
-pkg_setup() { |
642 |
- use python && python-single-r1_pkg_setup |
643 |
-} |
644 |
- |
645 |
-src_prepare() { |
646 |
- [[ -n ${RPM} ]] && rpm_spec_epatch "${WORKDIR}"/gdb.spec |
647 |
- ! use vanilla && [[ -n ${PATCH_VER} ]] && EPATCH_SUFFIX="patch" epatch "${WORKDIR}"/patch |
648 |
- |
649 |
- default |
650 |
- |
651 |
- strip-linguas -u bfd/po opcodes/po |
652 |
-} |
653 |
- |
654 |
-gdb_branding() { |
655 |
- printf "Gentoo ${PV} " |
656 |
- if ! use vanilla && [[ -n ${PATCH_VER} ]] ; then |
657 |
- printf "p${PATCH_VER}" |
658 |
- else |
659 |
- printf "vanilla" |
660 |
- fi |
661 |
- [[ -n ${EGIT_COMMIT} ]] && printf " ${EGIT_COMMIT}" |
662 |
-} |
663 |
- |
664 |
-src_configure() { |
665 |
- strip-unsupported-flags |
666 |
- |
667 |
- local myconf=( |
668 |
- --with-pkgversion="$(gdb_branding)" |
669 |
- --with-bugurl='https://bugs.gentoo.org/' |
670 |
- --disable-werror |
671 |
- # Disable modules that are in a combined binutils/gdb tree. #490566 |
672 |
- --disable-{binutils,etc,gas,gold,gprof,ld} |
673 |
- ) |
674 |
- local sysroot="${EPREFIX}/usr/${CTARGET}" |
675 |
- is_cross && myconf+=( |
676 |
- --with-sysroot="${sysroot}" |
677 |
- --includedir="${sysroot}/usr/include" |
678 |
- --with-gdb-datadir="\${datadir}/gdb/${CTARGET}" |
679 |
- ) |
680 |
- |
681 |
- if use server && ! use client ; then |
682 |
- # just configure+build in the gdbserver subdir to speed things up |
683 |
- cd gdb/gdbserver |
684 |
- myconf+=( --program-transform-name='' ) |
685 |
- else |
686 |
- # gdbserver only works for native targets (CHOST==CTARGET). |
687 |
- # it also doesn't support all targets, so rather than duplicate |
688 |
- # the target list (which changes between versions), use the |
689 |
- # "auto" value when things are turned on. |
690 |
- is_cross \ |
691 |
- && myconf+=( --disable-gdbserver ) \ |
692 |
- || myconf+=( $(use_enable server gdbserver auto) ) |
693 |
- fi |
694 |
- |
695 |
- if ! ( use server && ! use client ) ; then |
696 |
- # if we are configuring in the top level, then use all |
697 |
- # the additional global options |
698 |
- myconf+=( |
699 |
- --enable-64-bit-bfd |
700 |
- --disable-install-libbfd |
701 |
- --disable-install-libiberty |
702 |
- # Disable guile for now as it requires guile-2.x #562902 |
703 |
- --without-guile |
704 |
- # This only disables building in the readline subdir. |
705 |
- # For gdb itself, it'll use the system version. |
706 |
- --disable-readline |
707 |
- --with-system-readline |
708 |
- # This only disables building in the zlib subdir. |
709 |
- # For gdb itself, it'll use the system version. |
710 |
- --without-zlib |
711 |
- --with-system-zlib |
712 |
- --with-separate-debug-dir="${EPREFIX}"/usr/lib/debug |
713 |
- $(use_with xml expat) |
714 |
- $(use_with lzma) |
715 |
- $(use_enable nls) |
716 |
- $(use multitarget && echo --enable-targets=all) |
717 |
- $(use_with python python "${EPYTHON}") |
718 |
- ) |
719 |
- fi |
720 |
- if use sparc-solaris || use x86-solaris ; then |
721 |
- # disable largefile support |
722 |
- # https://sourceware.org/ml/gdb-patches/2014-12/msg00058.html |
723 |
- myconf+=( --disable-largefile ) |
724 |
- fi |
725 |
- |
726 |
- econf "${myconf[@]}" |
727 |
-} |
728 |
- |
729 |
-src_test() { |
730 |
- nonfatal emake check || ewarn "tests failed" |
731 |
-} |
732 |
- |
733 |
-src_install() { |
734 |
- use server && ! use client && cd gdb/gdbserver |
735 |
- default |
736 |
- use client && find "${ED}"/usr -name libiberty.a -delete |
737 |
- cd "${S}" |
738 |
- |
739 |
- # Delete translations that conflict with binutils-libs. #528088 |
740 |
- # Note: Should figure out how to store these in an internal gdb dir. |
741 |
- if use nls ; then |
742 |
- find "${ED}" \ |
743 |
- -regextype posix-extended -regex '.*/(bfd|opcodes)[.]g?mo$' \ |
744 |
- -delete |
745 |
- fi |
746 |
- |
747 |
- # Don't install docs when building a cross-gdb |
748 |
- if [[ ${CTARGET} != ${CHOST} ]] ; then |
749 |
- rm -r "${ED}"/usr/share/{doc,info,locale} |
750 |
- local f |
751 |
- for f in "${ED}"/usr/share/man/*/* ; do |
752 |
- if [[ ${f##*/} != ${CTARGET}-* ]] ; then |
753 |
- mv "${f}" "${f%/*}/${CTARGET}-${f##*/}" || die |
754 |
- fi |
755 |
- done |
756 |
- return 0 |
757 |
- fi |
758 |
- # Install it by hand for now: |
759 |
- # https://sourceware.org/ml/gdb-patches/2011-12/msg00915.html |
760 |
- # Only install if it exists due to the twisted behavior (see |
761 |
- # notes in src_configure above). |
762 |
- [[ -e gdb/gdbserver/gdbreplay ]] && dobin gdb/gdbserver/gdbreplay |
763 |
- |
764 |
- if use client ; then |
765 |
- docinto gdb |
766 |
- dodoc gdb/CONTRIBUTE gdb/README gdb/MAINTAINERS \ |
767 |
- gdb/NEWS gdb/ChangeLog gdb/PROBLEMS |
768 |
- fi |
769 |
- docinto sim |
770 |
- dodoc sim/{ChangeLog,MAINTAINERS,README-HACKING} |
771 |
- if use server ; then |
772 |
- docinto gdbserver |
773 |
- dodoc gdb/gdbserver/{ChangeLog,README} |
774 |
- fi |
775 |
- |
776 |
- if [[ -n ${PATCH_VER} ]] ; then |
777 |
- dodoc "${WORKDIR}"/extra/gdbinit.sample |
778 |
- fi |
779 |
- |
780 |
- # Remove shared info pages |
781 |
- rm -f "${ED}"/usr/share/info/{annotate,bfd,configure,standards}.info* |
782 |
-} |
783 |
- |
784 |
-pkg_postinst() { |
785 |
- # portage sucks and doesnt unmerge files in /etc |
786 |
- rm -vf "${EROOT}"/etc/skel/.gdbinit |
787 |
- |
788 |
- if use prefix && [[ ${CHOST} == *-darwin* ]] ; then |
789 |
- ewarn "gdb is unable to get a mach task port when installed by Prefix" |
790 |
- ewarn "Portage, unprivileged. To make gdb fully functional you'll" |
791 |
- ewarn "have to perform the following steps:" |
792 |
- ewarn " % sudo chgrp procmod ${EPREFIX}/usr/bin/gdb" |
793 |
- ewarn " % sudo chmod g+s ${EPREFIX}/usr/bin/gdb" |
794 |
- fi |
795 |
-} |
796 |
|
797 |
diff --git a/sys-devel/gdb/gdb-8.1.ebuild b/sys-devel/gdb/gdb-8.1.ebuild |
798 |
deleted file mode 100644 |
799 |
index 9b9a504a17b..00000000000 |
800 |
--- a/sys-devel/gdb/gdb-8.1.ebuild |
801 |
+++ /dev/null |
802 |
@@ -1,254 +0,0 @@ |
803 |
-# Copyright 1999-2018 Gentoo Foundation |
804 |
-# Distributed under the terms of the GNU General Public License v2 |
805 |
- |
806 |
-EAPI=6 |
807 |
-PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} ) |
808 |
- |
809 |
-inherit epatch eutils flag-o-matic python-single-r1 |
810 |
- |
811 |
-export CTARGET=${CTARGET:-${CHOST}} |
812 |
-if [[ ${CTARGET} == ${CHOST} ]] ; then |
813 |
- if [[ ${CATEGORY} == cross-* ]] ; then |
814 |
- export CTARGET=${CATEGORY#cross-} |
815 |
- fi |
816 |
-fi |
817 |
-is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; } |
818 |
- |
819 |
-RPM= |
820 |
-MY_PV=${PV} |
821 |
-case ${PV} in |
822 |
-9999*) |
823 |
- # live git tree |
824 |
- EGIT_REPO_URI="git://sourceware.org/git/binutils-gdb.git" |
825 |
- inherit git-r3 |
826 |
- SRC_URI="" |
827 |
- ;; |
828 |
-*.*.50.2???????) |
829 |
- # weekly snapshots |
830 |
- SRC_URI="ftp://sourceware.org/pub/gdb/snapshots/current/gdb-weekly-${PV}.tar.xz" |
831 |
- ;; |
832 |
-*.*.*.*.*.*) |
833 |
- # fedora versions; note we swap the rpm & fedora core versions. |
834 |
- # gdb-6.8.50.20090302-8.fc11.src.rpm -> gdb-6.8.50.20090302.11.8.ebuild |
835 |
- # gdb-7.9-11.fc23.src.rpm -> gdb-7.9.23.11.ebuild |
836 |
- inherit versionator rpm |
837 |
- gvcr() { get_version_component_range "$@"; } |
838 |
- parse_fedora_ver() { |
839 |
- set -- $(get_version_components) |
840 |
- MY_PV=$(gvcr 1-$(( $# - 2 ))) |
841 |
- RPM="${PN}-${MY_PV}-$(gvcr $#).fc$(gvcr $(( $# - 1 ))).src.rpm" |
842 |
- } |
843 |
- parse_fedora_ver |
844 |
- SRC_URI="mirror://fedora-dev/development/rawhide/source/SRPMS/g/${RPM}" |
845 |
- ;; |
846 |
-*) |
847 |
- # Normal upstream release |
848 |
- SRC_URI="mirror://gnu/gdb/${P}.tar.xz |
849 |
- ftp://sourceware.org/pub/gdb/releases/${P}.tar.xz" |
850 |
- ;; |
851 |
-esac |
852 |
- |
853 |
-PATCH_VER="1" |
854 |
-PATCH_DEV="slyfox" |
855 |
-DESCRIPTION="GNU debugger" |
856 |
-HOMEPAGE="https://sourceware.org/gdb/" |
857 |
-SRC_URI="${SRC_URI} |
858 |
- ${PATCH_DEV:+https://dev.gentoo.org/~${PATCH_DEV}/distfiles/${PN}-8.1-patches-${PATCH_VER}.tar.xz} |
859 |
- ${PATCH_VER:+mirror://gentoo/${PN}-8.1-patches-${PATCH_VER}.tar.xz} |
860 |
-" |
861 |
- |
862 |
-LICENSE="GPL-2 LGPL-2" |
863 |
-SLOT="0" |
864 |
-if [[ ${PV} != 9999* ]] ; then |
865 |
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
866 |
-fi |
867 |
-IUSE="+client lzma multitarget nls +python +server test vanilla xml" |
868 |
-REQUIRED_USE=" |
869 |
- python? ( ${PYTHON_REQUIRED_USE} ) |
870 |
- || ( client server ) |
871 |
-" |
872 |
- |
873 |
-RDEPEND="server? ( !dev-util/gdbserver ) |
874 |
- client? ( |
875 |
- >=sys-libs/ncurses-5.2-r2:0= |
876 |
- sys-libs/readline:0= |
877 |
- lzma? ( app-arch/xz-utils ) |
878 |
- python? ( ${PYTHON_DEPS} ) |
879 |
- xml? ( dev-libs/expat ) |
880 |
- sys-libs/zlib |
881 |
- )" |
882 |
-DEPEND="${RDEPEND} |
883 |
- app-arch/xz-utils |
884 |
- sys-apps/texinfo |
885 |
- client? ( |
886 |
- virtual/yacc |
887 |
- test? ( dev-util/dejagnu ) |
888 |
- nls? ( sys-devel/gettext ) |
889 |
- )" |
890 |
- |
891 |
-S=${WORKDIR}/${PN}-${MY_PV} |
892 |
- |
893 |
-pkg_setup() { |
894 |
- use python && python-single-r1_pkg_setup |
895 |
-} |
896 |
- |
897 |
-src_prepare() { |
898 |
- [[ -n ${RPM} ]] && rpm_spec_epatch "${WORKDIR}"/gdb.spec |
899 |
- ! use vanilla && [[ -n ${PATCH_VER} ]] && EPATCH_SUFFIX="patch" epatch "${WORKDIR}"/patch |
900 |
- |
901 |
- default |
902 |
- |
903 |
- strip-linguas -u bfd/po opcodes/po |
904 |
-} |
905 |
- |
906 |
-gdb_branding() { |
907 |
- printf "Gentoo ${PV} " |
908 |
- if ! use vanilla && [[ -n ${PATCH_VER} ]] ; then |
909 |
- printf "p${PATCH_VER}" |
910 |
- else |
911 |
- printf "vanilla" |
912 |
- fi |
913 |
- [[ -n ${EGIT_COMMIT} ]] && printf " ${EGIT_COMMIT}" |
914 |
-} |
915 |
- |
916 |
-src_configure() { |
917 |
- strip-unsupported-flags |
918 |
- |
919 |
- local myconf=( |
920 |
- --with-pkgversion="$(gdb_branding)" |
921 |
- --with-bugurl='https://bugs.gentoo.org/' |
922 |
- --disable-werror |
923 |
- # Disable modules that are in a combined binutils/gdb tree. #490566 |
924 |
- --disable-{binutils,etc,gas,gold,gprof,ld} |
925 |
- ) |
926 |
- local sysroot="${EPREFIX}/usr/${CTARGET}" |
927 |
- is_cross && myconf+=( |
928 |
- --with-sysroot="${sysroot}" |
929 |
- --includedir="${sysroot}/usr/include" |
930 |
- --with-gdb-datadir="\${datadir}/gdb/${CTARGET}" |
931 |
- ) |
932 |
- |
933 |
- if use server && ! use client ; then |
934 |
- # just configure+build in the gdbserver subdir to speed things up |
935 |
- cd gdb/gdbserver |
936 |
- myconf+=( --program-transform-name='' ) |
937 |
- else |
938 |
- # gdbserver only works for native targets (CHOST==CTARGET). |
939 |
- # it also doesn't support all targets, so rather than duplicate |
940 |
- # the target list (which changes between versions), use the |
941 |
- # "auto" value when things are turned on. |
942 |
- is_cross \ |
943 |
- && myconf+=( --disable-gdbserver ) \ |
944 |
- || myconf+=( $(use_enable server gdbserver auto) ) |
945 |
- fi |
946 |
- |
947 |
- if ! ( use server && ! use client ) ; then |
948 |
- # if we are configuring in the top level, then use all |
949 |
- # the additional global options |
950 |
- myconf+=( |
951 |
- --enable-64-bit-bfd |
952 |
- --disable-install-libbfd |
953 |
- --disable-install-libiberty |
954 |
- # Disable guile for now as it requires guile-2.x #562902 |
955 |
- --without-guile |
956 |
- # This only disables building in the readline subdir. |
957 |
- # For gdb itself, it'll use the system version. |
958 |
- --disable-readline |
959 |
- --with-system-readline |
960 |
- # This only disables building in the zlib subdir. |
961 |
- # For gdb itself, it'll use the system version. |
962 |
- --without-zlib |
963 |
- --with-system-zlib |
964 |
- --with-separate-debug-dir="${EPREFIX}"/usr/lib/debug |
965 |
- $(use_with xml expat) |
966 |
- $(use_with lzma) |
967 |
- $(use_enable nls) |
968 |
- $(use multitarget && echo --enable-targets=all) |
969 |
- $(use_with python python "${EPYTHON}") |
970 |
- ) |
971 |
- fi |
972 |
- if use sparc-solaris || use x86-solaris ; then |
973 |
- # disable largefile support |
974 |
- # https://sourceware.org/ml/gdb-patches/2014-12/msg00058.html |
975 |
- myconf+=( --disable-largefile ) |
976 |
- fi |
977 |
- |
978 |
- econf "${myconf[@]}" |
979 |
-} |
980 |
- |
981 |
-src_test() { |
982 |
- nonfatal emake check || ewarn "tests failed" |
983 |
-} |
984 |
- |
985 |
-src_install() { |
986 |
- if use server && ! use client; then |
987 |
- cd gdb/gdbserver || die |
988 |
- fi |
989 |
- default |
990 |
- if use client; then |
991 |
- find "${ED}"/usr -name libiberty.a -delete || die |
992 |
- fi |
993 |
- cd "${S}" || die |
994 |
- |
995 |
- # Delete translations that conflict with binutils-libs. #528088 |
996 |
- # Note: Should figure out how to store these in an internal gdb dir. |
997 |
- if use nls ; then |
998 |
- find "${ED}" \ |
999 |
- -regextype posix-extended -regex '.*/(bfd|opcodes)[.]g?mo$' \ |
1000 |
- -delete || die |
1001 |
- fi |
1002 |
- |
1003 |
- # Don't install docs when building a cross-gdb |
1004 |
- if [[ ${CTARGET} != ${CHOST} ]] ; then |
1005 |
- rm -rf "${ED}"/usr/share/{doc,info,locale} || die |
1006 |
- local f |
1007 |
- for f in "${ED}"/usr/share/man/*/* ; do |
1008 |
- if [[ ${f##*/} != ${CTARGET}-* ]] ; then |
1009 |
- mv "${f}" "${f%/*}/${CTARGET}-${f##*/}" || die |
1010 |
- fi |
1011 |
- done |
1012 |
- return 0 |
1013 |
- fi |
1014 |
- # Install it by hand for now: |
1015 |
- # https://sourceware.org/ml/gdb-patches/2011-12/msg00915.html |
1016 |
- # Only install if it exists due to the twisted behavior (see |
1017 |
- # notes in src_configure above). |
1018 |
- [[ -e gdb/gdbserver/gdbreplay ]] && dobin gdb/gdbserver/gdbreplay |
1019 |
- |
1020 |
- if use client ; then |
1021 |
- docinto gdb |
1022 |
- dodoc gdb/CONTRIBUTE gdb/README gdb/MAINTAINERS \ |
1023 |
- gdb/NEWS gdb/ChangeLog gdb/PROBLEMS |
1024 |
- fi |
1025 |
- docinto sim |
1026 |
- dodoc sim/{ChangeLog,MAINTAINERS,README-HACKING} |
1027 |
- if use server ; then |
1028 |
- docinto gdbserver |
1029 |
- dodoc gdb/gdbserver/{ChangeLog,README} |
1030 |
- fi |
1031 |
- |
1032 |
- if [[ -n ${PATCH_VER} ]] ; then |
1033 |
- dodoc "${WORKDIR}"/extra/gdbinit.sample |
1034 |
- fi |
1035 |
- |
1036 |
- # Remove shared info pages |
1037 |
- rm -f "${ED}"/usr/share/info/{annotate,bfd,configure,standards}.info* |
1038 |
- |
1039 |
- # gcore is part of ubin on freebsd |
1040 |
- if [[ ${CHOST} == *-freebsd* ]]; then |
1041 |
- rm "${ED}"/usr/bin/gcore || die |
1042 |
- fi |
1043 |
-} |
1044 |
- |
1045 |
-pkg_postinst() { |
1046 |
- # portage sucks and doesnt unmerge files in /etc |
1047 |
- rm -vf "${EROOT}"/etc/skel/.gdbinit |
1048 |
- |
1049 |
- if use prefix && [[ ${CHOST} == *-darwin* ]] ; then |
1050 |
- ewarn "gdb is unable to get a mach task port when installed by Prefix" |
1051 |
- ewarn "Portage, unprivileged. To make gdb fully functional you'll" |
1052 |
- ewarn "have to perform the following steps:" |
1053 |
- ewarn " % sudo chgrp procmod ${EPREFIX}/usr/bin/gdb" |
1054 |
- ewarn " % sudo chmod g+s ${EPREFIX}/usr/bin/gdb" |
1055 |
- fi |
1056 |
-} |