From 7069d2fcbb6ea889207c6d14278c461128c7d7fd Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Thu, 9 Mar 2023 23:41:40 -0800 Subject: pahole: Upgrade to tip of trunk Drop patches already present in 1.24+ Needed to get fixes to build with latest libbpf APIs Signed-off-by: Khem Raj --- .../0001-CMakeList.txt-make-python-optional.patch | 44 ---------------------- ...xt-don-t-download-libbpf-source-when-syst.patch | 34 ----------------- meta-oe/recipes-devtools/pahole/pahole_1.22.bb | 34 ----------------- meta-oe/recipes-devtools/pahole/pahole_1.24.bb | 33 ++++++++++++++++ 4 files changed, 33 insertions(+), 112 deletions(-) delete mode 100644 meta-oe/recipes-devtools/pahole/files/0001-CMakeList.txt-make-python-optional.patch delete mode 100644 meta-oe/recipes-devtools/pahole/files/0003-CMakeList.txt-don-t-download-libbpf-source-when-syst.patch delete mode 100644 meta-oe/recipes-devtools/pahole/pahole_1.22.bb create mode 100644 meta-oe/recipes-devtools/pahole/pahole_1.24.bb (limited to 'meta-oe/recipes-devtools') diff --git a/meta-oe/recipes-devtools/pahole/files/0001-CMakeList.txt-make-python-optional.patch b/meta-oe/recipes-devtools/pahole/files/0001-CMakeList.txt-make-python-optional.patch deleted file mode 100644 index d64cba109..000000000 --- a/meta-oe/recipes-devtools/pahole/files/0001-CMakeList.txt-make-python-optional.patch +++ /dev/null @@ -1,44 +0,0 @@ -From f6ca8c930d0fbd2491b3cc77169e32806a14e5e9 Mon Sep 17 00:00:00 2001 -From: Matteo Croce -Date: Mon, 30 Aug 2021 16:25:56 +0200 -Subject: [PATCH] CMakeList.txt: make python optional - -Upstream-Status: Backport [https://git.kernel.org/pub/scm/devel/pahole/pahole.git/commit/?id=88431099950ab3e8bc1645353508d7978a6cad35] - -ostra-cg, which requires python, is installed in the destination dir. -Make it optional for embedded distributions which doesn't have the -python interpreter available. - -Signed-off-by: Matteo Croce ---- - CMakeLists.txt | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 4140574..8523bce 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -61,6 +61,7 @@ find_package(DWARF REQUIRED) - find_package(ZLIB REQUIRED) - find_package(argp REQUIRED) - find_package(obstack REQUIRED) -+find_package(Python3 QUIET) - - # make sure git submodule(s) are checked out - find_package(Git QUIET) -@@ -185,8 +186,10 @@ install(FILES dwarves.h dwarves_emit.h dwarves_reorganize.h - elfcreator.h elf_symtab.h hash.h libctf.h - DESTINATION ${CMAKE_INSTALL_PREFIX}/include/dwarves/) - install(FILES man-pages/pahole.1 DESTINATION ${CMAKE_INSTALL_PREFIX}/share/man/man1/) --install(PROGRAMS ostra/ostra-cg DESTINATION ${CMAKE_INSTALL_PREFIX}/bin) -+if(Python3_FOUND) -+ install(PROGRAMS ostra/ostra-cg DESTINATION ${CMAKE_INSTALL_PREFIX}/bin) -+ install(FILES ostra/python/ostra.py DESTINATION ${CMAKE_INSTALL_PREFIX}/share/dwarves/runtime/python) -+endif() - install(PROGRAMS btfdiff fullcircle DESTINATION ${CMAKE_INSTALL_PREFIX}/bin) --install(FILES ostra/python/ostra.py DESTINATION ${CMAKE_INSTALL_PREFIX}/share/dwarves/runtime/python) - install(FILES lib/Makefile lib/ctracer_relay.c lib/ctracer_relay.h lib/linux.blacklist.cu - DESTINATION ${CMAKE_INSTALL_PREFIX}/share/dwarves/runtime) --- -2.31.1 - diff --git a/meta-oe/recipes-devtools/pahole/files/0003-CMakeList.txt-don-t-download-libbpf-source-when-syst.patch b/meta-oe/recipes-devtools/pahole/files/0003-CMakeList.txt-don-t-download-libbpf-source-when-syst.patch deleted file mode 100644 index 3d491e2ef..000000000 --- a/meta-oe/recipes-devtools/pahole/files/0003-CMakeList.txt-don-t-download-libbpf-source-when-syst.patch +++ /dev/null @@ -1,34 +0,0 @@ -From 3d20210d84f61ee2189927e2d9de9ce3e5a0a9c5 Mon Sep 17 00:00:00 2001 -From: Matteo Croce -Date: Mon, 20 Sep 2021 18:44:52 +0200 -Subject: [PATCH] CMakeList.txt: Don't download libbpf source when system - library is used - -Upstream-Status: Backport [https://git.kernel.org/pub/scm/devel/pahole/pahole.git/commit/?id=3d20210d84f61ee2189927e2d9de9ce3e5a0a9c5] - -The build system always download the libbpf submodule, regardless if -we're using the embedded or the system version. -Download the libbpf source only if we're using the embedded one. - -Signed-off-by: Matteo Croce -Signed-off-by: Arnaldo Carvalho de Melo ---- - CMakeLists.txt | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 8523bce..2ab66e4 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -65,7 +65,7 @@ find_package(Python3 QUIET) - - # make sure git submodule(s) are checked out - find_package(Git QUIET) --if(GIT_FOUND AND EXISTS "${PROJECT_SOURCE_DIR}/.git") -+if(LIBBPF_EMBEDDED AND GIT_FOUND AND EXISTS "${PROJECT_SOURCE_DIR}/.git") - # Update submodules as needed - option(GIT_SUBMODULE "Check submodules during build" ON) - if(GIT_SUBMODULE) --- -2.31.1 - diff --git a/meta-oe/recipes-devtools/pahole/pahole_1.22.bb b/meta-oe/recipes-devtools/pahole/pahole_1.22.bb deleted file mode 100644 index 449508a5d..000000000 --- a/meta-oe/recipes-devtools/pahole/pahole_1.22.bb +++ /dev/null @@ -1,34 +0,0 @@ -SUMMARY = "Shows and manipulates data structure layout" - -LICENSE = "GPL-2.0-only" -LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" - -DEPENDS = "elfutils zlib libbpf" - -# Depends on MACHINE_ARCH libbpf -PACKAGE_ARCH = "${MACHINE_ARCH}" -COMPATIBLE_HOST = "(x86_64|i.86|aarch64).*-linux" - -SRCREV = "f02af2553ea58ae1186226af0d0ec835a248358f" -SRC_URI = "git://git.kernel.org/pub/scm/devel/pahole/pahole.git;branch=master \ - file://0001-CMakeList.txt-make-python-optional.patch \ - file://0002-Use-usr-bin-env-python3-instead-of-just-usr-bin-pyth.patch \ - file://0003-CMakeList.txt-don-t-download-libbpf-source-when-syst.patch" - -S = "${WORKDIR}/git" - -inherit cmake pkgconfig - -PACKAGECONFIG[python3] = ",,python3-core,python3-core" - -EXTRA_OECMAKE = "-D__LIB=lib -DCMAKE_BUILD_TYPE=Release -DLIBBPF_EMBEDDED=OFF" - -FILES:${PN} = "${bindir}/pahole \ - ${libdir}/libdwarves.so* \ - ${libdir}/libdwarves_reorganize.so*" - -PACKAGES += "${PN}-extra" -FILES:${PN}-extra = "${datadir} ${bindir} ${libdir}/libdwarves_emit.so*" -RDEPENDS:${PN}-extra += "bash python3-core" - -BBCLASSEXTEND = "native nativesdk" diff --git a/meta-oe/recipes-devtools/pahole/pahole_1.24.bb b/meta-oe/recipes-devtools/pahole/pahole_1.24.bb new file mode 100644 index 000000000..b7f1f8bb2 --- /dev/null +++ b/meta-oe/recipes-devtools/pahole/pahole_1.24.bb @@ -0,0 +1,33 @@ +SUMMARY = "Shows and manipulates data structure layout" + +LICENSE = "GPL-2.0-only" +LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" + +DEPENDS = "elfutils zlib libbpf" + +# Depends on MACHINE_ARCH libbpf +PACKAGE_ARCH = "${MACHINE_ARCH}" +COMPATIBLE_HOST = "(x86_64|i.86|aarch64).*-linux" + +PV .= "+1.25+git${SRCPV}" +SRCREV = "a9498899109d3be14f17abbc322a8f55a1067bee" +SRC_URI = "git://git.kernel.org/pub/scm/devel/pahole/pahole.git;branch=master \ + file://0002-Use-usr-bin-env-python3-instead-of-just-usr-bin-pyth.patch" + +S = "${WORKDIR}/git" + +inherit cmake pkgconfig + +PACKAGECONFIG[python3] = ",,python3-core,python3-core" + +EXTRA_OECMAKE = "-D__LIB=lib -DCMAKE_BUILD_TYPE=Release -DLIBBPF_EMBEDDED=OFF" + +FILES:${PN} = "${bindir}/pahole \ + ${libdir}/libdwarves.so* \ + ${libdir}/libdwarves_reorganize.so*" + +PACKAGES += "${PN}-extra" +FILES:${PN}-extra = "${datadir} ${bindir} ${libdir}/libdwarves_emit.so*" +RDEPENDS:${PN}-extra += "bash python3-core" + +BBCLASSEXTEND = "native nativesdk" -- cgit v1.2.3-54-g00ecf