From 1121044151f3ff1c18696e3466a171af684c2369 Mon Sep 17 00:00:00 2001 From: Harish Sadineni Date: Thu, 24 Apr 2025 15:23:22 +0530 Subject: bcc: install opt dir to image to fix py_test_trace3_c This patch Fixes the following error: ERROR: test_blk1 (__main__.TestBlkRequest.test_blk1) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/lib/bcc/ptest/tests/python/./test_trace3.py", line 38, in test_blk1 os.unlink("/opt/trace3.txt") ~~~~~~~~~^^^^^^^^^^^^^^^^^^^ FileNotFoundError: [Errno 2] No such file or directory: '/opt/trace3.txt' Signed-off-by: Harish Sadineni --- dynamic-layers/meta-python/recipes-devtools/bcc/bcc_0.33.0.bb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dynamic-layers/meta-python/recipes-devtools/bcc/bcc_0.33.0.bb b/dynamic-layers/meta-python/recipes-devtools/bcc/bcc_0.33.0.bb index 3285020..69fa9f2 100644 --- a/dynamic-layers/meta-python/recipes-devtools/bcc/bcc_0.33.0.bb +++ b/dynamic-layers/meta-python/recipes-devtools/bcc/bcc_0.33.0.bb @@ -67,6 +67,7 @@ do_install_ptest() { # Hence, these files are copied to the image to fix these tests. install -d ${D}${B}/tests/cc install ${B}/tests/cc/archive.zip ${B}/tests/cc/libdebuginfo_test_lib.so ${B}/tests/cc/with_gnu_debuglink.so ${B}/tests/cc/with_gnu_debugdata.so ${B}/tests/cc/debuginfo.so ${D}${B}/tests/cc + install -d ${D}/opt install ${B}/tests/cc/test_libbcc_no_libbpf ${B}/tests/cc/libusdt_test_lib.so ${D}${PTEST_PATH}/tests/cc cp -rf ${S}/tests/python ${D}${PTEST_PATH}/tests/python install ${UNPACKDIR}/ptest_wrapper.sh ${D}${PTEST_PATH}/tests @@ -75,6 +76,7 @@ do_install_ptest() { FILES:${PN} += "${PYTHON_SITEPACKAGES_DIR}" FILES:${PN} += "${B}/tests/cc" +FILES:${PN}-ptest += "/opt/" FILES:${PN}-doc += "${datadir}/${PN}/man" COMPATIBLE_HOST = "(x86_64.*|aarch64.*|powerpc64.*|riscv64.*)-linux" -- cgit v1.2.3-54-g00ecf