With the correct patch attached, sorry for the incorrect previous one ! Marc
----- Original Message ----- > From: "gcc-patches" <gcc-patches@gcc.gnu.org> > To: "gcc-patches" <gcc-patches@gcc.gnu.org>, "libstdc++" > <libstd...@gcc.gnu.org> > Cc: "Luc Michel" <lmic...@kalray.eu> > Sent: Tuesday, July 20, 2021 4:12:16 PM > Subject: [NEWS] libstdc++: Fix testsuite for skipping gdb tests on > remote/non-native target > This fixes an incorrect invocation of gdb on remote targets where DejaGNU > would > try to run host's gdb in remote target simulator. > gdb-test skips the testing when target is remote or non native but the gdb > version check function does not. > > libstdc++-v3/ChangeLog: > * testsuite/lib/gdb-test.exp (gdb_batch_check): Exit if non native or > remote > target.
diff --git a/libstdc++-v3/testsuite/lib/gdb-test.exp b/libstdc++-v3/testsuite/lib/gdb-test.exp index af20c85e5a0..0ec9ac46c68 100644 --- a/libstdc++-v3/testsuite/lib/gdb-test.exp +++ b/libstdc++-v3/testsuite/lib/gdb-test.exp @@ -244,6 +244,8 @@ proc gdb-test { marker {selector {}} {load_xmethods 0} } { # Invoke gdb with a command and pattern-match the output. proc gdb_batch_check {command pattern} { + if { ![isnative] || [is_remote target] } { return 0 } + set gdb_name $::env(GUALITY_GDB_NAME) set cmd "$gdb_name -nw -nx -quiet -batch -ex \"$command\"" send_log "Spawning: $cmd\n"