OLD | NEW |
1 # Copyright 1997, 1999, 2007-2012 Free Software Foundation, Inc. | 1 # Copyright 1997, 1999, 2007-2012 Free Software Foundation, Inc. |
2 | 2 |
3 # This program is free software; you can redistribute it and/or modify | 3 # This program is free software; you can redistribute it and/or modify |
4 # it under the terms of the GNU General Public License as published by | 4 # it under the terms of the GNU General Public License as published by |
5 # the Free Software Foundation; either version 3 of the License, or | 5 # the Free Software Foundation; either version 3 of the License, or |
6 # (at your option) any later version. | 6 # (at your option) any later version. |
7 # | 7 # |
8 # This program is distributed in the hope that it will be useful, | 8 # This program is distributed in the hope that it will be useful, |
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of |
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
11 # GNU General Public License for more details. | 11 # GNU General Public License for more details. |
12 # | 12 # |
13 # You should have received a copy of the GNU General Public License | 13 # You should have received a copy of the GNU General Public License |
14 # along with this program. If not, see <http://www.gnu.org/licenses/>. | 14 # along with this program. If not, see <http://www.gnu.org/licenses/>. |
15 | 15 |
16 if { [is_remote target] || ![isnative] } then { | 16 if { [is_remote target] || ![isnative] } then { |
17 continue | 17 continue |
18 } | 18 } |
19 | 19 |
| 20 # Until "set follow-fork-mode" and "catch fork" are implemented on |
| 21 # other targets... |
| 22 # |
| 23 if {![istarget "hppa*-hp-hpux*"] && ![istarget "*-linux*"]} then { |
| 24 continue |
| 25 } |
20 | 26 |
21 global srcfile | 27 global srcfile |
22 set testfile "foll-fork" | 28 set testfile "foll-fork" |
23 set srcfile ${testfile}.c | 29 set srcfile ${testfile}.c |
24 set binfile ${objdir}/${subdir}/${testfile} | 30 set binfile ${objdir}/${subdir}/${testfile} |
25 | 31 |
26 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug}] != "" } { | 32 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug}] != "" } { |
27 untested foll-fork.exp | 33 untested foll-fork.exp |
28 return -1 | 34 return -1 |
29 } | 35 } |
30 | 36 |
31 | |
32 | |
33 # Until "set follow-fork-mode" and "catch fork" are implemented on | |
34 # other targets... | |
35 # | |
36 if {![istarget "hppa*-hp-hpux*"] && ![istarget "*-linux*"]} then { | |
37 continue | |
38 } | |
39 | |
40 proc check_fork_catchpoints {} { | 37 proc check_fork_catchpoints {} { |
41 global gdb_prompt | 38 global gdb_prompt |
42 | 39 |
43 # Verify that the system supports "catch fork". | 40 # Verify that the system supports "catch fork". |
44 gdb_test "catch fork" "Catchpoint \[0-9\]* \\(fork\\)" "insert first fork catc
hpoint" | 41 gdb_test "catch fork" "Catchpoint \[0-9\]* \\(fork\\)" "insert first fork catc
hpoint" |
45 set has_fork_catchpoints 0 | 42 set has_fork_catchpoints 0 |
46 gdb_test_multiple "continue" "continue to first fork catchpoint" { | 43 gdb_test_multiple "continue" "continue to first fork catchpoint" { |
47 -re ".*Your system does not support this type\r\nof catchpoint.*$gdb_prompt
$" { | 44 -re ".*Your system does not support this type\r\nof catchpoint.*$gdb_prompt
$" { |
48 unsupported "continue to first fork catchpoint" | 45 unsupported "continue to first fork catchpoint" |
49 } | 46 } |
(...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 # The "Detaching..." and "Attaching..." messages may be hidden by | 341 # The "Detaching..." and "Attaching..." messages may be hidden by |
345 # default. | 342 # default. |
346 gdb_test_no_output "set verbose" | 343 gdb_test_no_output "set verbose" |
347 | 344 |
348 # This is a test of gdb's ability to follow the parent, child or both | 345 # This is a test of gdb's ability to follow the parent, child or both |
349 # parent and child of a Unix fork() system call. | 346 # parent and child of a Unix fork() system call. |
350 # | 347 # |
351 do_fork_tests | 348 do_fork_tests |
352 | 349 |
353 return 0 | 350 return 0 |
OLD | NEW |