bfd/
authorRichard Sandiford <rdsandiford@googlemail.com>
Thu, 12 Apr 2007 19:27:35 +0000 (19:27 +0000)
committerRichard Sandiford <rdsandiford@googlemail.com>
Thu, 12 Apr 2007 19:27:35 +0000 (19:27 +0000)
* elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Don't add
DT_MIPS_RTLD_MAP for PIEs.

bfd/ChangeLog
bfd/elfxx-mips.c

index 962a288ac6eba6babb08cdec68c19b0aa98d2201..125960d78adeda1d29d48d9f823f4c685a8620d3 100644 (file)
@@ -1,3 +1,8 @@
+2007-04-12  Richard Sandiford  <richard@codesourcery.com>
+
+       * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Don't add
+       DT_MIPS_RTLD_MAP for PIEs.
+
 2007-04-12  Richard Sandiford  <richard@codesourcery.com>
 
        * elfxx-mips.c (mips_elf_calculate_relocation): Set DT_TEXTREL
index 5c782de5d5b2b5147f871e00d304e5f26a1a266f..c560e18f5693651eb0434d851993e6fb41236a42 100644 (file)
@@ -7586,18 +7586,16 @@ _bfd_mips_elf_size_dynamic_sections (bfd *output_bfd,
         must add the entries now so that we get the correct size for
         the .dynamic section.  The DT_DEBUG entry is filled in by the
         dynamic linker and used by the debugger.  */
-      if (info->executable)
-       {
-         /* SGI object has the equivalence of DT_DEBUG in the
-            DT_MIPS_RLD_MAP entry.  */
-         if (!MIPS_ELF_ADD_DYNAMIC_ENTRY (info, DT_MIPS_RLD_MAP, 0))
-           return FALSE;
-         if (!SGI_COMPAT (output_bfd))
-           {
-             if (!MIPS_ELF_ADD_DYNAMIC_ENTRY (info, DT_DEBUG, 0))
-               return FALSE;
-           }
-       }
+      if (info->executable
+         && !SGI_COMPAT (output_bfd)
+         && !MIPS_ELF_ADD_DYNAMIC_ENTRY (info, DT_DEBUG, 0))
+       return FALSE;
+
+      /* SGI object has the equivalence of DT_DEBUG in the
+        DT_MIPS_RLD_MAP entry.  */
+      if (!info->shared
+         && !MIPS_ELF_ADD_DYNAMIC_ENTRY (info, DT_MIPS_RLD_MAP, 0))
+       return FALSE;
 
       if (reltext && (SGI_COMPAT (output_bfd) || htab->is_vxworks))
        info->flags |= DF_TEXTREL;
This page took 0.031584 seconds and 4 git commands to generate.