mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-02-11 13:02:10 +08:00
Use require can_spawn_for_attach
This changes some tests to use "require can_spawn_for_attach".
This commit is contained in:
parent
8ce7423fda
commit
06e93b057c
@ -18,9 +18,7 @@
|
||||
# call any of setpgrp/setpgid/setsid to move itself to a new process
|
||||
# group.
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -13,9 +13,7 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile .c
|
||||
set executable ${testfile}
|
||||
|
@ -13,9 +13,7 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
set executable ${testfile}
|
||||
|
@ -13,9 +13,7 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile attach.c attach2.c attach3.c
|
||||
set binfile2 ${binfile}2
|
||||
|
@ -144,10 +144,7 @@ gdb_breakpoint $srcfile:$bp_main
|
||||
test_dlmopen
|
||||
|
||||
# Try the same again when attaching after dlmopen().
|
||||
if { ![can_spawn_for_attach] } {
|
||||
unsupported "target does not support attach"
|
||||
return -1
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
clean_restart $binfile
|
||||
|
||||
|
@ -24,9 +24,7 @@ if [target_info exists gdb,nointerrupts] {
|
||||
return
|
||||
}
|
||||
|
||||
if { ![can_spawn_for_attach] } {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -13,9 +13,7 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile .c
|
||||
set executable ${testfile}
|
||||
|
@ -18,9 +18,7 @@
|
||||
# Test the basic operation of the "kill inferiors" and "detach inferiors"
|
||||
# commands.
|
||||
|
||||
if ![can_spawn_for_attach] {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
set executable $testfile
|
||||
|
@ -16,9 +16,7 @@
|
||||
# Check that forking a process after a previous process was attached to unsets
|
||||
# attach_flag. This is done indirectly by inspecting GDB's quit prompt.
|
||||
|
||||
if ![can_spawn_for_attach] {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
set executable $testfile
|
||||
|
@ -27,11 +27,7 @@
|
||||
# difference appears to be caused by prelink, adjusting expectations
|
||||
# In such case both disk libraries will be loaded at VMAs starting at zero.
|
||||
|
||||
require !skip_shlib_tests
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require !skip_shlib_tests can_spawn_for_attach
|
||||
|
||||
# Library file.
|
||||
set libname "solib-overlap-lib"
|
||||
|
@ -18,9 +18,7 @@
|
||||
|
||||
require !skip_hw_watchpoint_tests
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -35,9 +35,7 @@ if [mi_gdb_start] {
|
||||
return
|
||||
}
|
||||
|
||||
if ![can_spawn_for_attach] {
|
||||
return
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
set string_re {(?:[^\\"]|\\.)*}
|
||||
|
||||
|
@ -26,9 +26,7 @@ if { [skip_gdbserver_tests] } {
|
||||
return 0
|
||||
}
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
if {[build_executable "build" $testfile $srcfile {debug}] == -1} {
|
||||
return -1
|
||||
|
@ -19,9 +19,7 @@
|
||||
|
||||
standard_testfile
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}]} {
|
||||
return -1
|
||||
|
@ -25,9 +25,7 @@
|
||||
|
||||
standard_testfile
|
||||
|
||||
if ![can_spawn_for_attach] {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
if [build_executable "failed to prepare" $testfile $srcfile {debug}] {
|
||||
return -1
|
||||
|
@ -20,9 +20,7 @@
|
||||
|
||||
standard_testfile
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
load_lib gdb-python.exp
|
||||
|
||||
|
@ -25,9 +25,7 @@ if { [skip_gdbserver_tests] } {
|
||||
return 0
|
||||
}
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
# Start the test program, attach to it using gdbserver's --attach flag, connect
|
||||
# to it with GDB, check that what we see makes sense.
|
||||
|
@ -26,9 +26,7 @@ if { [skip_gdbserver_tests] } {
|
||||
return 0
|
||||
}
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
|
||||
return -1
|
||||
|
@ -49,9 +49,7 @@ if {[bad_dejagnu]} {
|
||||
return 0
|
||||
}
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -19,9 +19,7 @@
|
||||
# - maint target non-stop off/on
|
||||
# - "attach" vs "attach &"
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -23,9 +23,7 @@ if ![istarget *-*-linux*] {
|
||||
return
|
||||
}
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
@ -48,9 +48,7 @@
|
||||
# a breakpoint, which has helped with exposing further corner case
|
||||
# bugs.
|
||||
|
||||
if {![can_spawn_for_attach]} {
|
||||
return 0
|
||||
}
|
||||
require can_spawn_for_attach
|
||||
|
||||
standard_testfile
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user