bfd/
authorRichard Sandiford <rdsandiford@googlemail.com>
Fri, 20 Oct 2006 07:58:17 +0000 (07:58 +0000)
committerRichard Sandiford <rdsandiford@googlemail.com>
Fri, 20 Oct 2006 07:58:17 +0000 (07:58 +0000)
* elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Make the
size of .rel.dyn reflect the value of DT_RELSZ.

ld/testsuite/
* ld-mips-elf/multi-got-1.d: Remove trailing R_MIPS_NONE entries.
* ld-mips-elf/tls-multi-got-1.got: Likewise.
* ld-mips-elf/tls-multi-got-1.r: Likewise.

bfd/ChangeLog
bfd/elfxx-mips.c
ld/testsuite/ChangeLog
ld/testsuite/ld-mips-elf/multi-got-1.d
ld/testsuite/ld-mips-elf/tls-multi-got-1.got
ld/testsuite/ld-mips-elf/tls-multi-got-1.r

index 5a1cbd34543114653e3889853f1ea8a98812216f..304783a34fd2ae3e0f8c83e0f48acdee3522fd58 100644 (file)
@@ -1,3 +1,8 @@
+2006-10-20  Richard Sandiford  <richard@codesourcery.com>
+
+       * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Make the
+       size of .rel.dyn reflect the value of DT_RELSZ.
+
 2006-10-20  Richard Sandiford  <richard@codesourcery.com>
 
        * elfxx-mips.c (_bfd_mips_elf_additional_program_headers): Allocate
index 639a0658033fe68faa5fda3b4665df535057e11c..34a06c8df439c4fcdc588139654639c15b0b8e2b 100644 (file)
@@ -8873,6 +8873,10 @@ _bfd_mips_elf_finish_dynamic_sections (bfd *output_bfd,
                                * (ABI_64_P (output_bfd)
                                   ? sizeof (Elf64_Mips_External_Rel)
                                   : sizeof (Elf32_External_Rel)));
+             /* Adjust the section size too.  Tools like the prelinker
+                can reasonably expect the values to the same.  */
+             elf_section_data (s->output_section)->this_hdr.sh_size
+               = dyn.d_un.d_val;
              break;
 
            default:
index 22cdf09c71469ba64542b3adfd2cd50de9776e40..2c8ea098a2a6a4e95989b6938927787550013c41 100644 (file)
@@ -1,3 +1,9 @@
+2006-10-20  Richard Sandiford  <richard@codesourcery.com>
+
+       * ld-mips-elf/multi-got-1.d: Remove trailing R_MIPS_NONE entries.
+       * ld-mips-elf/tls-multi-got-1.got: Likewise.
+       * ld-mips-elf/tls-multi-got-1.r: Likewise.
+
 2006-10-20  Richard Sandiford  <richard@codesourcery.com>
 
        * ld-mips-elf/multi-got-1.d: Do not expect a particular address
index 3912439d483cb9ca3da7566eb7a8dec9b9c49512..db76eea6736913cc618a91df2428b5eead5362c5 100644 (file)
@@ -25,7 +25,7 @@ Dynamic section at offset .* contains 17 entries:
  0x70000013 \(MIPS_GOTSYM\)                0x[0-9a-f]+
  0x00000000 \(NULL\)                       0x0
 
-Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 8203 entries:
+Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 8193 entries:
  Offset     Info    Type            Sym.Value  Sym. Name
 00000000  00000000 R_MIPS_NONE      
 ^[0-9a-f]+  [0-9a-f]+ R_MIPS_REL32      [0-9a-f]+   sym_2_[0-9]+
@@ -8220,13 +8220,3 @@ Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 8203 entries:
 ^[0-9a-f]+  [0-9a-f]+ R_MIPS_REL32      [0-9a-f]+   sym_2_[0-9]+
 ^[0-9a-f]+  [0-9a-f]+ R_MIPS_REL32      [0-9a-f]+   sym_2_[0-9]+
 ^[0-9a-f]+  [0-9a-f]+ R_MIPS_REL32      [0-9a-f]+   sym_2_[0-9]+
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
-00000000  00000000 R_MIPS_NONE      
index 4ee502f70f3d6188f461c5230b7dd26616127452..649baae8d4d45b0d3dcf432b40c9bd237650f559 100644 (file)
@@ -15,28 +15,6 @@ OFFSET   TYPE              VALUE
 00143f7c R_MIPS_REL32      sym_1_9526
 #...
 00139bd0 R_MIPS_REL32      sym_2_8654
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
-00000000 R_MIPS_NONE       \*ABS\*
 
 
 Contents of section .got:
index c63d230ac23e0431fb71c916d0ceb267e8ec014e..db441147eccf4b403b329bd13df5712887c5d32c 100644 (file)
@@ -20,7 +20,7 @@ Dynamic section at offset .* contains 18 entries:
  0x0000001e \(FLAGS\)                      STATIC_TLS
  0x00000000 \(NULL\)                       0x0
 
-Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 20031 entries:
+Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 20009 entries:
  Offset     Info    Type            Sym.Value  Sym. Name
 [0-9a-f ]+R_MIPS_NONE      
 [0-9a-f ]+R_MIPS_TLS_DTPMOD
@@ -36,4 +36,3 @@ Relocation section '\.rel\.dyn' at offset 0x[0-9a-f]+ contains 20031 entries:
 #...
 [0-9a-f ]+R_MIPS_REL32      000cf2b4   sym_1_0465
 [0-9a-f ]+R_MIPS_REL32      000e0ef8   sym_2_8654
-#...
This page took 0.039858 seconds and 4 git commands to generate.