http://sourceware.org/gdb/wiki/TestingGDB#head-4eade7db27381c0f4747113b6edea1b8f365d73f
authorjkratoch <>
Tue, 19 Jan 2010 19:38:59 +0000 (19:38 +0000)
committerjkratoch <>
Tue, 19 Jan 2010 19:38:59 +0000 (19:38 +0000)
src/runtest-gdbserver/boards/native-gdbserver.exp [new file with mode: 0644]
src/runtest-gdbserver/site.exp [new file with mode: 0644]

diff --git a/src/runtest-gdbserver/boards/native-gdbserver.exp b/src/runtest-gdbserver/boards/native-gdbserver.exp
new file mode 100644 (file)
index 0000000..d027a2e
--- /dev/null
@@ -0,0 +1,54 @@
+# gdbserver running native.
+
+load_generic_config "gdbserver"
+process_multilib_options ""
+
+# The default compiler for this target.
+set_board_info compiler "[find_gcc]"
+
+# This gdbserver can only run a process once per session.
+set_board_info gdb,do_reload_on_run 1
+
+# There's no support for argument-passing (yet).
+set_board_info noargs 1
+
+# Can't do input (or output) in the current gdbserver.
+set_board_info gdb,noinferiorio 1
+
+# gdbserver does not intercept target file operations and perform them
+# on the host.
+set_board_info gdb,nofileio 1
+
+# Can't do hardware watchpoints, in general.
+set_board_info gdb,no_hardware_watchpoints 1
+
+set_board_info sockethost "localhost:"
+set_board_info use_gdb_stub 1
+
+# We will be using the standard GDB remote protocol.
+set_board_info gdb_protocol "remote"
+# Test the copy of gdbserver in the build directory.
+set_board_info gdb_server_prog "../gdbserver/gdbserver"
+
+proc ${board}_spawn { board cmd } {
+  global board_info
+
+  set baseboard [lindex [split $board "/"] 0]
+
+  set board_info($baseboard,isremote) 0
+  set result [remote_spawn $board $cmd]
+  set board_info($baseboard,isremote) 1
+
+  return $result
+}
+
+proc ${board}_download { board host dest } {
+  return $host
+}
+
+proc ${board}_file { dest op args } {
+    if { $op == "delete" } {
+        return 0
+    }
+    return [eval [list standard_file $dest $op] $args]
+}
diff --git a/src/runtest-gdbserver/site.exp b/src/runtest-gdbserver/site.exp
new file mode 100644 (file)
index 0000000..e69de29