gdb/testsuite/
authorNathan Froyd <froydnj@codesourcery.com>
Fri, 12 Nov 2010 21:47:47 +0000 (21:47 +0000)
committerNathan Froyd <froydnj@codesourcery.com>
Fri, 12 Nov 2010 21:47:47 +0000 (21:47 +0000)
* gdb.base/break-entry.exp: Skip if using a stub.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/break-entry.exp

index 0694d9c4819d8615525a6dd0bcb998c0b6f38813..2a6c11bd274ea6227c352414d8271197cc9b66bb 100644 (file)
@@ -1,3 +1,7 @@
+2010-11-12  Nathan Froyd  <froydnj@codesourcery.com>
+
+       * gdb.base/break-entry.exp: Skip if using a stub.
+
 2010-11-12  Nathan Froyd  <froydnj@codesourcery.com>
 
        * gdb.python/py-inferior.exp: Pack values in target endianness.
index 13605042e6e7d042de6d2624c4821006808df727..151eb04634832ab5cb36269924b4cceb8b7dc8cf 100644 (file)
@@ -21,6 +21,20 @@ if { [prepare_for_testing ${testfile}.exp ${testfile} start.c {additional_flags=
     return -1
 }
 
+# If we're using a stub, we'll already be debugging a live program and
+# stopped at the entry point when we connect, and so the runto below
+# will issue a "continue", which always skips any breakpoint at PC.
+# When testing with a native target (or some other target that supports
+# "run"), runto will do a "run", which first creates the process,
+# leaving the PC at the entry point, just like the stub case, but then
+# continues the process with the equivalent of "jump *$PC", which
+# triggers any breakpoint at $PC.  The latter is what we want to test.
+
+if [target_info exists use_gdb_stub] {
+    untested ${testfile}.exp
+    return
+}
+
 set test "info files"
 set entry ""
 gdb_test_multiple $test $test {