diff options
author | Tom de Vries <tdevries@suse.de> | 2022-11-15 15:24:54 +0100 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2022-11-15 15:24:54 +0100 |
commit | b108c563f0f8a74813cae6b8e0e2b0089de32ba1 (patch) | |
tree | d5f96fa4451e0c3795e113388e57f5a9d91a81b9 /gdb | |
parent | 08d237dd4ebdcc0a13cac1dc57cd73de067d2f98 (diff) | |
download | gdb-b108c563f0f8a74813cae6b8e0e2b0089de32ba1.zip gdb-b108c563f0f8a74813cae6b8e0e2b0089de32ba1.tar.gz gdb-b108c563f0f8a74813cae6b8e0e2b0089de32ba1.tar.bz2 |
[gdb/testsuite] Fix gdb.base/foll-exec.exp for remote target
When running test-case gdb.base/foll-exec.exp with target board
remote-gdbserver-on-localhost.exp, I run into:
...
(gdb) PASS: gdb.base/foll-exec.exp: insert first exec catchpoint
continue^M
Continuing.^M
[Inferior 1 (process 4476) exited normally]^M
(gdb) FAIL: gdb.base/foll-exec.exp: continue to first exec catchpoint (the program e\
xited)
...
The problem is that the foll-exec executable expects the exec-ed executable
execd-prog alongside it, but it's missing.
Fix this by adding the missing gdb_remote_download.
Likewise in a few other test-cases.
Tested on x86_64-linux.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/testsuite/gdb.base/exec-invalid-sysroot.exp | 4 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/foll-exec.exp | 4 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/foll-vfork.exp | 4 |
3 files changed, 12 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.base/exec-invalid-sysroot.exp b/gdb/testsuite/gdb.base/exec-invalid-sysroot.exp index cacd5a0..7f7599c 100644 --- a/gdb/testsuite/gdb.base/exec-invalid-sysroot.exp +++ b/gdb/testsuite/gdb.base/exec-invalid-sysroot.exp @@ -33,6 +33,10 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable $c return -1 } +if { [is_remote target] } { + gdb_remote_download target $binfile2 +} + if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $compile_options] != "" } { untested "failed to compile main testcase" return -1 diff --git a/gdb/testsuite/gdb.base/foll-exec.exp b/gdb/testsuite/gdb.base/foll-exec.exp index 8cddfa5..a3d1a87 100644 --- a/gdb/testsuite/gdb.base/foll-exec.exp +++ b/gdb/testsuite/gdb.base/foll-exec.exp @@ -36,6 +36,10 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable $c return -1 } +if { [is_remote target] } { + gdb_remote_download target $binfile2 +} + if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $compile_options] != "" } { untested "failed to compile" return -1 diff --git a/gdb/testsuite/gdb.base/foll-vfork.exp b/gdb/testsuite/gdb.base/foll-vfork.exp index e4f7572..9627a17 100644 --- a/gdb/testsuite/gdb.base/foll-vfork.exp +++ b/gdb/testsuite/gdb.base/foll-vfork.exp @@ -42,6 +42,10 @@ if {[build_executable $testfile.exp $testfile2 $srcfile2 $compile_options] == -1 return -1 } +if { [is_remote target] } { + gdb_remote_download target [standard_output_file $testfile2] +} + # A few of these tests require a little more time than the standard # timeout allows. set oldtimeout $timeout |