summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-12-31 09:43:19 +0000
committerMike Frysinger <vapier@gentoo.org>2011-12-31 09:43:19 +0000
commitb52af3fbc339f7033f85cdedd9d8ad842979cbab (patch)
tree25b092c184d04de6836bb3540aea24b5d06a376d /sys-devel/gdb
parentStable for AMD64, wrt bug #396515 (diff)
downloadhistorical-b52af3fbc339f7033f85cdedd9d8ad842979cbab.tar.gz
historical-b52af3fbc339f7033f85cdedd9d8ad842979cbab.tar.bz2
historical-b52af3fbc339f7033f85cdedd9d8ad842979cbab.zip
Add USE=client/server support, and fix up the install of helper libraries.
Package-Manager: portage-2.2.0_alpha81/cvs/Linux x86_64
Diffstat (limited to 'sys-devel/gdb')
-rw-r--r--sys-devel/gdb/ChangeLog8
-rw-r--r--sys-devel/gdb/Manifest23
-rw-r--r--sys-devel/gdb/gdb-7.3.1-r1.ebuild170
-rw-r--r--sys-devel/gdb/metadata.xml2
4 files changed, 196 insertions, 7 deletions
diff --git a/sys-devel/gdb/ChangeLog b/sys-devel/gdb/ChangeLog
index 5bb91ffd6195..2b14c495d9fc 100644
--- a/sys-devel/gdb/ChangeLog
+++ b/sys-devel/gdb/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sys-devel/gdb
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/gdb/ChangeLog,v 1.198 2011/12/29 18:48:27 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gdb/ChangeLog,v 1.199 2011/12/31 09:43:19 vapier Exp $
+
+*gdb-7.3.1-r1 (31 Dec 2011)
+
+ 31 Dec 2011; Mike Frysinger <vapier@gentoo.org> +gdb-7.3.1-r1.ebuild,
+ metadata.xml:
+ Add USE=client/server support, and fix up the install of helper libraries.
29 Dec 2011; Jeroen Roovers <jer@gentoo.org> gdb-7.3.1.ebuild:
Stable for HPPA (bug #395017).
diff --git a/sys-devel/gdb/Manifest b/sys-devel/gdb/Manifest
index 1462fabffb5f..45dc924bc000 100644
--- a/sys-devel/gdb/Manifest
+++ b/sys-devel/gdb/Manifest
@@ -27,15 +27,26 @@ EBUILD gdb-7.0.1.ebuild 2662 RMD160 b0b28b127070a76420944c4b33bed46f73bf79b3 SHA
EBUILD gdb-7.1.ebuild 2621 RMD160 11f84a78dbe93023ad5ee5cb726284f84bba8d3b SHA1 288f227938c607bc551e190a80a2e460e2be6e21 SHA256 46ba95a663ac81bfdb61b43f0b19ab05ae6f287fdd49a5174f492fe1cf5aca36
EBUILD gdb-7.2.50.20101117.4.15.ebuild 3089 RMD160 b6ecd83162d74f5977678a1b48625949a2ef897b SHA1 0b73196b1914b7a4aaebc07f96c20ab293bd80bc SHA256 8f4c0108099ddc82cafd77896a1fa1b07a30f0bfec02909d61a84b9b93b070fc
EBUILD gdb-7.2.ebuild 3498 RMD160 97d6ae6747660a07b8587d1c9bd92d99fb4261b4 SHA1 60236219e3e25cc8df44735fd45668d0b222e1d1 SHA256 72398724872bd5cd6c5a2b7d5881f8958bcc8958fdbcbb59e2772005cb964817
+EBUILD gdb-7.3.1-r1.ebuild 4455 RMD160 08f3e4c41890971428497e888252adf2fafecfdd SHA1 bd50c89da66259886a38ff3c3141b250f2781248 SHA256 8fe72111657b8172c58c3fc5825c800d1ddb7cd65e2aff7f59a00023844f3d0e
EBUILD gdb-7.3.1.ebuild 3887 RMD160 3c8edb3a2deea0ca7d9153bc17a86837f1470fe6 SHA1 5860f1f2476cc527ee0277d5cc29477718acebe4 SHA256 ffaac3abdfa456236a171eadb73350c46e3935598330c0f68de3ca6c88deac0a
EBUILD gdb-7.3.ebuild 3801 RMD160 59f24f3a7276a440fc4162863d52706febadea9b SHA1 a0a4aa9d51c7e5396d53e40536117b6c86277c30 SHA256 69aa29131061561ec60165e2f65e74a897ae2a5f51799ddce2c048a7a6606855
EBUILD gdb-9999.ebuild 3801 RMD160 e7ad051337c709d27a054496add98dfd0ae6c4d4 SHA1 558f566e9ca3759cb6fe5207824c93cc16544c88 SHA256 6f1274be5a450413e0e3397af32b767f8ee145083e2b4b45892ffe05d713b77d
-MISC ChangeLog 26310 RMD160 5f082f5667a3ec69d88781a007cf9d950d32740f SHA1 fd607936f3e2c161d15c0822dea5b1e9bca2cd32 SHA256 1c15527929f49b506a149aa7b75fa648736ebfbd4a3743a866569e0e7198be26
-MISC metadata.xml 372 RMD160 c3a62441fbad26523b3416ab2067e27bef252c12 SHA1 a84490ba53909470055928bc524759841bd8d7a6 SHA256 bfc04fb1d2f4c78fd5a766860966e4d5efa12c2eea2a49a952627a27644c9035
+MISC ChangeLog 26508 RMD160 b0709b5b894d0c586e26aba77e619575ac93c957 SHA1 24b3417708c588e27b7d93f925b27cdb577c9559 SHA256 12f8ac1a597eb657a9a744247c4dcf6209303ebb60f305d8edf854b61fbab273
+MISC metadata.xml 552 RMD160 05c46fb5af7dc382b5977a47dac90f077ddf7b68 SHA1 2aab7d540d4b18a618bf34d962c63ae9f7e18aed SHA256 e86791dadf315a7a079e460854bcc4a28d7c69a93694efc85014b325824b81cf
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.17 (GNU/Linux)
+Version: GnuPG v2.0.18 (GNU/Linux)
-iEYEARECAAYFAk78tgEACgkQVWmRsqeSphNMIQCfSSBzpjWHeaSNUXsDoagZfs9M
-KlcAnRYey/yeyaVqVISdy4iQmiWvA3JD
-=ttAP
+iQIcBAEBAgAGBQJO/tk9AAoJELEHsLL7fEFWAW8QAMWAQe8IYZIrBAElmvOhRRpG
+VxrFBy8bNtimThwW0iB6nOUXb8G297i8r+zdcLY5ZPZ0noQ+wA2ht414DOzbMGol
+WmWZdm/IQs6TnrcZ54yBxutunD2HvpEq8+6gPyVBFOGWOKvRobzGAwgGM3Yd0nZl
+wL4fuTMrBFe4KKltb1ss0zcMvOQV+hm27v72DFHUSCEw/A8VMXHQQexvp1gBZift
+QnieM9nRazO30pLG/UzC3+D+KvajAbfdBXhrlx0GioZz5y1NamByUmJmQayTzMHM
+3+nKScROKjL/UkeQ+3jQORDEW7b913Md6Ojmofmj+k0aq9thlDwVmVzaSNS9oPRg
+jMg/qEnb5tEvL9mBiCbGEagHfrj2+PeqNUXn69efKPzVzXg4CRmnArnKrXrPIVcf
+aEX6Ty7iDrN/CKXdLFWNhdS1y9WIK8CbciwN7vm0BYZSOOsQeEB6f38Ct6ImrOvY
+gnsLdj0mtCbSctJMmcm3brpNSWjedtWfrjJJ/P+NyRmX2TFkB/ukqpdrItC3uWk4
+z0td2G+mK7z+aNG8Lm1R8o1IQSnw11+TGlKrZlQSZDypRsrN2C3zGKvHIUxNM+sj
+0I2Mia+KSZ3DEVUO+YtGd1Th+NXBVVtAeME1+P+KkiGk8GDRH8iGad1WSPUNFE7E
+9lw7uri3w5VpjcsUkDxy
+=XzNU
-----END PGP SIGNATURE-----
diff --git a/sys-devel/gdb/gdb-7.3.1-r1.ebuild b/sys-devel/gdb/gdb-7.3.1-r1.ebuild
new file mode 100644
index 000000000000..1701dae6d462
--- /dev/null
+++ b/sys-devel/gdb/gdb-7.3.1-r1.ebuild
@@ -0,0 +1,170 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gdb/gdb-7.3.1-r1.ebuild,v 1.1 2011/12/31 09:43:19 vapier Exp $
+
+EAPI="3"
+
+inherit flag-o-matic eutils
+
+export CTARGET=${CTARGET:-${CHOST}}
+if [[ ${CTARGET} == ${CHOST} ]] ; then
+ if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
+ export CTARGET=${CATEGORY/cross-}
+ fi
+fi
+is_cross() { [[ ${CHOST} != ${CTARGET} ]] ; }
+
+RPM=
+MY_PV=${PV}
+case ${PV} in
+*.*.*.*.*.*)
+ # fedora version: gdb-6.8.50.20090302-8.fc11.src.rpm
+ inherit versionator rpm
+ gvcr() { get_version_component_range "$@"; }
+ MY_PV=$(gvcr 1-4)
+ RPM="${PN}-${MY_PV}-$(gvcr 5).fc$(gvcr 6).src.rpm"
+ SRC_URI="mirror://fedora/development/source/SRPMS/${RPM}"
+ ;;
+*.*.50.*)
+ # weekly snapshots
+ SRC_URI="ftp://sources.redhat.com/pub/gdb/snapshots/current/gdb-weekly-${PV}.tar.bz2"
+ ;;
+9999*)
+ # live git tree
+ EGIT_REPO_URI="git://sourceware.org/git/gdb.git"
+ inherit git-2
+ SRC_URI=""
+ ;;
+*)
+ # Normal upstream release
+ SRC_URI="http://ftp.gnu.org/gnu/gdb/${P}.tar.bz2
+ ftp://sources.redhat.com/pub/gdb/releases/${P}.tar.bz2"
+ ;;
+esac
+
+PATCH_VER="2"
+DESCRIPTION="GNU debugger"
+HOMEPAGE="http://sourceware.org/gdb/"
+SRC_URI="${SRC_URI} ${PATCH_VER:+mirror://gentoo/${P}-patches-${PATCH_VER}.tar.xz}"
+
+LICENSE="GPL-2 LGPL-2"
+is_cross \
+ && SLOT="${CTARGET}" \
+ || SLOT="0"
+if [[ ${PV} != 9999* ]] ; then
+ KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-aix ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+fi
+IUSE="+client expat multitarget nls +python +server test vanilla"
+
+RDEPEND="!dev-util/gdbserver
+ >=sys-libs/ncurses-5.2-r2
+ sys-libs/readline
+ expat? ( dev-libs/expat )
+ python? ( =dev-lang/python-2* )"
+DEPEND="${RDEPEND}
+ app-arch/xz-utils
+ virtual/yacc
+ test? ( dev-util/dejagnu )
+ nls? ( sys-devel/gettext )"
+
+S=${WORKDIR}/${PN}-${MY_PV}
+
+src_prepare() {
+ [[ -n ${RPM} ]] && rpm_spec_epatch "${WORKDIR}"/gdb.spec
+ use vanilla || [[ -n ${PATCH_VER} ]] && EPATCH_SUFFIX="patch" epatch "${WORKDIR}"/patch
+ strip-linguas -u bfd/po opcodes/po
+}
+
+gdb_branding() {
+ printf "Gentoo ${PV} "
+ if [[ -n ${PATCH_VER} ]] ; then
+ printf "p${PATCH_VER}"
+ else
+ printf "vanilla"
+ fi
+}
+
+src_configure() {
+ strip-unsupported-flags
+
+ local myconf=(
+ --with-pkgversion="$(gdb_branding)"
+ --with-bugurl='http://bugs.gentoo.org/'
+ --disable-werror
+ $(is_cross && echo --with-sysroot="${EPREFIX}"/usr/${CTARGET})
+ )
+
+ if use server ; then
+ use client || cd gdb/gdbserver
+ myconf+=( --program-transform-name='' )
+ fi
+
+ if use client ; then
+ myconf+=(
+ --enable-64-bit-bfd
+ --disable-install-libbfd
+ --disable-install-libiberty
+ --with-system-readline
+ --with-separate-debug-dir="${EPREFIX}"/usr/lib/debug
+ $(use_with expat)
+ $(use_enable nls)
+ $(use multitarget && echo --enable-targets=all)
+ $(use_with python python "${EPREFIX}/usr/bin/python2")
+ $(use_enable server gdbserver)
+ )
+ fi
+
+ econf "${myconf[@]}"
+}
+
+src_test() {
+ emake check || ewarn "tests failed"
+}
+
+src_install() {
+ use server && ! use client && cd gdb/gdbserver
+ emake DESTDIR="${D}" install || die
+ use client && { rm "${D}"/usr/lib*/libiberty.a || die ; }
+ cd "${S}"
+
+ # Don't install docs when building a cross-gdb
+ if [[ ${CTARGET} != ${CHOST} ]] ; then
+ rm -r "${ED}"/usr/share
+ return 0
+ fi
+ # http://sourceware.org/ml/gdb-patches/2011-12/msg00915.html
+ use server && { dobin gdb/gdbserver/gdbreplay || die ; }
+
+ dodoc README
+ if use client ; then
+ docinto gdb
+ dodoc gdb/CONTRIBUTE gdb/README gdb/MAINTAINERS \
+ gdb/NEWS gdb/ChangeLog gdb/PROBLEMS
+ fi
+ docinto sim
+ dodoc sim/{ChangeLog,MAINTAINERS,README-HACKING}
+ if use server ; then
+ docinto gdbserver
+ dodoc gdb/gdbserver/{ChangeLog,README}
+ fi
+
+ if [[ -n ${PATCH_VER} ]] ; then
+ dodoc "${WORKDIR}"/extra/gdbinit.sample
+ fi
+
+ # Remove shared info pages
+ rm -f "${ED}"/usr/share/info/{annotate,bfd,configure,standards}.info*
+}
+
+pkg_postinst() {
+ # portage sucks and doesnt unmerge files in /etc
+ rm -vf "${ROOT}"/etc/skel/.gdbinit
+
+ if use prefix && [[ ${CHOST} == *-darwin* ]] ; then
+ ewarn "gdb is unable to get a mach task port when installed by Prefix"
+ ewarn "Portage, unprivileged. To make gdb fully functional you'll"
+ ewarn "have to perform the following steps:"
+ ewarn " % sudo chgrp procmod ${EPREFIX}/usr/bin/gdb"
+ ewarn " % sudo chmod g+s ${EPREFIX}/usr/bin/gdb"
+ fi
+}
diff --git a/sys-devel/gdb/metadata.xml b/sys-devel/gdb/metadata.xml
index c3d01c553bcf..ab9c41a6cadc 100644
--- a/sys-devel/gdb/metadata.xml
+++ b/sys-devel/gdb/metadata.xml
@@ -3,7 +3,9 @@
<pkgmetadata>
<herd>toolchain</herd>
<use>
+ <flag name='client'>Install the main "gdb" program (most people want this)</flag>
<flag name='multitarget'>Support all known targets in one gdb binary</flag>
<flag name='python'>Enable support for the new internal scripting language, as well as extended pretty printers</flag>
+ <flag name='server'>Install the "gdbserver" program (useful for embedded/remote targets)</flag>
</use>
</pkgmetadata>