aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-scripts/section-match-1.t
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2010-09-01 08:05:16 +0000
committerNick Clifton <nickc@redhat.com>2010-09-01 08:05:16 +0000
commitb97b635e0fb64036559954bfb8e90c7654243a07 (patch)
tree12f22fbb104e2c163634cc3a9a88cf1654b78abd /ld/testsuite/ld-scripts/section-match-1.t
parentbe5b8c8cdb018466f34d951409cd5f39c85db80a (diff)
downloadgdb-b97b635e0fb64036559954bfb8e90c7654243a07.zip
gdb-b97b635e0fb64036559954bfb8e90c7654243a07.tar.gz
gdb-b97b635e0fb64036559954bfb8e90c7654243a07.tar.bz2
* ld-scripts/section-match.exp: New file. Runs ths
section-match-1 test. * ld-scripts/section-match-1.d: New file. * ld-scripts/section-match-1.s: New file. * ld-scripts/section-match-1.t: New file.
Diffstat (limited to 'ld/testsuite/ld-scripts/section-match-1.t')
-rw-r--r--ld/testsuite/ld-scripts/section-match-1.t16
1 files changed, 16 insertions, 0 deletions
diff --git a/ld/testsuite/ld-scripts/section-match-1.t b/ld/testsuite/ld-scripts/section-match-1.t
new file mode 100644
index 0000000..155b3dc
--- /dev/null
+++ b/ld/testsuite/ld-scripts/section-match-1.t
@@ -0,0 +1,16 @@
+SECTIONS
+{
+ /* .secA should collect all sections with a prefix of ".sec."
+ except for those with a prefix of ".sec..". */
+ .secA : { *(*.sec.[^.]*) }
+
+ /* .secB should be empty because .secA will have taken all of
+ the potential matches. */
+ .secB : { *(*.sec.[!.]*) }
+
+ /* .secC should match any sections with a ".sec.." prefix. */
+ .secC : { *(*.sec.*) }
+
+ /* Ignore anything else. */
+ /DISCARD/ : { *(*) }
+}