Rename to allow_gdbserver_tests

This changes skip_gdbserver_tests to invert the sense, and renames it
to allow_gdbserver_tests.
This commit is contained in:
Tom Tromey 2023-01-08 10:53:55 -07:00
parent 57b7402d20
commit cadfc59b0d
39 changed files with 46 additions and 46 deletions

View File

@ -70,13 +70,13 @@ gdb_test "record btrace" "The process is already being recorded\\. Use \"record
# continue to the end and make sure we don't die
gdb_test "continue" ".*Inferior.*exited.*" "continue to end"
# skip_gdbserver_tests requires GDB not running.
# allow_gdbserver_tests requires GDB not running.
gdb_exit
# skip the rerun test when using gdbserver
# otherwise rerun twice, target should be automatically disabled
load_lib gdbserver-support.exp
if [skip_gdbserver_tests] {
if !{[allow_gdbserver_tests]} {
unsupported "target does not support gdbserver"
return 0
}

View File

@ -20,7 +20,7 @@
load_lib gdbserver-support.exp
require allow_btrace_tests
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile
if [prepare_for_testing "failed to prepare" $testfile $srcfile] {

View File

@ -20,7 +20,7 @@ load_lib gdbserver-support.exp
load_lib mi-support.exp
set MIFLAGS "-i=mi"
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile basics.c

View File

@ -22,7 +22,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
require can_spawn_for_attach

View File

@ -165,7 +165,7 @@ proc setup {non-stop} {
proc multi_target_prepare {} {
global binfile srcfile
if { [skip_gdbserver_tests] } {
if { ![allow_gdbserver_tests] } {
return 0
}

View File

@ -24,7 +24,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests !skip_python_tests
require allow_gdbserver_tests !skip_python_tests
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } {
return -1

View File

@ -22,7 +22,7 @@ load_lib gdbserver-support.exp
standard_testfile normal.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
# Because we're relying on being able to change our CWD before
# executing gdbserver, we just run if we're not testing with a remote

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
require can_spawn_for_attach

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if { [prepare_for_testing "failed to prepare" ${binfile} "${srcfile}" \
{debug pthreads}] } {

View File

@ -20,7 +20,7 @@
load_lib gdbserver-support.exp
load_lib prelink-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile
set executable ${testfile}

View File

@ -25,7 +25,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
if { [build_executable "failed to prepare" $testfile $srcfile debug] } {
return -1

View File

@ -18,7 +18,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile

View File

@ -25,7 +25,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile

View File

@ -22,7 +22,7 @@ load_lib trace-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
require can_spawn_for_attach

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
save_vars { GDBFLAGS } {
# If GDB and GDBserver are both running locally, set the sysroot to avoid

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
return -1

View File

@ -19,7 +19,7 @@ load_lib gdbserver-support.exp
standard_testfile wrapper.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
return -1

View File

@ -20,7 +20,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
return -1

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
return -1

View File

@ -24,7 +24,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
save_vars { GDBFLAGS } {
# If GDB and GDBserver are both running locally, set the sysroot to avoid

View File

@ -25,7 +25,7 @@ load_lib gdbserver-support.exp
standard_testfile
set unresolvable_thread_db_path "/foo/bar"
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
return -1

View File

@ -22,7 +22,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
set gdbserver [find_gdbserver]
if { $gdbserver == "" } {

View File

@ -19,7 +19,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
if [target_info exists gdb,nointerrupts] {
verbose "Skipping reconnect-ctrl-c.exp because of nointerrupts."

View File

@ -15,7 +15,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile normal.c

View File

@ -22,7 +22,7 @@ load_lib gdbserver-support.exp
standard_testfile normal.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
# We want to have control over where we start gdbserver.
if { [is_remote target] } {

View File

@ -18,7 +18,7 @@ load_lib gdbserver-support.exp
# We test for skip_shlib_tests in this test because without a main
# exec file we only have the exec target loaded if shared libraries
# are present.
require !skip_gdbserver_tests !skip_shlib_tests
require allow_gdbserver_tests !skip_shlib_tests
standard_testfile server.c
if [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] {

View File

@ -23,7 +23,7 @@ load_lib gdbserver-support.exp
standard_testfile multi-ui-errors.c
require !skip_gdbserver_tests !skip_python_tests
require allow_gdbserver_tests !skip_python_tests
if {[build_executable "failed to prepare" ${testfile} \
${srcfile}] == -1} {

View File

@ -22,7 +22,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
if { [build_executable "failed to prepare" ${testfile}] } {
return -1

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
return -1

View File

@ -32,7 +32,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
set gdbserver [find_gdbserver]
if { $gdbserver == "" } {

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile server.c
require !skip_gdbserver_tests
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
return -1

View File

@ -23,7 +23,7 @@
load_lib gdbserver-support.exp
load_lib prelink-support.exp
require !skip_gdbserver_tests !skip_shlib_tests
require allow_gdbserver_tests !skip_shlib_tests
standard_testfile solib-list-main.c
set srclibfile ${testfile}-lib.c

View File

@ -30,7 +30,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile
if { [build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1 } {

View File

@ -22,7 +22,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile
if { [build_executable "failed to prepare" $testfile $srcfile] == -1 } {

View File

@ -20,7 +20,7 @@
load_lib gdbserver-support.exp
require !skip_gdbserver_tests
require allow_gdbserver_tests
standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile "additional_flags=--no-builtin"] == -1} {

View File

@ -19,7 +19,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
if { [build_executable "failed to prepare" $::testfile $::srcfile \
{debug}] } {

View File

@ -19,7 +19,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
global server_spawn_id

View File

@ -21,7 +21,7 @@ load_lib gdbserver-support.exp
standard_testfile
require !skip_gdbserver_tests
require allow_gdbserver_tests
if { [istarget *-*-mingw*]
|| [istarget *-*-cygwin*] } {

View File

@ -160,12 +160,12 @@ proc find_gdbserver { } {
return ""
}
# Return non-zero if we should skip gdbserver-specific tests.
# Return non-zero if we should run gdbserver-specific tests.
proc skip_gdbserver_tests { } {
if { [find_gdbserver] == "" } {
return 1
}
proc allow_gdbserver_tests { } {
if { [find_gdbserver] == "" } {
return 0
}
# If GDB is lack of XML support, and targets, like arm, have
# multiple target descriptions, GDB doesn't know which target
@ -179,10 +179,10 @@ proc skip_gdbserver_tests { } {
|| [istarget "s390*-*-linux*"]
|| [istarget "x86_64-*-linux*"]
|| [istarget "i\[34567\]86-*-linux*"]) } {
return 1
return 0
}
return 0
return 1
}
# Download the currently loaded program to the target if necessary.