aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-elfvsb/sh2.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2006-12-05 01:29:58 +0000
committerAlan Modra <amodra@gmail.com>2006-12-05 01:29:58 +0000
commit125c64931b973e11b1e60d3cff5cf21e0681da3e (patch)
tree3aa1c581503ee8dbe001f640e5ac9df3836851e9 /ld/testsuite/ld-elfvsb/sh2.c
parente611e605d161a1cdf2c149ccf767b1139a12fc5a (diff)
downloadgdb-125c64931b973e11b1e60d3cff5cf21e0681da3e.zip
gdb-125c64931b973e11b1e60d3cff5cf21e0681da3e.tar.gz
gdb-125c64931b973e11b1e60d3cff5cf21e0681da3e.tar.bz2
* ld-elfvsb/sh1.c (overriddenvar, shlib_overriddencall2,
shared_data): If !SHARED, move to... * ld-elfvsb/sh2.c: ... here. * ld-elfvsb/elfvsb.exp: Add -DSHARED to compiler options when building with $picflag.
Diffstat (limited to 'ld/testsuite/ld-elfvsb/sh2.c')
-rw-r--r--ld/testsuite/ld-elfvsb/sh2.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/ld/testsuite/ld-elfvsb/sh2.c b/ld/testsuite/ld-elfvsb/sh2.c
index ef6b2f1..e9a9687 100644
--- a/ld/testsuite/ld-elfvsb/sh2.c
+++ b/ld/testsuite/ld-elfvsb/sh2.c
@@ -44,3 +44,18 @@ visibility_func_weak ()
return 2;
}
#endif
+
+#ifndef SHARED
+# ifndef XCOFF_TEST
+int overriddenvar = -1;
+
+int
+shlib_overriddencall2 ()
+{
+ return 7;
+}
+# endif
+# ifdef PROTECTED_TEST
+int shared_data = 100;
+# endif
+#endif