]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
elfutils: Add provisions for marking XFAILS in ptests
authorKhem Raj <raj.khem@gmail.com>
Wed, 13 Aug 2025 06:24:26 +0000 (23:24 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 14 Aug 2025 09:14:30 +0000 (10:14 +0100)
elfuitls testsuites do not pass on all kind of distro features e.g.
with musl there are failures and with ld-is-lld less numer but it shows
failures too. Make run-ptest treat these as known failures.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/elfutils/elfutils_0.193.bb
meta/recipes-devtools/elfutils/files/run-ptest

index 4ccea2bea3b5a66e7ee852fb877dbb7f660ae538..e700c415be97077bf1d42a595413eba2731694fe 100644 (file)
@@ -63,6 +63,10 @@ do_compile_ptest() {
 }
 PTEST_PARALLEL_MAKE = ""
 
+PTEST_XFAILS ?= ""
+# See - https://sourceware.org/bugzilla/show_bug.cgi?id=32232
+PTEST_XFAILS:append = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-lld', ' run-strip-strmerge.sh run-elflint-self.sh run-backtrace-data.sh run-reverse-sections-self.sh', '', d)}"
+
 do_install_ptest() {
        # copy the files which needed by the cases
        TEST_FILES="strip strip.o addr2line elfcmp objdump readelf size.o nm.o nm elflint elfcompress elfclassify stack unstrip srcfiles"
@@ -100,6 +104,7 @@ do_install_ptest() {
        cp -r ${B}/debuginfod                   ${D}${PTEST_PATH}
        sed -i '/^Makefile:/c Makefile:'        ${D}${PTEST_PATH}/tests/Makefile
        find ${D}${PTEST_PATH} -type f -name *.[hoc] | xargs -i rm {}
+       sed -i -e 's|@XFAIL_TESTS@|${PTEST_XFAILS}|' ${D}${PTEST_PATH}/run-ptest
 }
 
 EXTRA_OEMAKE:class-native = ""
index d5776fdb5386698990c2a143dda8ed63334109d5..3c6c14e47f92baa00a494ad07327d8ae282e3ba2 100644 (file)
@@ -3,4 +3,4 @@
 #This script is used to run elfutils test suites
 cd tests
 
-make -k installcheck-local CC=gcc abs_srcdir=$PWD abs_builddir=$PWD srcdir=$PWD top_srcdir=$PWD/../ abs_top_builddir=$PWD/../ elfutils_testrun=installed elfutils_tests_rpath=no program_transform_name=s,^,eu-,
+make -k installcheck-local CC=gcc abs_srcdir=$PWD abs_builddir=$PWD srcdir=$PWD top_srcdir=$PWD/../ abs_top_builddir=$PWD/../ elfutils_testrun=installed elfutils_tests_rpath=no program_transform_name=s,^,eu-, XFAIL_TESTS="@XFAIL_TESTS@"