standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile] == -1} {
- return -1
+ return
}
# Split out BINFILE.debug. Remove debug from BINFILE.
if {[gdb_gnu_strip_debug $binfile] != 0} {
- return -1
+ return
}
# Get the '.build-id/xx/xxx...xxx' part of the filename.
set executable ${testfile}
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
proc do_test {nonstop} {
require allow_gdbserver_tests
if { [build_executable "failed to prepare" $testfile $srcfile debug] } {
- return -1
+ return
}
# Test connecting GDB to GDBserver without loading a symbol file.
standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Test spawning gdbserver with a program, connect to it and run to
require can_spawn_for_attach
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Run the test. TARGET_NON_STOP and TARGET_ASYNC should be 'on'
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
- return -1
+ return
}
# allow_xml_test must be called while gdb is not running.
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
- return -1
+ return
}
save_vars { GDBFLAGS } {
standard_testfile
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Core of the test. DO_KILL_P controls whether we kill one of the
require allow_gdbserver_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Make sure we're disconnected, in case we're testing with an
standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile]} {
- return -1
+ return
}
# EXTENDED_P is a boolean, when true gdbserver is started with --multi, and
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
- return -1
+ return
}
save_vars { GDBFLAGS } {
require allow_gdbserver_tests
if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
- return -1
+ return
}
save_vars { GDBFLAGS } {
if { [prepare_for_testing ${testfile}.exp $testfile \
$srcfile {debug additional_flags=-nostdlib} ] } {
- return -1
+ return
}
clean_restart
if {[build_executable "failed to prepare" $testfile $srcfile \
{debug build-id}] == -1} {
- return -1
+ return
}
# Split out BINFILE.debug. Remove debug from BINFILE.
if {[gdb_gnu_strip_debug $binfile] != 0} {
- return -1
+ return
}
# Get the '.build-id/xx/xxx...xxx' part of the filename.
standard_testfile normal.c
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
set target_binfile [gdb_remote_download target $binfile]
require {!is_remote target}
if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } {
- return -1
+ return
}
# Make sure we're disconnected, in case we're testing with an
standard_testfile server.c
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } {
- return -1
+ return
}
# Make sure we're disconnected, in case we're testing with an
if {[build_executable "failed to prepare" ${testfile} \
${srcfile}] == -1} {
- return -1
+ return
}
set target_binfile [gdb_remote_download target $binfile]
require allow_gdbserver_tests
if { [build_executable "failed to prepare" ${testfile}] } {
- return -1
+ return
}
# Spawn GDBserver, run to main, extract GDBserver's PID and save it in
require allow_gdbserver_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Make sure we're disconnected, in case we're testing with an
set executable ${testfile}
if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
- return -1
+ return
}
# Start GDB using remote type TARGET, which should be either "remote"
require allow_gdbserver_tests
if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
- return -1
+ return
}
save_vars { GDBFLAGS } {
if { [gdb_compile_shlib "${srcdir}/${subdir}/${srclibfile}" "${binlibfile}" {debug}] != ""
|| [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable "shlib=${binlibfile} build-id"] != "" } {
untested "failed to compile"
- return -1
+ return
}
set interp_system [section_get ${binfile} .interp]
standard_testfile
if { [build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1 } {
- return -1
+ return
}
set target_binfile [gdb_remote_download target $binfile]
standard_testfile
if { [build_executable "failed to prepare" $testfile $srcfile] == -1 } {
- return -1
+ return
}
set target_binfile [gdb_remote_download target $binfile]
standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile "additional_flags=--no-builtin"] == -1} {
- return -1
+ return
}
set target_binfile [gdb_remote_download target $binfile]
standard_testfile
if { [build_executable "failed to prepare" $testfile $srcfile debug] } {
- return -1
+ return
}
clean_restart
set status [lindex $res 0]
if { $status != 0 } {
fail "touching executable on target"
- return -1
+ return
}
# Start the inferior again, we expect to see the symbols being re-read
if { [build_executable "failed to prepare" $::testfile $::srcfile \
{debug}] } {
- return -1
+ return
}
# Don't use $binfile arg, to make sure we use the remote file target:$binfile.
if { [istarget *-*-mingw*]
|| [istarget *-*-cygwin*] } {
unsupported "gdbserver does not support --wrapper on this target (PR server/15967)"
- return -1
+ return
}
save_vars { GDBFLAGS } {