From: Hemanth Kumar M D <[email protected]> The recipe calls runtest directly, bypassing upstream's Makefile which normally passes CC_FOR_TARGET/CXX_FOR_TARGET to the test harness. Without them, dejagnu falls back to find_gcc() returning the bare compiler name without --sysroot.
On ARM, ld-selective/selective.exp calls $CC_FOR_TARGET directly to query -print-libgcc-file-name. Without --sysroot, OE's poisoned cross-gcc cannot locate libgcc.a, failing selective1/2/3. Set CC_FOR_TARGET/CXX_FOR_TARGET the same way CC/CXX already are. Tested on qemuarm: ld: +--------------+--------+--------+------+ | Result | Before | After | Diff | +--------------+--------+--------+------+ | PASS | 1173 | 1879 | +706 | | FAIL | 3 | 0 | -3 | | XFAIL | 8 | 57 | +49 | | XPASS | 0 | 6 | +6 | | UNTESTED | 22 | 4 | -18 | | UNSUPPORTED | 153 | 417 | +264 | +--------------+--------+--------+------+ selective1/2/3 are ARM-specific and are fixed here. The larger test-count increase is not ARM-specific: CC_FOR_TARGET without --sysroot made check_compiler_available fail, silently skipping many sub-tests across all architectures. With the fix those tests run. Upstream bug tracking the silent skipping: https://sourceware.org/bugzilla/show_bug.cgi?id=34580 [YOCTO #16342] Signed-off-by: Hemanth Kumar M D <[email protected]> --- meta/recipes-devtools/binutils/binutils-testsuite_2.47.bb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meta/recipes-devtools/binutils/binutils-testsuite_2.47.bb b/meta/recipes-devtools/binutils/binutils-testsuite_2.47.bb index 5369333434..2219da7c7a 100644 --- a/meta/recipes-devtools/binutils/binutils-testsuite_2.47.bb +++ b/meta/recipes-devtools/binutils/binutils-testsuite_2.47.bb @@ -51,6 +51,8 @@ python check_prepare() { content.append(d.expand('set CXXFILT "${TARGET_PREFIX}c++filt"')) content.append(d.expand('set CC "${TARGET_PREFIX}gcc --sysroot=${STAGING_DIR_TARGET} ${TUNE_CCARGS}"')) content.append(d.expand('set CXX "${TARGET_PREFIX}g++ --sysroot=${STAGING_DIR_TARGET} ${TUNE_CCARGS}"')) + content.append(d.expand('set CC_FOR_TARGET "${TARGET_PREFIX}gcc --sysroot=${STAGING_DIR_TARGET} ${TUNE_CCARGS}"')) + content.append(d.expand('set CXX_FOR_TARGET "${TARGET_PREFIX}g++ --sysroot=${STAGING_DIR_TARGET} ${TUNE_CCARGS}"')) content.append(d.expand('set CFLAGS_FOR_TARGET "--sysroot=${STAGING_DIR_TARGET} ${TUNE_CCARGS}"')) content.append(d.expand('set LD "${TARGET_PREFIX}ld ${TUNE_LDARGS}"')) content.append(d.expand('set LDFLAGS_FOR_TARGET "${TUNE_LDARGS}"')) -- 2.49.0
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#244825): https://lists.openembedded.org/g/openembedded-core/message/244825 Mute This Topic: https://lists.openembedded.org/mt/121031548/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
