* elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Create DT_PLTGOT
authorBob Wilson <bob.wilson@acm.org>
Tue, 4 Dec 2007 22:41:59 +0000 (22:41 +0000)
committerBob Wilson <bob.wilson@acm.org>
Tue, 4 Dec 2007 22:41:59 +0000 (22:41 +0000)
entry for all dynamic objects.

bfd/ChangeLog
bfd/elf32-xtensa.c

index 547b7580f38a75f8bce4212251f9643fd7d897c5..c0f367ca7c328fc8a6191a2f3e3368bf82312e25 100644 (file)
@@ -1,3 +1,8 @@
+2007-12-04  Bob Wilson  <bob.wilson@acm.org>
+
+       * elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Create DT_PLTGOT
+       entry for all dynamic objects.
+
 2007-12-04  Alan Modra  <amodra@bigpond.net.au>
 
        * elf32-spu.c (spu_elf_size_stubs): Correct section alignment.
index 6bf5609b67c8f7051b2d87051e4c4fb793d83743..c45a18c5bbfdd93832bb1bdc4e8197624cd5f89e 100644 (file)
@@ -1504,8 +1504,7 @@ elf_xtensa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
 
       if (relplt)
        {
-         if (!add_dynamic_entry (DT_PLTGOT, 0)
-             || !add_dynamic_entry (DT_PLTRELSZ, 0)
+         if (!add_dynamic_entry (DT_PLTRELSZ, 0)
              || !add_dynamic_entry (DT_PLTREL, DT_RELA)
              || !add_dynamic_entry (DT_JMPREL, 0))
            return FALSE;
@@ -1519,7 +1518,8 @@ elf_xtensa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
            return FALSE;
        }
 
-      if (!add_dynamic_entry (DT_XTENSA_GOT_LOC_OFF, 0)
+      if (!add_dynamic_entry (DT_PLTGOT, 0)
+         || !add_dynamic_entry (DT_XTENSA_GOT_LOC_OFF, 0)
          || !add_dynamic_entry (DT_XTENSA_GOT_LOC_SZ, 0))
        return FALSE;
     }