diff options
author | Tom de Vries <tdevries@suse.de> | 2023-03-13 17:20:09 +0100 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2023-03-13 17:20:09 +0100 |
commit | 72f160d012233b7a322cd626e11f787f501beee2 (patch) | |
tree | 5ae94f3e21cc0b4b8a07cbeddfd94fddd95c5ab3 /gdb | |
parent | 6b81ded4876cb836e5fd7d8bc2459fef99dcac70 (diff) | |
download | binutils-72f160d012233b7a322cd626e11f787f501beee2.zip binutils-72f160d012233b7a322cd626e11f787f501beee2.tar.gz binutils-72f160d012233b7a322cd626e11f787f501beee2.tar.bz2 |
[gdb/testsuite] Require ![is_remote host] for TUI
When running test-case gdb.tui/corefile-run.exp with both host and target board
local-remote-host-native.exp, we run into:
...
FAIL: gdb.tui/corefile-run.exp: load corefile
...
while this passes with USE_TUI=0.
The problem is that the TUI setup code uses "setenv TERM ansi", which has no
effect on remote host.
I can confirm this analysis by working around this problem in
local-remote-host-native.exp like this:
...
- spawn $RSH -t -l $username $remote $cmd
+ spawn $RSH -t -l $username $remote "export TERM=ansi; $cmd"
...
For now, simply make TUI unsupported for remote host, by returning 0 in
prepare_for_tui.
Tested on x86_64-linux.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/testsuite/lib/tuiterm.exp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gdb/testsuite/lib/tuiterm.exp b/gdb/testsuite/lib/tuiterm.exp index 8a3f7a4..05edfe9 100644 --- a/gdb/testsuite/lib/tuiterm.exp +++ b/gdb/testsuite/lib/tuiterm.exp @@ -792,6 +792,14 @@ namespace eval Term { # Setup ready for starting the tui, but don't actually start it. # Returns 1 on success, 0 if TUI tests should be skipped. proc prepare_for_tui {} { + if { [is_remote host] } { + # In clean_restart, we're using "setenv TERM ansi", which has + # effect on build. If we have [is_remote host] == 0, so + # build == host, then it also has effect on host. But for + # [is_remote host] == 1, it has no effect on host. + return 0 + } + if {![allow_tui_tests]} { return 0 } |