This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb] [LD][Testsuite] Add --no-dynamic-linker option to dynamic-1 rdynamic-1 test case.
- From: Renlin Li <renlin at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 13 Jun 2017 13:40:54 -0000
- Subject: [binutils-gdb] [LD][Testsuite] Add --no-dynamic-linker option to dynamic-1 rdynamic-1 test case.
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8569cfa78c2cc8b5ef66b0bebddcc0e63231fb51
commit 8569cfa78c2cc8b5ef66b0bebddcc0e63231fb51
Author: Renlin Li <renlin.li@arm.com>
Date: Tue Jun 13 14:03:47 2017 +0100
[LD][Testsuite] Add --no-dynamic-linker option to dynamic-1 rdynamic-1 test case.
arm-none-eabi-ld supports shared libraries. However, the toolchain may be
configured to generate statically linked executable by default.
It is required to have --no-dynamic-linker option before adding dynamic symbol
to static executable.
For dynamically linked executable, the behavior won't change.
ld/ChangeLog
2017-06-13 Renlin Li <renlin.li@arm.com>
* testsuite/ld-elf/shared.exp (build_tests): Add --no-dynamic-linker
option to rdynamic-1 and dynamic-1 tests.
Diff:
---
ld/ChangeLog | 5 +++++
ld/testsuite/ld-elf/shared.exp | 4 ++--
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/ld/ChangeLog b/ld/ChangeLog
index e21f447..1c81211 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,8 @@
+2017-06-13 Renlin Li <renlin.li@arm.com>
+
+ * testsuite/ld-elf/shared.exp (build_tests): Add --no-dynamic-linker
+ option to rdynamic-1 and dynamic-1 tests.
+
2017-06-09 H.J. Lu <hongjiu.lu@intel.com>
* testsuite/ld-x86-64/property-x86-3-x32.d: New file.
diff --git a/ld/testsuite/ld-elf/shared.exp b/ld/testsuite/ld-elf/shared.exp
index 070b51a..7c4e0a2 100644
--- a/ld/testsuite/ld-elf/shared.exp
+++ b/ld/testsuite/ld-elf/shared.exp
@@ -382,10 +382,10 @@ set build_tests {
"" ""
{pr2404b.c} {} "libpr2404b.a"}
{"Build rdynamic-1"
- "-Wl,-export-dynamic,--gc-sections" "-ffunction-sections"
+ "-Wl,--no-dynamic-linker,-export-dynamic,--gc-sections" "-ffunction-sections"
{rdynamic-1.c} {{readelf {-s} rdynamic-1.rd}} "rdynamic-1"}
{"Build dynamic-1"
- "-Wl,--dynamic-list,dynamic-1.syms -Wl,--gc-sections" "-ffunction-sections"
+ "-Wl,--no-dynamic-linker,--dynamic-list,dynamic-1.syms -Wl,--gc-sections" "-ffunction-sections"
{dynamic-1.c} {{readelf {-s} dynamic-1.rd}} "dynamic-1"}
{"Build libpr16496a.so"
"-shared -Wl,--version-script=pr16496a.map" "-fPIC"