* gdb.c++/templates.cc (printf): Remove unused function definition.
+2001-01-26 Felix Lee <flee@redhat.com>
+
+ * sid.exp (sid_exit): Pass host, not target, to remote_close.
+
+2001-01-25 matthew green <mrg@redhat.com>
+
+ * config/sid.exp (sid_start): Call `remote_push_conn' after firing
+ up sid.
+ (sid_exit): Call `remote_pop_conn' after GDB is gone.
+
+2001-01-25 matthew green <mrg@redhat.com>
+
+ * config/sid.exp (sid_start): Use `remote_spawn' instead of `spawn.'
+ Deprecate $sid_spawn_id.
+ (sid_exit): Remove code necessary only for `spawn.'
+
+2001-01-25 matthew green <mrg@redhat.com>
+
+ * config/sid.exp (sid_start): Handle sim,protocol of `sid.'
+
2001-01-17 Ben Elliston <bje@redhat.com>
* config/sid.exp: New file.
load_lib gdb.exp
proc sid_start {} {
- global sid_spawn_id
global verbose
set port [lindex [split [target_info netport] ":"] 1]
set env(MKSID) "../../sid/main/static/mksid"
if {! [file exists $env(SID)]} then { error "Cannot find sid in build tree" }
}
- set spawncmd "../../sid/bsp/[target_info sim] $sidverbose $sidendian --persistent --gdb=$port [target_info sim,options]"
+ if { [board_info target sim,protocol] == "sid" } {
+ set spawncmd "[target_info sim] [target_info sim,options] -e \"set gdb-socket sockaddr-local 0.0.0.0:$port\""
+ } else {
+ set spawncmd "../../sid/bsp/[target_info sim] $sidverbose $sidendian --gdb=$port [target_info sim,options]"
+ }
set post_spawn {
global env
unset env(SID_LIBRARY_PATH)
unset env(SID)
}
} else {
+ global find_rawsid;
+
set pre_spawn {}
- set spawncmd "[target_info sim] $sidverbose $sidendian --persistent --gdb=$port [target_info sim,options]"
+ if { [board_info target sim,protocol] == "sid" } {
+ # FIXME: sim,options may be from the build tree, should find
+ # it in the install tree.
+ set spawncmd "sid [target_info sim,options] -e \"set gdb-socket sockaddr-local 0.0.0.0:$port\""
+ } else {
+ set spawncmd "[target_info sim] $sidverbose $sidendian --gdb=$port [target_info sim,options]"
+ }
set post_spawn {}
}
eval $pre_spawn
- if {[catch "spawn $spawncmd" msg]} {
+ if {[catch [list remote_spawn host $spawncmd] msg]} {
perror $msg
exit 1
}
# GDB would wait for a fair while for the stub to respond.
sleep 4
- set sid_spawn_id $spawn_id
+ if ![target_info exists gdb,no_push_conn] {
+ remote_push_conn host;
+ }
}
#
}
proc sid_exit {} {
- global sid_spawn_id
- if {[info exists sid_spawn_id]} {
- catch {exec kill [exp_pid -i $sid_spawn_id]}
- catch {wait -i $sid_spawn_id}
- unset sid_spawn_id
- sleep 4
+ if ![target_info exists gdb,no_push_conn] {
+ remote_close host;
+ remote_pop_conn host;
}
}