PR ld/21375: MIPS: Fix non-zero run-time value for undefined weaks
[deliverable/binutils-gdb.git] / ld / emultempl / mipself.em
index c7c164274e7b9fbcfce221f3f48b46d149b0f0cd..ec8a086c923237b2a29cd21e53d1be664ee945a0 100644 (file)
 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
 # MA 02110-1301, USA.
 
+case ${target} in
+  *-*-*gnu*)
+    gnu_target=TRUE
+    ;;
+  *)
+    gnu_target=FALSE
+    ;;
+esac
+
 fragment <<EOF
 
 #include "ldctor.h"
@@ -203,7 +212,8 @@ mips_create_output_section_statements (void)
 
   htab = elf_hash_table (&link_info);
   if (is_elf_hash_table (htab) && is_mips_elf (link_info.output_bfd))
-    _bfd_mips_elf_linker_flags (&link_info, insn32, ignore_branch_isa);
+    _bfd_mips_elf_linker_flags (&link_info, insn32, ignore_branch_isa,
+                               ${gnu_target});
 
   if (is_mips_elf (link_info.output_bfd))
     _bfd_mips_elf_init_stubs (&link_info, mips_add_stub_section);
This page took 0.023368 seconds and 4 git commands to generate.