On irc we've seen a couple of people report demangling problems in elfutils-native on differing ubuntu versions. Once I convinced someone to share the config.log, it turned out that linking with -lstdc++ is failing. They were missing the right libstdc++-12-dev for their current c++ lib version (they had older ones). The best "fix" for this I can see would be to test linking to libstdc++ in sanity.bbclass.
basically just need to test by having a hello world that use libstdc++ to add to sanity.bbclass.
Christos sent a v1 here: https://lists.openembedded.org/g/openembedded-core/topic/meta_oe_patch_sanity_test/110595436 Looking through the mentioned IRC logs: https://libera.irclog.whitequark.org/yocto/2025-01-06#37555109, it appear that the test to do is: gcc -lstdc++ ... and not a compilation with g++. The failing line in the logs of the original reporter (https://pastebin.com/HtzCe1vb) is configure:8876: checking for __cxa_demangle in -lstdc++ configure:8905: gcc -o conftest [...] conftest.c -lstdc++ >&5 /yoc/test/build/tmp-glibc/hosttools/ld: cannot find -lstdc++: No such file or directory collect2: error: ld returned 1 exit status To trigger the test, maybe removing libstc++-dev suffice?
I have submitted a patch v2. The use of gcc with lstdc++ sounds advanced case to me.Am I wrong?
hi it is merged with the following commit ID: https://git.openembedded.org/openembedded-core/commit/?id=611c1a26212dfbfe8d0640d9fefe5df49f7b69b8
Changed the issue type to an enhancement and also set the Status to resolved/fixed. Thanks Christos.