commit:     e78f8bdb713aabc1a135f6dba9def7da7a373360
Author:     Arsen Arsenović <arsen <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 18 00:30:48 2023 +0000
Commit:     Arsen Arsenović <arsen <AT> gentoo <DOT> org>
CommitDate: Wed Jul 19 21:44:26 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e78f8bdb

sys-devel/gdb: add debuginfod support

Closes: https://github.com/gentoo/gentoo/pull/31941
Signed-off-by: Arsen Arsenović <arsen <AT> gentoo.org>

 sys-devel/gdb/{gdb-9999.ebuild => gdb-13.2-r2.ebuild} | 10 ++++++----
 sys-devel/gdb/gdb-9999.ebuild                         |  9 +++++----
 sys-devel/gdb/metadata.xml                            |  1 +
 3 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/sys-devel/gdb/gdb-9999.ebuild b/sys-devel/gdb/gdb-13.2-r2.ebuild
similarity index 97%
copy from sys-devel/gdb/gdb-9999.ebuild
copy to sys-devel/gdb/gdb-13.2-r2.ebuild
index f234645144c8..0d8c5729c3d2 100644
--- a/sys-devel/gdb/gdb-9999.ebuild
+++ b/sys-devel/gdb/gdb-13.2-r2.ebuild
@@ -72,7 +72,7 @@ SRC_URI="
 
 LICENSE="GPL-3+ LGPL-2.1+"
 SLOT="0"
-IUSE="cet guile lzma multitarget nls +python +server sim source-highlight test 
vanilla xml xxhash zstd"
+IUSE="cet debuginfod guile lzma multitarget nls +python +server sim 
source-highlight test vanilla xml xxhash zstd"
 if [[ -n ${REGULAR_RELEASE} ]] ; then
        KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc 
~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
 fi
@@ -86,6 +86,9 @@ RDEPEND="
        >=sys-libs/readline-7:=
        sys-libs/zlib
        elibc_glibc? ( net-libs/libnsl:= )
+       debuginfod? (
+               dev-libs/elfutils[debuginfod(-)]
+       )
        lzma? ( app-arch/xz-utils )
        python? ( ${PYTHON_DEPS} )
        guile? ( >=dev-scheme/guile-2.0 )
@@ -110,6 +113,7 @@ BDEPEND="
 
 PATCHES=(
        "${FILESDIR}"/${PN}-8.3.1-verbose-build.patch
+       "${FILESDIR}"/${P}-fix-sparc-debugging.patch
 )
 
 pkg_setup() {
@@ -158,9 +162,7 @@ src_configure() {
                # Disable modules that are in a combined binutils/gdb tree. bug 
#490566
                --disable-{binutils,etc,gas,gold,gprof,gprofng,ld}
 
-               # avoid automagic dependency on (currently prefix) systems
-               # systems with debuginfod library, bug #754753
-               --without-debuginfod
+               $(use_with debuginfod)
 
                $(use_enable test unit-tests)
 

diff --git a/sys-devel/gdb/gdb-9999.ebuild b/sys-devel/gdb/gdb-9999.ebuild
index f234645144c8..a9932a210efe 100644
--- a/sys-devel/gdb/gdb-9999.ebuild
+++ b/sys-devel/gdb/gdb-9999.ebuild
@@ -72,7 +72,7 @@ SRC_URI="
 
 LICENSE="GPL-3+ LGPL-2.1+"
 SLOT="0"
-IUSE="cet guile lzma multitarget nls +python +server sim source-highlight test 
vanilla xml xxhash zstd"
+IUSE="cet debuginfod guile lzma multitarget nls +python +server sim 
source-highlight test vanilla xml xxhash zstd"
 if [[ -n ${REGULAR_RELEASE} ]] ; then
        KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc 
~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
 fi
@@ -86,6 +86,9 @@ RDEPEND="
        >=sys-libs/readline-7:=
        sys-libs/zlib
        elibc_glibc? ( net-libs/libnsl:= )
+       debuginfod? (
+               dev-libs/elfutils[debuginfod(-)]
+       )
        lzma? ( app-arch/xz-utils )
        python? ( ${PYTHON_DEPS} )
        guile? ( >=dev-scheme/guile-2.0 )
@@ -158,9 +161,7 @@ src_configure() {
                # Disable modules that are in a combined binutils/gdb tree. bug 
#490566
                --disable-{binutils,etc,gas,gold,gprof,gprofng,ld}
 
-               # avoid automagic dependency on (currently prefix) systems
-               # systems with debuginfod library, bug #754753
-               --without-debuginfod
+               $(use_with debuginfod)
 
                $(use_enable test unit-tests)
 

diff --git a/sys-devel/gdb/metadata.xml b/sys-devel/gdb/metadata.xml
index 5baff33ff49e..2e08f18a3470 100644
--- a/sys-devel/gdb/metadata.xml
+++ b/sys-devel/gdb/metadata.xml
@@ -15,6 +15,7 @@
                <flag name="source-highlight">Enable listing highlighting via 
<pkg>dev-util/source-highlight</pkg></flag>
                <flag name="xml">Support parsing XML data files needed (at 
least) for cpu features, memory maps, and syscall tracing</flag>
                <flag name="xxhash">Use <pkg>dev-libs/xxhash</pkg> to speed up 
internal hashing.</flag>
+               <flag name="debuginfod">Enable debuginfod support via 
<pkg>dev-libs/elfutils</pkg> libdebuginfod</flag>
        </use>
        <upstream>
                <remote-id type="cpe">cpe:/a:gnu:gdb</remote-id>

Reply via email to