diff options
author | Alan Hayward <alan.hayward@arm.com> | 2019-04-23 14:12:25 +0100 |
---|---|---|
committer | Alan Hayward <alan.hayward@arm.com> | 2019-04-23 14:12:25 +0100 |
commit | ba22ff8694e366fe5f27824566aae65fc6626841 (patch) | |
tree | d50eee59fce91938e183da3cb4ed8b461f8ef6d5 /gdb | |
parent | 624a24513d2dcf7f2c2d42dbdf6d86be2f6d74aa (diff) | |
download | gdb-ba22ff8694e366fe5f27824566aae65fc6626841.zip gdb-ba22ff8694e366fe5f27824566aae65fc6626841.tar.gz gdb-ba22ff8694e366fe5f27824566aae65fc6626841.tar.bz2 |
Testsuite: Remove pie from trace tests
Ubuntu/Debian defaults PIE to enabled. This causes the trace tests
to fall over due to variables being returned as "unavailable". The
tests were never designed to work with pie.
Simply ensure the nopie flag is always used for the failing tests.
This removes 100+ failures when running native-gdbserver on Ubuntu 18.04.
gdb/testsuite/ChangeLog:
* gdb.trace/backtrace.exp: Use nopie flag.
* gdb.trace/circ.exp: Likewise.
* gdb.trace/collection.exp: Likewise.
* gdb.trace/ftrace.exp: Likewise.
* gdb.trace/mi-trace-unavailable.exp: Likewise.
* gdb.trace/mi-traceframe-changed.exp: Likewise.
* gdb.trace/qtro.exp: Likewise.
* gdb.trace/read-memory.exp: Likewise.
* gdb.trace/report.exp: Likewise.
* gdb.trace/tfile.exp: Likewise.
* gdb.trace/tfind.exp: Likewise.
* gdb.trace/unavailable.exp: Likewise.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/testsuite/ChangeLog | 15 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/backtrace.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/circ.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/collection.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/ftrace.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/mi-trace-unavailable.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/mi-traceframe-changed.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/qtro.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/read-memory.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/report.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/tfile.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/tfind.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/gdb.trace/unavailable.exp | 2 |
13 files changed, 27 insertions, 12 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 20bcd25..115623d 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,18 @@ +2019-04-23 Alan Hayward <alan.hayward@arm.com> + + * gdb.trace/backtrace.exp: Use nopie flag. + * gdb.trace/circ.exp: Likewise. + * gdb.trace/collection.exp: Likewise. + * gdb.trace/ftrace.exp: Likewise. + * gdb.trace/mi-trace-unavailable.exp: Likewise. + * gdb.trace/mi-traceframe-changed.exp: Likewise. + * gdb.trace/qtro.exp: Likewise. + * gdb.trace/read-memory.exp: Likewise. + * gdb.trace/report.exp: Likewise. + * gdb.trace/tfile.exp: Likewise. + * gdb.trace/tfind.exp: Likewise. + * gdb.trace/unavailable.exp: Likewise. + 2019-04-22 Pedro Alves <palves@redhat.com> * gdb.base/solib-probes-nosharedlibrary.c, diff --git a/gdb/testsuite/gdb.trace/backtrace.exp b/gdb/testsuite/gdb.trace/backtrace.exp index 0f60153..24e0971 100644 --- a/gdb/testsuite/gdb.trace/backtrace.exp +++ b/gdb/testsuite/gdb.trace/backtrace.exp @@ -27,7 +27,7 @@ if ![gdb_trace_common_supports_arch] { } if [prepare_for_testing "failed to prepare" $executable $srcfile \ - [list debug nowarnings]] { + [list debug nowarnings nopie]] { return -1 } diff --git a/gdb/testsuite/gdb.trace/circ.exp b/gdb/testsuite/gdb.trace/circ.exp index d48eca5..30ec9b4 100644 --- a/gdb/testsuite/gdb.trace/circ.exp +++ b/gdb/testsuite/gdb.trace/circ.exp @@ -17,7 +17,7 @@ load_lib "trace-support.exp" standard_testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings}]} { +if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings nopie}]} { return -1 } diff --git a/gdb/testsuite/gdb.trace/collection.exp b/gdb/testsuite/gdb.trace/collection.exp index 8c06438..44eccbe 100644 --- a/gdb/testsuite/gdb.trace/collection.exp +++ b/gdb/testsuite/gdb.trace/collection.exp @@ -19,7 +19,7 @@ load_lib "trace-support.exp" standard_testfile set executable $testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings}]} { +if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings nopie}]} { return -1 } diff --git a/gdb/testsuite/gdb.trace/ftrace.exp b/gdb/testsuite/gdb.trace/ftrace.exp index f97c2c6..702efe7 100644 --- a/gdb/testsuite/gdb.trace/ftrace.exp +++ b/gdb/testsuite/gdb.trace/ftrace.exp @@ -53,7 +53,7 @@ set remote_libipa [gdb_load_shlib $libipa] # file unused because linking not done" when building the object. if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ - executable [list debug $additional_flags shlib=$libipa] ] != "" } { + executable [list debug nopie $additional_flags shlib=$libipa] ] != "" } { untested "failed to compile" return -1 } diff --git a/gdb/testsuite/gdb.trace/mi-trace-unavailable.exp b/gdb/testsuite/gdb.trace/mi-trace-unavailable.exp index 5ec4bbc..f0b3c52 100644 --- a/gdb/testsuite/gdb.trace/mi-trace-unavailable.exp +++ b/gdb/testsuite/gdb.trace/mi-trace-unavailable.exp @@ -17,7 +17,7 @@ load_lib trace-support.exp standard_testfile trace-unavailable.c -if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug}] } { +if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug nopie}] } { return -1 } diff --git a/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp b/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp index 781d364..1244b5b 100644 --- a/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp +++ b/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp @@ -32,7 +32,7 @@ if {![is_remote host] && ![is_remote target]} { if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable \ - [list debug nowarnings \ + [list debug nowarnings nopie\ "additional_flags=-DTFILE_DIR=\"$tfile_dir\""]] \ != "" } { untested "failed to compile" diff --git a/gdb/testsuite/gdb.trace/qtro.exp b/gdb/testsuite/gdb.trace/qtro.exp index 9eabfeb..d5d912b 100644 --- a/gdb/testsuite/gdb.trace/qtro.exp +++ b/gdb/testsuite/gdb.trace/qtro.exp @@ -22,7 +22,7 @@ load_lib trace-support.exp standard_testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { +if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nopie}]} { return -1 } clean_restart $testfile diff --git a/gdb/testsuite/gdb.trace/read-memory.exp b/gdb/testsuite/gdb.trace/read-memory.exp index 61fc137..4d19f00 100644 --- a/gdb/testsuite/gdb.trace/read-memory.exp +++ b/gdb/testsuite/gdb.trace/read-memory.exp @@ -17,7 +17,7 @@ load_lib "trace-support.exp" standard_testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { +if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nopie}]} { return -1 } diff --git a/gdb/testsuite/gdb.trace/report.exp b/gdb/testsuite/gdb.trace/report.exp index f43fbb7..c847ab0 100644 --- a/gdb/testsuite/gdb.trace/report.exp +++ b/gdb/testsuite/gdb.trace/report.exp @@ -27,7 +27,7 @@ if ![gdb_trace_common_supports_arch] { return -1 } if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ - executable {debug nowarnings}] != "" } { + executable {debug nowarnings nopie}] != "" } { untested "failed to compile" return -1 } diff --git a/gdb/testsuite/gdb.trace/tfile.exp b/gdb/testsuite/gdb.trace/tfile.exp index 04f3e98..23f4fc5 100644 --- a/gdb/testsuite/gdb.trace/tfile.exp +++ b/gdb/testsuite/gdb.trace/tfile.exp @@ -37,7 +37,7 @@ if {![is_remote host] && ![is_remote target]} { standard_testfile if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ executable \ - [list debug \ + [list debug nopie\ "additional_flags=-DTFILE_DIR=\"$tfile_dir\""]] \ != "" } { untested "failed to compile" diff --git a/gdb/testsuite/gdb.trace/tfind.exp b/gdb/testsuite/gdb.trace/tfind.exp index 2c9996b..fb58f80 100644 --- a/gdb/testsuite/gdb.trace/tfind.exp +++ b/gdb/testsuite/gdb.trace/tfind.exp @@ -29,7 +29,7 @@ if ![gdb_trace_common_supports_arch] { } if { [gdb_compile "$srcdir/$subdir/$srcfile" "$binfile" \ - executable {debug nowarnings}] != "" } { + executable {debug nowarnings nopie}] != "" } { untested "failed to compile" return -1 } diff --git a/gdb/testsuite/gdb.trace/unavailable.exp b/gdb/testsuite/gdb.trace/unavailable.exp index 23d593e..f3bb54d 100644 --- a/gdb/testsuite/gdb.trace/unavailable.exp +++ b/gdb/testsuite/gdb.trace/unavailable.exp @@ -19,7 +19,7 @@ standard_testfile unavailable.cc set executable $testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ - {debug nowarnings c++}]} { + {debug nowarnings c++ nopie}]} { return -1 } |