| Index: gdb/testsuite/gdb.base/disabled-location.exp
|
| diff --git a/gdb/testsuite/gdb.threads/tls-nodebug.exp b/gdb/testsuite/gdb.base/disabled-location.exp
|
| similarity index 58%
|
| copy from gdb/testsuite/gdb.threads/tls-nodebug.exp
|
| copy to gdb/testsuite/gdb.base/disabled-location.exp
|
| index 186a9da2f6c667932844de8188ffae6c30ec563d..169365c4dc4df2acc05c8286d89025317f47f6e6 100644
|
| --- a/gdb/testsuite/gdb.threads/tls-nodebug.exp
|
| +++ b/gdb/testsuite/gdb.base/disabled-location.exp
|
| @@ -1,5 +1,4 @@
|
| -# tls.exp -- Expect script to test thread-local storage without debuginfo
|
| -# Copyright (C) 2006-2012 Free Software Foundation, Inc.
|
| +# Copyright (C) 2012-2013 Free Software Foundation, Inc.
|
|
|
| # This program is free software; you can redistribute it and/or modify
|
| # it under the terms of the GNU General Public License as published by
|
| @@ -12,31 +11,31 @@
|
| # GNU General Public License for more details.
|
| #
|
| # You should have received a copy of the GNU General Public License
|
| -# along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
| +# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
| standard_testfile
|
|
|
| -if [istarget "*-*-linux"] then {
|
| - set target_cflags "-D_MIT_POSIX_THREADS"
|
| -} else {
|
| - set target_cflags ""
|
| -}
|
| -
|
| -if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable []] != "" } {
|
| +if { [prepare_for_testing ${testfile}.exp ${testfile}] } {
|
| return -1
|
| }
|
|
|
| -clean_restart ${binfile}
|
| if ![runto_main] then {
|
| fail "Can't run to main"
|
| return 0
|
| }
|
|
|
| -# Formerly: Cannot access memory at address 0x0
|
| -gdb_test "p thread_local" "= 42" "thread local storage"
|
| +gdb_test "break function" \
|
| + "Breakpoint.*at.* file .*$srcfile, line.*" \
|
| + "setting breakpoint on function"
|
|
|
| -# Done!
|
| -#
|
| -gdb_exit
|
| +gdb_test_no_output "disable \$bpnum.1" "disable location"
|
|
|
| -return 0
|
| +set test "step doesn't trip on disabled location"
|
| +gdb_test_multiple "step" $test {
|
| + -re "Breakpoint .*$gdb_prompt $" {
|
| + fail $test
|
| + }
|
| + -re "function \\(\\) at .*$srcfile:.*step stops here.*$gdb_prompt $" {
|
| + pass $test
|
| + }
|
| +}
|
|
|