GNU Binutils with patches for OS216
Revision | 04981bc1fb2151ec0d6adf57793eea41779c2f34 (tree) |
---|---|
Time | 2009-06-16 11:14:12 |
Author | Maciej W. Rozycki <macro@linu...> |
Commiter | Maciej W. Rozycki |
bfd/
* elf32-vax.c (elf_vax_relocate_section): For symbol references
from an executable to a shared library treat R_VAX_PC32
relocations as R_VAX_PLT32 ones.
@@ -1,5 +1,11 @@ | ||
1 | 1 | 2009-06-16 Maciej W. Rozycki <macro@linux-mips.org> |
2 | 2 | |
3 | + * elf32-vax.c (elf_vax_relocate_section): For symbol references | |
4 | + from an executable to a shared library treat R_VAX_PC32 | |
5 | + relocations as R_VAX_PLT32 ones. | |
6 | + | |
7 | +2009-06-16 Maciej W. Rozycki <macro@linux-mips.org> | |
8 | + | |
3 | 9 | * elf32-vax.c (elf_vax_instantiate_got_entries): Skip local |
4 | 10 | symbols in GOT space calculation. |
5 | 11 | (elf_vax_relocate_section): Adjust accordingly. |
@@ -1544,6 +1544,14 @@ elf_vax_relocate_section (bfd *output_bfd, | ||
1544 | 1544 | } |
1545 | 1545 | break; |
1546 | 1546 | |
1547 | + case R_VAX_PC32: | |
1548 | + /* If we are creating an executable and the function this | |
1549 | + reloc refers to is in a shared lib, then we made a PLT | |
1550 | + entry for this symbol and need to handle the reloc like | |
1551 | + a PLT reloc. */ | |
1552 | + if (info->shared) | |
1553 | + goto r_vax_pc32_shared; | |
1554 | + /* Fall through. */ | |
1547 | 1555 | case R_VAX_PLT32: |
1548 | 1556 | /* Relocation is to the entry for this symbol in the |
1549 | 1557 | procedure linkage table. */ |
@@ -1605,7 +1613,7 @@ elf_vax_relocate_section (bfd *output_bfd, | ||
1605 | 1613 | |
1606 | 1614 | case R_VAX_PC8: |
1607 | 1615 | case R_VAX_PC16: |
1608 | - case R_VAX_PC32: | |
1616 | + r_vax_pc32_shared: | |
1609 | 1617 | if (h == NULL |
1610 | 1618 | || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT |
1611 | 1619 | || h->forced_local) |