This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [ld, testsuite] Only run rdynamic-1 when "-rdynamic" option is supported by compiler


On Fri, Mar 10, 2017 at 04:24:39PM +0000, Jiong Wang wrote:
> This is the following error on arm bare-metal
> 
>   FAIL: Build rdynamic-1
> 
> "-rdynamic" is not supported by most bare-metal GCC, the only bare-metal I am
> aware of is
>   https://gcc.gnu.org/ml/gcc-patches/2011-02/msg00567.html
> 
> This patch implemented a -rdynamic availability check and gated "rdynamic-1"
> build test.  GCC testsuite has added similar checks this week.
> 
>   https://gcc.gnu.org/ml/gcc-patches/2017-03/msg00258.html
> 
> No regression on X86-64/AArch64 native ld check.
> OK for master?

No.  I'll commit the following simpler patch after a test run.

diff --git a/ld/testsuite/ld-elf/shared.exp b/ld/testsuite/ld-elf/shared.exp
index 070915a..300100a 100644
--- a/ld/testsuite/ld-elf/shared.exp
+++ b/ld/testsuite/ld-elf/shared.exp
@@ -328,7 +328,7 @@ set build_tests {
    "" ""
    {pr2404b.c} {} "libpr2404b.a"}
   {"Build rdynamic-1"
-   "-rdynamic -Wl,--gc-sections" "-ffunction-sections"
+   "-Wl,-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"

-- 
Alan Modra
Australia Development Lab, IBM


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]