]> code.ossystems Code Review - openembedded-core.git/commitdiff
gdb-cross: enable debuginfod
authorAlexander Kanavin <alex.kanavin@gmail.com>
Tue, 15 Jun 2021 08:12:11 +0000 (10:12 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 17 Jun 2021 12:41:56 +0000 (13:41 +0100)
This allows avoiding having gdb inside the target image, which might
be too resource-constrained, or otherwise inconvenient.

Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/gdb/gdb-cross-canadian.inc
meta/recipes-devtools/gdb/gdb-cross.inc

index c9daf25a41715794d43edfae7559f7286c92828e..edb05b6f1803d06a6ff857bcbdd074304beffbc5 100644 (file)
@@ -11,12 +11,13 @@ DEPENDS = "nativesdk-ncurses nativesdk-expat nativesdk-gettext \
 GDBPROPREFIX = "--program-prefix='${TARGET_PREFIX}'"
 
 # Overrides PACKAGECONFIG variables in gdb-common.inc
-PACKAGECONFIG ??= "python readline"
+PACKAGECONFIG ??= "python readline ${@bb.utils.filter('DISTRO_FEATURES', 'debuginfod', d)}"
 PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,nativesdk-python3, \
                          nativesdk-python3-core \
                          nativesdk-python3-codecs nativesdk-python3-netclient \
                          "
 PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,nativesdk-readline"
+PACKAGECONFIG[debuginfod] = "--with-debuginfod, --without-debuginfod, nativesdk-elfutils"
 
 SSTATE_DUPWHITELIST += "${STAGING_DATADIR}/gdb"
 
index ebe329f6d3b1ca506f4feead6a0cdc98fd146f72..f8a113da8f6cf53634c4eb1968d158ad48462419 100644 (file)
@@ -5,9 +5,10 @@ DEPENDS = "expat-native ncurses-native flex-native bison-native"
 inherit python3native
 
 # Overrides PACKAGECONFIG variables in gdb-common.inc
-PACKAGECONFIG ??= "python readline"
+PACKAGECONFIG ??= "python readline ${@bb.utils.filter('DISTRO_FEATURES', 'debuginfod', d)}"
 PACKAGECONFIG[python] = "--with-python=${PYTHON},--without-python,python3-native"
 PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,readline-native"
+PACKAGECONFIG[debuginfod] = "--with-debuginfod, --without-debuginfod, elfutils-native"
 
 do_compile_prepend() {
     export STAGING_LIBDIR="${STAGING_LIBDIR_NATIVE}"