ChangeLog rotation
[deliverable/binutils-gdb.git] / ld / testsuite / ld-elf / shared.exp
index 7514eb116bb4572ee4ad598ab575871aea0f728a..cc145b48cb98c4cbaae463cd1439735354bfd038 100644 (file)
@@ -34,6 +34,8 @@ if ![check_shared_lib_support] {
 # Add $NOPIE_CFLAGS and $NOPIE_LDFLAGS if non-PIE is required.
 global NOPIE_CFLAGS NOPIE_LDFLAGS
 
+set old_ASFLAGS $ASFLAGS
+
 # This target requires extra GAS options when building code for shared
 # libraries.
 set AFLAGS_PIC ""
@@ -81,6 +83,31 @@ run_ld_link_tests [list \
     ] \
 ]
 
+run_ld_link_tests [list \
+    [list \
+       "DT_TEXTREL in shared lib" \
+       "$LFLAGS -shared --warn-shared-textrel" \
+       "" \
+       "$AFLAGS_PIC" \
+       {textrel.s} \
+        {{ld textrel.warn} \
+         {readelf {-d --wide} textrel.rd}} \
+       "textrel.so" \
+    ] \
+] "xtensa-*-*"
+
+run_ld_link_tests [list \
+    [list \
+       "DT_TEXTREL map file warning" \
+       "$LFLAGS -shared -M" \
+       "" \
+       "$AFLAGS_PIC" \
+       {textrel.s} \
+        {{ld textrel.map}} \
+       "textrel.so" \
+    ] \
+] "cris*-*-*"
+
 # PR ld/20828 check for correct dynamic symbol table entries where:
 # - symbols have been defined with a linker script,
 # - the same symbols have been seen in shared library used in the link,
@@ -221,6 +248,8 @@ if { [check_gc_sections_available] } {
     ]
 }
 
+set ASFLAGS $old_ASFLAGS
+
 # Check to see if the C compiler works
 if { [which $CC] == 0 } {
     return
This page took 0.023254 seconds and 4 git commands to generate.