diff options
author | Mark Salter <msalter@sadr.localdomain> | 2003-01-31 13:11:26 +0000 |
---|---|---|
committer | Mark Salter <msalter@sadr.localdomain> | 2003-01-31 13:11:26 +0000 |
commit | b53f9b27afd4e5a9b9766e544d143d293bb32a6f (patch) | |
tree | e020bff0b85abb3e2967ae5b6f3178a9165d68d5 | |
parent | 31f7ba0423bfad4867253963a543e51cc05e0d89 (diff) | |
download | gdb-b53f9b27afd4e5a9b9766e544d143d293bb32a6f.zip gdb-b53f9b27afd4e5a9b9766e544d143d293bb32a6f.tar.gz gdb-b53f9b27afd4e5a9b9766e544d143d293bb32a6f.tar.bz2 |
Support remote targets.
-rw-r--r-- | gdb/testsuite/lib/mi-support.exp | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/gdb/testsuite/lib/mi-support.exp b/gdb/testsuite/lib/mi-support.exp index 399aac6..4b057d4 100644 --- a/gdb/testsuite/lib/mi-support.exp +++ b/gdb/testsuite/lib/mi-support.exp @@ -291,8 +291,15 @@ proc mi_gdb_load { arg } { global loadfile global GDB global mi_gdb_prompt + global last_mi_gdb_file upvar timeout timeout + if { $arg == "" } { + set arg $last_mi_gdb_file; + } + + set last_mi_gdb_file $arg; + # ``gdb_unload'' # ``gdb_file_cmd'' @@ -388,6 +395,26 @@ proc mi_gdb_load { arg } { return -1 } } + } elseif { [target_info gdb_protocol] == "remote" } { + # remote targets + send_gdb "target [target_info gdb_protocol] [target_info netport]\n" + gdb_expect 60 { + -re "\\^done,.*$mi_gdb_prompt$" { + } + timeout { + perror "Unable to connect to remote target" + return -1 + } + } + send_gdb "48-target-download\n" + gdb_expect 10 { + -re "48\\^done.*$mi_gdb_prompt$" { + } + timeout { + perror "Unable to download to remote target" + return -1 + } + } } return 0 } |