diff options
author | H.J. Lu <hjl@lucon.org> | 2004-07-27 14:20:49 +0000 |
---|---|---|
committer | H.J. Lu <hjl@lucon.org> | 2004-07-27 14:20:49 +0000 |
commit | d40e5402044d882444fba6d58dc416828ccba7df (patch) | |
tree | 48a2a11dc013dbc7d0a621ba6d7193cb2e482123 /bfd/linker.c | |
parent | 0655e53011e3cf999f9de9b062bc85766b26b6d7 (diff) | |
download | binutils-redhat-d40e5402044d882444fba6d58dc416828ccba7df.tar.gz |
2004-07-27 H.J. Lu <hongjiu.lu@intel.com>
PR 161/251
* elf-bfd.h (bfd_elf_section_data): Add sec_group.
(elf_sec_group): Defined.
(bfd_elf_match_symbols_in_sections): New prototype.
(_bfd_elf_setup_group_pointers): Likewise.
* elf.c (bfd_elf_discard_group): Abort.
(bfd_elf_set_group_contents): Also include relocation sections.
Remove zero-fill for ld -r.
(_bfd_elf_setup_group_pointers): New function.
(elf_sort_elf_symbol): Likewise.
(elf_sym_name_compare): Likewise.
(bfd_elf_match_symbols_in_sections): Likewise.
* elfcode.h (elf_object_p): Call _bfd_elf_setup_group_pointers.
* elflink.c (match_group_member): New.
(elf_link_input_bfd): Check group member for discarded section.
(try_match_symbols_in_sections): New function.
(already_linked): Likewise.
(_bfd_elf_section_already_linked): Support mixing comdat group
and linkonce section.
* libbfd-in.h (bfd_section_already_linked_table_traverse): New.
* linker.c (bfd_section_already_linked_table_traverse): New.
* libbfd.h: Regenerated.
Diffstat (limited to 'bfd/linker.c')
-rw-r--r-- | bfd/linker.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/bfd/linker.c b/bfd/linker.c index cd2adb5e51..a2095dccba 100644 --- a/bfd/linker.c +++ b/bfd/linker.c @@ -2858,8 +2858,19 @@ DESCRIPTION static struct bfd_hash_table _bfd_section_already_linked_table; /* Support routines for the hash table used by section_already_linked, - initialize the table, lookup, fill in an entry and remove the - table. */ + initialize the table, traverse, lookup, fill in an entry and remove + the table. */ + +void +bfd_section_already_linked_table_traverse + (bfd_boolean (*func) (struct bfd_section_already_linked_hash_entry *, + void *), void *info) +{ + bfd_hash_traverse (&_bfd_section_already_linked_table, + (bfd_boolean (*) (struct bfd_hash_entry *, + void *)) func, + info); +} struct bfd_section_already_linked_hash_entry * bfd_section_already_linked_table_lookup (const char *name) |