libatomic hasn't been ported to vxworks. Most of the stdatomic.h and
<atomic> underlying requirements are provided by builtins and libgcc,
and the vxworks libc already provides remaining __atomic symbols, so
porting libatomic doesn't seem to make sense.
However, some of the target arch-only tests in
add_options_for_libatomic cover vxworks targets, so we end up
attempting to link libatomic in, even though it's not there.
Preempt those too-broad tests.
Co-Authored-By: Marc Poulhiès <poulhies@adacore.com>
for libstdc++-v3/ChangeLog
* testsuite/lib/dg-options.exp (add_options_for_libatomic):
None for *-*-vxworks*.
}
proc add_options_for_libatomic { flags } {
+ # We don't (need to) build libatomic for vxworks. Don't try to
+ # link it in, even on arches that support libatomic.
+ if { [istarget *-*-vxworks*] } {
+ return $flags
+ }
if { [istarget hppa*-*-hpux*]
|| ([istarget powerpc*-*-*] && [check_effective_target_ilp32])
|| [istarget riscv*-*-*]