diff options
author | Tom de Vries <tdevries@suse.de> | 2022-10-07 16:17:34 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2022-10-07 16:17:34 +0200 |
commit | 8ed73e316466987d0d33ce9e21ebc8ff9aa4c4d7 (patch) | |
tree | c5fefc476788a2c9d7aea172427a2f07a237b6aa /gdb/testsuite | |
parent | ea4e4a19b7f6c192c307b5a37c67d141f3aea074 (diff) | |
download | gdb-8ed73e316466987d0d33ce9e21ebc8ff9aa4c4d7.zip gdb-8ed73e316466987d0d33ce9e21ebc8ff9aa4c4d7.tar.gz gdb-8ed73e316466987d0d33ce9e21ebc8ff9aa4c4d7.tar.bz2 |
[gdb/testsuite] Fix path in test name in gdb_load_shlib
When running test-case gdb.server/solib-list.exp with target board
remote-gdbserver-on-localhost, I run into:
...
(gdb) set solib-search-path $outputs/gdb.server/solib-list^M
(gdb) PASS: gdb.server/solib-list.exp: non-stop 0: \
set solib-search-path $outputs/gdb.server/solib-list
PATH: gdb.server/solib-list.exp: non-stop 0: \
set solib-search-path $outputs/gdb.server/solib-list
...
This is due to this code in gdb_load_shlib:
...
gdb_test "set solib-search-path [file dirname $file]" "" ""
...
Fix this by setting an explicit test name.
Tested on x86_64-linux, with native and target boards
remote-gdbserver-on-localhost, native-gdbserver and native-extended-gdbserver.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/lib/gdb.exp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index 432ed5e..d60dcef 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -5614,7 +5614,8 @@ proc gdb_load_shlib { file } { # We could set this even when not testing remotely, but a user # generally won't set it unless necessary. In order to make the tests # more like the real-life scenarios, we don't set it for local testing. - gdb_test "set solib-search-path [file dirname $file]" "" "" + gdb_test "set solib-search-path [file dirname $file]" "" \ + "set solib-search-path for [file tail $file]" } return $dest |