aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2001-11-30 08:07:34 +0000
committerH.J. Lu <hjl.tools@gmail.com>2001-11-30 08:07:34 +0000
commit679547726ae76ae4b9929ad13dd20f58edfe93dc (patch)
tree4be3477919082591a35721e978133798207086de /ld/testsuite
parent16333c4fa1324972804c8ddfb7b788ad6e07c69e (diff)
downloadgdb-679547726ae76ae4b9929ad13dd20f58edfe93dc.zip
gdb-679547726ae76ae4b9929ad13dd20f58edfe93dc.tar.gz
gdb-679547726ae76ae4b9929ad13dd20f58edfe93dc.tar.bz2
2001-11-29 H.J. Lu <hjl@gnu.org>
* ld-elfvers/vers.exp (build_vers_lib): Support linking against more than one libraries. Add "vers20a" and "vers20" tests for common symbols. * ld-elfvers/vers20.c: New. * ld-elfvers/vers20.dsym: New. * ld-elfvers/vers20.map: New. * ld-elfvers/vers20.ver: New. * ld-elfvers/vers20a.ver: New.
Diffstat (limited to 'ld/testsuite')
-rw-r--r--ld/testsuite/ChangeLog12
-rw-r--r--ld/testsuite/ld-elfvers/vers.exp13
-rw-r--r--ld/testsuite/ld-elfvers/vers20.c1
-rw-r--r--ld/testsuite/ld-elfvers/vers20.dsym2
-rw-r--r--ld/testsuite/ld-elfvers/vers20.map7
-rw-r--r--ld/testsuite/ld-elfvers/vers20.ver4
-rw-r--r--ld/testsuite/ld-elfvers/vers20a.ver4
7 files changed, 39 insertions, 4 deletions
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index 5b53e54..3450ec9 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,3 +1,15 @@
+2001-11-29 H.J. Lu <hjl@gnu.org>
+
+ * ld-elfvers/vers.exp (build_vers_lib): Support linking against
+ more than one libraries.
+ Add "vers20a" and "vers20" tests for common symbols.
+
+ * ld-elfvers/vers20.c: New.
+ * ld-elfvers/vers20.dsym: New.
+ * ld-elfvers/vers20.map: New.
+ * ld-elfvers/vers20.ver: New.
+ * ld-elfvers/vers20a.ver: New.
+
2001-11-19 H.J. Lu <hjl@gnu.org>
* ld-elfvsb/define.s: Mark all global lables as object.
diff --git a/ld/testsuite/ld-elfvers/vers.exp b/ld/testsuite/ld-elfvers/vers.exp
index c4b7892..c77466d 100644
--- a/ld/testsuite/ld-elfvers/vers.exp
+++ b/ld/testsuite/ld-elfvers/vers.exp
@@ -480,10 +480,11 @@ proc build_vers_lib { test source libname other mapfile verexp versymexp symexp
return
}
- if [string match "" $other] then {
- set other_lib ""
- } else {
- set other_lib $tmpdir/$other
+ set other_lib ""
+ if ![string match "" $other] then {
+ foreach o $other {
+ set other_lib "$tmpdir/$o $other_lib"
+ }
}
if [string match "" $mapfile] then {
@@ -816,3 +817,7 @@ build_exec "vers16" vers16.c vers16 "" vers16a.so "" vers16.dsym ""
build_vers_lib "vers17" vers17.c vers17 "" vers17.map vers17.ver vers17.dsym ""
build_vers_lib "vers18" vers18.c vers18 vers17.so vers18.map vers18.ver vers18.dsym vers18.sym
build_exec "vers19" vers19.c vers19 "-rpath ." vers18.so vers19.ver vers19.dsym ""
+
+build_vers_lib "vers20a" vers20.c vers20a "" vers20.map vers20a.ver vers20.dsym ""
+exec cp $tmpdir/vers20a.so $tmpdir/vers20b.so
+build_vers_lib "vers20" vers20.c vers20 "vers20a.so vers20b.so" vers20.map vers20.ver vers20.dsym ""
diff --git a/ld/testsuite/ld-elfvers/vers20.c b/ld/testsuite/ld-elfvers/vers20.c
new file mode 100644
index 0000000..01a6ff2
--- /dev/null
+++ b/ld/testsuite/ld-elfvers/vers20.c
@@ -0,0 +1 @@
+int show_foo;
diff --git a/ld/testsuite/ld-elfvers/vers20.dsym b/ld/testsuite/ld-elfvers/vers20.dsym
new file mode 100644
index 0000000..70aa05e
--- /dev/null
+++ b/ld/testsuite/ld-elfvers/vers20.dsym
@@ -0,0 +1,2 @@
+[0]*[ ]+g[ ]+DO[ ]+\*ABS\*[ ]+[0]*[ ]+VERS_1.1[ ]+VERS_1.1
+[0-9a-f]*[ ]+g[ ]+DO[ ]+.(s|)bss[ ]+[0-9a-f]*[ ]+VERS_1.1[ ]+show_foo
diff --git a/ld/testsuite/ld-elfvers/vers20.map b/ld/testsuite/ld-elfvers/vers20.map
new file mode 100644
index 0000000..e683565
--- /dev/null
+++ b/ld/testsuite/ld-elfvers/vers20.map
@@ -0,0 +1,7 @@
+VERS_1.1 {
+ global:
+ show_foo;
+ local:
+ *;
+};
+
diff --git a/ld/testsuite/ld-elfvers/vers20.ver b/ld/testsuite/ld-elfvers/vers20.ver
new file mode 100644
index 0000000..afeb137
--- /dev/null
+++ b/ld/testsuite/ld-elfvers/vers20.ver
@@ -0,0 +1,4 @@
+Version definitions:
+1 0x01 0x0965695f vers20.so
+2 0x00 0x0a7927b1 VERS_1.1
+
diff --git a/ld/testsuite/ld-elfvers/vers20a.ver b/ld/testsuite/ld-elfvers/vers20a.ver
new file mode 100644
index 0000000..2592f02
--- /dev/null
+++ b/ld/testsuite/ld-elfvers/vers20a.ver
@@ -0,0 +1,4 @@
+Version definitions:
+1 0x01 0x0652090f vers20a.so
+2 0x00 0x0a7927b1 VERS_1.1
+