diff options
author | Ian Lance Taylor <ian@airs.com> | 1994-10-27 21:25:31 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 1994-10-27 21:25:31 +0000 |
commit | 14cac507a88e921a16b8847ffe8ade8e7e8160b3 (patch) | |
tree | c05a389c67f4a9cca9ec34989e065b75df2dc731 /bfd/libelf.h | |
parent | c51975113da1ac36f42768dbbeb6bc90545be5f8 (diff) | |
download | gdb-14cac507a88e921a16b8847ffe8ade8e7e8160b3.zip gdb-14cac507a88e921a16b8847ffe8ade8e7e8160b3.tar.gz gdb-14cac507a88e921a16b8847ffe8ade8e7e8160b3.tar.bz2 |
* libelf.h (struct bfd_elf_section_data): Add field dynindx.
* elfcode.h (NAME(bfd_elf,size_dynamic_sections)): Don't finalize
the .dynsym, .dynstr or .hash sections until after the backend
size_dynamic_sections routine, so that it can add dynamic symbols
if it wants to.
* elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't define the
symbol to be in the .plt section when generating a shared library
if it is a defined symbol.
* elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Likewise.
(elf32_sparc_size_dynamic_sections): When generating a shared
library, allocate space for a dynamic symbol for each output
section, storing the index in the dynindx field of the ELF section
data. Adjust the other dynindx fields to account for this.
(elf32_sparc_adjust_dynindx): New static function.
(elf32_sparc_relocate_section): When copying a reloc into a shared
library, use the original addend as appropriate. Convert an
R_SPARC_32 reloc into an R_SPARC_RELATIVE reloc. Use the dynamic
symbol index of the output section, not the normal symbol index.
(elf32_sparc_finish_dynamic_sections): Don't die if a section does
not exist when setting the value of the dynamic tags. Write out
a dynamic symbol for each output section.
Diffstat (limited to 'bfd/libelf.h')
-rw-r--r-- | bfd/libelf.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bfd/libelf.h b/bfd/libelf.h index b752946..3bbde89 100644 --- a/bfd/libelf.h +++ b/bfd/libelf.h @@ -420,6 +420,10 @@ struct bfd_elf_section_data { rather than RELA, all the r_addend fields will be zero. This pointer may be NULL. It is used by the backend linker. */ Elf_Internal_Rela *relocs; + /* Used by the backend linker when generating a shared library to + record the dynamic symbol index for a section symbol + corresponding to this section. */ + long dynindx; }; #define elf_section_data(sec) ((struct bfd_elf_section_data*)sec->used_by_bfd) |