aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/lib
diff options
context:
space:
mode:
authorJim Wilson <jimw@sifive.com>2018-01-09 10:08:47 -0800
committerJim Wilson <jimw@sifive.com>2018-01-09 10:08:47 -0800
commit74ccf6db1188b7b05c716f8382d28b276ec578ec (patch)
treeb0197e0e104473cc54396b47546ad2cf78374dcc /ld/testsuite/lib
parent91d8b670661883fc0472fd05cf0e54d0e357c187 (diff)
downloadgdb-74ccf6db1188b7b05c716f8382d28b276ec578ec.zip
gdb-74ccf6db1188b7b05c716f8382d28b276ec578ec.tar.gz
gdb-74ccf6db1188b7b05c716f8382d28b276ec578ec.tar.bz2
Add explicit shared check to eh-frame-hdr test.
ld/ * testsuite/ld-elf/eh-frame-hdr.d (#xfail): Delete (#alltargets): Renamed from #target. Add shared. * testsuite/lib/ld-lib.exp (run_dump_test): Document shared target. Document alltargets option. Add support for alltargets option. (istarget): Add support for shared target.
Diffstat (limited to 'ld/testsuite/lib')
-rw-r--r--ld/testsuite/lib/ld-lib.exp18
1 files changed, 17 insertions, 1 deletions
diff --git a/ld/testsuite/lib/ld-lib.exp b/ld/testsuite/lib/ld-lib.exp
index bfbc30d..52baf0b 100644
--- a/ld/testsuite/lib/ld-lib.exp
+++ b/ld/testsuite/lib/ld-lib.exp
@@ -519,7 +519,13 @@ proc ld_link_defsyms {} {
# target: TARGET
# Only run the test for TARGET. This may occur more than once; the
# target being tested must match at least one. You may provide target
-# name "cfi" for any target supporting the CFI statements.
+# name "cfi" for any target supporting the CFI statements. You may
+# provide target name "shared" for any target supporting shared
+# libraries.
+#
+# alltargets: TARGET
+# Only run the test for TARGET. This may occur more than once; the
+# target being tested must match all of them.
#
# notarget: TARGET
# Do not run the test for TARGET. This may occur more than once;
@@ -599,6 +605,7 @@ proc run_dump_test { name {extra_options {}} } {
set opts(ld_after_inputfiles) {}
set opts(xfail) {}
set opts(target) {}
+ set opts(alltargets) {}
set opts(notarget) {}
set opts(objdump) {}
set opts(nm) {}
@@ -628,6 +635,7 @@ proc run_dump_test { name {extra_options {}} } {
switch -- $opt_name {
xfail {}
target {}
+ alltargets {}
notarget {}
warning {}
error {}
@@ -726,6 +734,11 @@ proc run_dump_test { name {extra_options {}} } {
return
}
}
+ foreach targ $opts(alltargets) {
+ if ![istarget $targ] {
+ return
+ }
+ }
foreach targ $opts(notarget) {
if [istarget $targ] {
return
@@ -2152,6 +2165,9 @@ proc istarget { target } {
if {$target == "cfi"} {
return [check_as_cfi]
}
+ if {$target == "shared"} {
+ return [check_shared_lib_support]
+ }
return [istarget_ld $target]
}