From c415680160f55480b3c1675bbaf0836e6b652489 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Sun, 31 Aug 2025 00:48:53 -0700 Subject: bpftrace: Upgrade to 0.23.5 release Drop backported patch Signed-off-by: Khem Raj --- ...build-failures-due-to-missing-location.hh.patch | 54 ---------------- .../recipes-devtools/bpftrace/bpftrace_0.23.0.bb | 71 ---------------------- .../recipes-devtools/bpftrace/bpftrace_0.23.5.bb | 68 +++++++++++++++++++++ 3 files changed, 68 insertions(+), 125 deletions(-) delete mode 100644 meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace/0001-Fix-build-failures-due-to-missing-location.hh.patch delete mode 100644 meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.0.bb create mode 100644 meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.5.bb (limited to 'meta-oe') diff --git a/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace/0001-Fix-build-failures-due-to-missing-location.hh.patch b/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace/0001-Fix-build-failures-due-to-missing-location.hh.patch deleted file mode 100644 index 1c2ae33238..0000000000 --- a/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace/0001-Fix-build-failures-due-to-missing-location.hh.patch +++ /dev/null @@ -1,54 +0,0 @@ -From 24421ba92c69f1abaadaff01270621917616a2b8 Mon Sep 17 00:00:00 2001 -From: Changqing Li -Date: Thu, 17 Apr 2025 10:38:50 +0800 -Subject: [PATCH] Fix build failures due to missing location.hh - -ast/location.h does `#include "location.hh"` and location.hh is -generated by the parser so any CMake target whose source includes -ast/location.h needs to have a dependency on the `parser` target, -otherwise the compilation may fail due to incorrect ordering of build -targets. This also applies to targets which include ast/location.h -transitively via other headers. - -To avoid such errors, do 2 things: -- drop includes of ast/location.h where unused -- for CMake targets including ast/location.h, add an explicit dependency - on the `parser` target - -Signed-off-by: Viktor Malik - -Upstream-Status: Backport [https://github.com/bpftrace/bpftrace/commit/743cb9c88c25fb9737d714f4d4ac853f05bb6481] - -Signed-off-by: Changqing Li ---- - src/CMakeLists.txt | 1 + - src/ast/CMakeLists.txt | 1 + - 2 files changed, 2 insertions(+) - -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index e04ee429..13a51040 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -21,6 +21,7 @@ add_library(compiler_core STATIC - struct.cpp - types.cpp - ) -+add_dependencies(compiler_core parser) - - add_library(runtime STATIC - attached_probe.cpp -diff --git a/src/ast/CMakeLists.txt b/src/ast/CMakeLists.txt -index 92231f85..7230cf71 100644 ---- a/src/ast/CMakeLists.txt -+++ b/src/ast/CMakeLists.txt -@@ -22,6 +22,7 @@ add_library(ast STATIC - passes/return_path_analyser.cpp - ) - -+add_dependencies(ast parser) - target_compile_definitions(ast PRIVATE ${BPFTRACE_FLAGS}) - target_link_libraries(ast PUBLIC ast_defs arch compiler_core parser) - --- -2.34.1 - diff --git a/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.0.bb b/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.0.bb deleted file mode 100644 index c8ccf4c83f..0000000000 --- a/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.0.bb +++ /dev/null @@ -1,71 +0,0 @@ -SUMMARY = "bpftrace" -HOMEPAGE = "https://github.com/iovisor/bpftrace" -LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" - -DEPENDS += "bison-native \ - flex-native \ - gzip-native \ - elfutils \ - bcc \ - systemtap \ - libcereal \ - libbpf \ - " -DEPENDS += "${@bb.utils.contains('PTEST_ENABLED', '1', 'pahole-native llvm-native', '', d)}" - -RDEPENDS:${PN} += "bash python3 xz" - -PV .= "+git" - -SRC_URI = "git://github.com/iovisor/bpftrace;branch=release/0.23.x;protocol=https \ - file://run-ptest \ - file://0002-CMakeLists.txt-allow-to-set-BISON_FLAGS-like-l.patch \ - file://0001-Fix-build-failures-due-to-missing-location.hh.patch \ -" -SRCREV = "01e806d24c61f996f1809e1e991646311499db4f" - -inherit bash-completion cmake ptest pkgconfig - -PACKAGECONFIG ?= " \ - ${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)} \ - ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "systemd", "", d)} \ - " - -PACKAGECONFIG[tests] = "-DBUILD_TESTING=ON,-DBUILD_TESTING=OFF,gtest xxd-native" -PACKAGECONFIG[systemd] = "-DENABLE_SYSTEMD=ON,-DENABLE_SYSTEMD=OFF,systemd" - -do_install_ptest() { - if [ -e ${B}/tests/bpftrace_test ]; then - install -Dm 755 ${B}/tests/bpftrace_test ${D}${PTEST_PATH}/tests/bpftrace_test - cp -rf ${B}/tests/runtime ${D}${PTEST_PATH}/tests - cp -rf ${B}/tests/test* ${D}${PTEST_PATH}/tests - fi - for f in testlibs/cmake_install.cmake \ - testprogs/cmake_install.cmake \ - testlibs/CTestTestfile.cmake \ - testprogs/CTestTestfile.cmake - do - sed -i -e 's|${STAGING_BINDIR_TOOLCHAIN}/||' ${D}${libdir}/bpftrace/ptest/tests/$f - sed -i -e 's|${S}/||' ${D}${libdir}/bpftrace/ptest/tests/$f - sed -i -e 's|${B}/||' ${D}${libdir}/bpftrace/ptest/tests/$f - done -} - -EXTRA_OECMAKE = " \ - -DCMAKE_ENABLE_EXPORTS=1 \ - -DCMAKE_BUILD_TYPE=Release \ - -DUSE_SYSTEM_BPF_BCC=ON \ - -DENABLE_MAN=OFF \ - -DBISON_FLAGS='--file-prefix-map=${WORKDIR}=' \ -" - -COMPATIBLE_HOST = "(x86_64.*|aarch64.*|powerpc64.*|riscv64.*)-linux" -COMPATIBLE_HOST:libc-musl = "null" - -INHIBIT_PACKAGE_STRIP_FILES += "\ - ${PKGD}${PTEST_PATH}/tests/testprogs/uprobe_test \ -" - -WARN_QA:append = "${@bb.utils.contains('PTEST_ENABLED', '1', ' buildpaths', '', d)}" -ERROR_QA:remove = "${@bb.utils.contains('PTEST_ENABLED', '1', 'buildpaths', '', d)}" diff --git a/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.5.bb b/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.5.bb new file mode 100644 index 0000000000..1b2f8ab0e4 --- /dev/null +++ b/meta-oe/dynamic-layers/meta-python/recipes-devtools/bpftrace/bpftrace_0.23.5.bb @@ -0,0 +1,68 @@ +SUMMARY = "bpftrace" +HOMEPAGE = "https://github.com/iovisor/bpftrace" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" + +DEPENDS += "bison-native \ + flex-native \ + gzip-native \ + elfutils \ + bcc \ + systemtap \ + libcereal \ + libbpf \ + " +DEPENDS += "${@bb.utils.contains('PTEST_ENABLED', '1', 'pahole-native llvm-native', '', d)}" + +RDEPENDS:${PN} += "bash python3 xz" + +SRC_URI = "git://github.com/iovisor/bpftrace;branch=release/0.23.x;protocol=https \ + file://run-ptest \ + file://0002-CMakeLists.txt-allow-to-set-BISON_FLAGS-like-l.patch \ +" +SRCREV = "e48ccc66c9971515648b63699bc4b1490c388d85" + +inherit bash-completion cmake ptest pkgconfig + +PACKAGECONFIG ?= " \ + ${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)} \ + ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "systemd", "", d)} \ + " + +PACKAGECONFIG[tests] = "-DBUILD_TESTING=ON,-DBUILD_TESTING=OFF,gtest xxd-native" +PACKAGECONFIG[systemd] = "-DENABLE_SYSTEMD=ON,-DENABLE_SYSTEMD=OFF,systemd" + +do_install_ptest() { + if [ -e ${B}/tests/bpftrace_test ]; then + install -Dm 755 ${B}/tests/bpftrace_test ${D}${PTEST_PATH}/tests/bpftrace_test + cp -rf ${B}/tests/runtime ${D}${PTEST_PATH}/tests + cp -rf ${B}/tests/test* ${D}${PTEST_PATH}/tests + fi + for f in testlibs/cmake_install.cmake \ + testprogs/cmake_install.cmake \ + testlibs/CTestTestfile.cmake \ + testprogs/CTestTestfile.cmake + do + sed -i -e 's|${STAGING_BINDIR_TOOLCHAIN}/||' ${D}${libdir}/bpftrace/ptest/tests/$f + sed -i -e 's|${S}/||' ${D}${libdir}/bpftrace/ptest/tests/$f + sed -i -e 's|${B}/||' ${D}${libdir}/bpftrace/ptest/tests/$f + done +} + +EXTRA_OECMAKE = " \ + -DCMAKE_ENABLE_EXPORTS=1 \ + -DCMAKE_BUILD_TYPE=Release \ + -DUSE_SYSTEM_BPF_BCC=ON \ + -DENABLE_MAN=OFF \ + -DBISON_FLAGS='--file-prefix-map=${WORKDIR}=' \ +" + +COMPATIBLE_HOST = "(x86_64.*|aarch64.*|powerpc64.*|riscv64.*)-linux" +COMPATIBLE_HOST:libc-musl = "null" + +INHIBIT_PACKAGE_STRIP_FILES += "\ + ${PKGD}${PTEST_PATH}/tests/testprogs/uprobe_test \ +" + +WARN_QA:append = "${@bb.utils.contains('PTEST_ENABLED', '1', ' buildpaths', '', d)}" +ERROR_QA:remove = "${@bb.utils.contains('PTEST_ENABLED', '1', 'buildpaths', '', d)}" -- cgit v1.2.3-54-g00ecf