Skip to contentSkip to conversation

elfutils: split libdebuginfod into its own package

PATCH In review Dorinda 2 participants 4 messages Jan 21, 2021 – Jan 22, 2021

lore
Share & tools
lore

Dorinda

author
#0 lore raw

PATCH 1/3 elfutils: split libdebuginfod into its own package

add package options for libdebuginfod

---
 meta/recipes-devtools/elfutils/elfutils_0.181.bb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
meta/recipes-devtools/elfutils/elfutils_0.181.bb +3 -1
index 6c49a5fc26..c5bb62e961 100644
@@ -91,7 +91,7 @@ EXTRA_OEMAKE_class-nativesdk = ""
 BBCLASSEXTEND = "native nativesdk"
 
 # Package utilities separately
-PACKAGES =+ "${PN}-binutils libelf libasm libdw"
+PACKAGES =+ "${PN}-binutils libelf libasm libdw libdebuginfod"
 
 # shared libraries are licensed GPLv2 or GPLv3+, binaries GPLv3+
 # according to NEWS file:
@@ -103,6 +103,7 @@ LICENSE_${PN} = "GPLv3+"
 LICENSE_libelf = "GPLv2 | LGPLv3+"
 LICENSE_libasm = "GPLv2 | LGPLv3+"
 LICENSE_libdw = "GPLv2 | LGPLv3+"
+LICENSE_libdebuginfod = "GPLv2+ | LGPLv3+"
 
 FILES_${PN}-binutils = "\
     ${bindir}/eu-addr2line \
@@ -115,6 +116,7 @@ FILES_${PN}-binutils = "\
 FILES_libelf = "${libdir}/libelf-${PV}.so ${libdir}/libelf.so.*"
 FILES_libasm = "${libdir}/libasm-${PV}.so ${libdir}/libasm.so.*"
 FILES_libdw  = "${libdir}/libdw-${PV}.so ${libdir}/libdw.so.* ${libdir}/elfutils/lib*"
+FILES_libdebuginfod = "${libdir}/libdebuginfod-${PV}.so ${libdir}/libdebuginfod.so.*"
 # Some packages have the version preceeding the .so instead properly
 # versioned .so.<version>, so we need to reorder and repackage.
 #FILES_${PN} += "${libdir}/*-${PV}.so ${base_libdir}/*-${PV}.so"
Signature · 1 line
2.17.1
author
#1 lore raw

PATCH 2/3 elfutils: add PACKAGECONFIG for debuginfod

removed the config option that disabled debuginfod and enabled it with PACKAGECONFIG

---
 meta/recipes-devtools/elfutils/elfutils_0.181.bb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
meta/recipes-devtools/elfutils/elfutils_0.181.bb +3 -1
index c5bb62e961..c18de53b1e 100644
@@ -21,6 +21,7 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
            file://ptest.patch \
            file://0001-tests-Makefile.am-compile-test_nlist-with-standard-C.patch \
            "
+
 SRC_URI_append_libc-musl = " \
            file://0001-musl-obstack-fts.patch \
            file://0002-musl-libs.patch \
@@ -32,7 +33,7 @@ SRC_URI[sha256sum] = "29a6ad7421ec2acfee489bb4a699908281ead2cb63a20a027ce8804a16
 
 inherit autotools gettext ptest pkgconfig
 
-EXTRA_OECONF = "--program-prefix=eu- --disable-debuginfod"
+EXTRA_OECONF = "--program-prefix=eu-"
 
 DEPENDS_BZIP2 = "bzip2-replacement-native"
 DEPENDS_BZIP2_class-target = "bzip2"
@@ -41,6 +42,7 @@ PACKAGECONFIG ??= ""
 PACKAGECONFIG[bzip2] = "--with-bzlib,--without-bzlib,${DEPENDS_BZIP2}"
 PACKAGECONFIG[xz] = "--with-lzma,--without-lzma,xz"
 PACKAGECONFIG[libdebuginfod] = "--enable-libdebuginfod,--disable-libdebuginfod,curl"
+PACKAGECONFIG[debuginfod] = "--enable-debuginfod,--disable-debuginfod,libarchive sqlite3 libmicrohttpd"
 
 RDEPENDS_${PN}-ptest += "libasm libelf bash make coreutils ${PN}-binutils"
 
Signature · 1 line
2.17.1
author
#2 lore raw

PATCH 3/3 elfutils: add support for ipkg

In reply to Dorinda

debuginfod scanner 0.181 could only support RPM and scan .debs, it can now scan .ipk

---
 .../elfutils/elfutils_0.181.bb                |  1 +
 ...d-support-for-ipkg-to-debuginfod.cxx.patch | 32 +++++++++++++++++++
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-devtools/elfutils/files/0001-add-support-for-ipkg-to-debuginfod.cxx.patch
meta/recipes-devtools/elfutils/elfutils_0.181.bb +1 -0
index c18de53b1e..ee97f06b87 100644
@@ -20,6 +20,7 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
            file://run-ptest \
            file://ptest.patch \
            file://0001-tests-Makefile.am-compile-test_nlist-with-standard-C.patch \
+           file://0001-add-support-for-ipkg-to-debuginfod.cxx.patch \
            "
 
 SRC_URI_append_libc-musl = " \
meta/recipes-devtools/elfutils/files/0001-add-support-for-ipkg-to-debuginfod.cxx.patch new file +32 -0
new file mode 100644
index 0000000000..4bb39c91e8
@@ -0,0 +1,32 @@
+From b647d1df55c20772a9cc7ce96fcf323c500481bf Mon Sep 17 00:00:00 2001
+From: dorindabassey <[email protected]>
+Date: Sat, 19 Dec 2020 01:11:46 +0100
+Subject: [PATCH] add support for ipkg to debuginfod.cxx
+
+added support for ipkg to the debuginfod scanner. 0.181 only supports RPM and scan .debs, with this patch, debuginfod scanner would be able to scan .ipk
+
+Upstream-status: Pending
+
+Signed-off-by: dorindabassey <[email protected]>
+---
+ debuginfod/debuginfod.cxx | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/debuginfod/debuginfod.cxx b/debuginfod/debuginfod.cxx
+index 5621030..cc78c93 100644
+--- a/debuginfod/debuginfod.cxx
++++ b/debuginfod/debuginfod.cxx
+@@ -442,11 +442,13 @@ parse_opt (int key, char *arg,
+         {
+           scan_archives[".deb"]="dpkg-deb --fsys-tarfile";
+           scan_archives[".ddeb"]="dpkg-deb --fsys-tarfile";
++          scan_archives[".ipk"]="dpkg-deb --fsys-tarfile";
+         }
+       else
+         {
+           scan_archives[".deb"]="(bsdtar -O -x -f - data.tar.xz)<";
+           scan_archives[".ddeb"]="(bsdtar -O -x -f - data.tar.xz)<";
++          scan_archives[".ipk"]="(bsdtar -O -x -f - data.tar.xz)<";
+         }
+       // .udeb too?
+       break;
Signature · 1 line
2.17.1
#3 lore raw
In reply to Dorinda
Quoted 6 lines · Dorinda

add package options for libdebuginfod

---
 meta/recipes-devtools/elfutils/elfutils_0.181.bb | 4 +++-

 1 file changed, 3 insertions(+), 1 deletion(-)

Thanks for these, at a quick glance without testing they look good to me. Master has moved to elfutils 0.182, would you be able to update against that and resend so I can queue them please?

Cheers,

Richard