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 | 3b35fb7cd0e2eeba611baf503d078fa395ebe1a8 (patch) | |
tree | e5c5e4ee46b7cf0af55aa184d5954e14edcea3d0 /gdbsupport/common-utils.cc | |
parent | 4b4f2a7d2551ecb98dbb3fbfff3e3ba177916f78 (diff) | |
download | binutils-3b35fb7cd0e2eeba611baf503d078fa395ebe1a8.zip binutils-3b35fb7cd0e2eeba611baf503d078fa395ebe1a8.tar.gz binutils-3b35fb7cd0e2eeba611baf503d078fa395ebe1a8.tar.bz2 |
[gdb/testsuite] Fix gdb.base/infcall-exec.exp for remote target
When running test-case gdb.base/infcall-exec.exp with target board
remote-gdbserver-on-localhost (using REMOTE_TARGET_USERNAME) we run into:
...
(gdb) call (int) execlp ("$outputs/gdb.base/infcall-exec/infcall-exec2", \
"$outputs/gdb.base/infcall-exec/infcall-exec2", (char *)0)^M
$1 = -1^M
(gdb) FAIL: gdb.base/infcall-exec.exp: call execlp
...
Fix this by using just:
...
(gdb) call (int) execlp ("infcall-exec2", "infcall-exec2", (char *)0)^M
...
and using putenv ("PATH=...") to allow infcall-exec to exec infcall-exec2
if it's available alongside.
Also fix the exec name in the test-case, such that we can successfully
run the test-case:
...
$ ./outputs/gdb.base/infcall-exec/infcall-exec
PATH SETTING: 'PATH=./outputs/gdb.base/infcall-exec'
$
...
Tested on x86_64-linux.
Co-Authored-by: Ivan Tetyushkin <ivan.tetyushkin@syntacore.com>
Diffstat (limited to 'gdbsupport/common-utils.cc')
0 files changed, 0 insertions, 0 deletions