aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2007-10-31 07:36:46 +0000
committerAlan Modra <amodra@gmail.com>2007-10-31 07:36:46 +0000
commit8f317e316924d673e4e685c88b202e845f4b0f79 (patch)
tree2a63f6e73966f5134124be8b23c4ac6f6f68d8e4 /bfd
parent081a0cdd45826347f2c755a9177c9365e40bbec4 (diff)
downloadgdb-8f317e316924d673e4e685c88b202e845f4b0f79.zip
gdb-8f317e316924d673e4e685c88b202e845f4b0f79.tar.gz
gdb-8f317e316924d673e4e685c88b202e845f4b0f79.tar.bz2
* elf-bfd.h (bfd_elf_match_symbols_in_sections): Don't declare.
* elflink.c (bfd_elf_match_symbols_in_sections): Make static. Remove section name comparisons.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog6
-rw-r--r--bfd/elf-bfd.h3
-rw-r--r--bfd/elflink.c18
3 files changed, 7 insertions, 20 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 5484c4b..6647eae 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2007-10-31 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (bfd_elf_match_symbols_in_sections): Don't declare.
+ * elflink.c (bfd_elf_match_symbols_in_sections): Make static.
+ Remove section name comparisons.
+
2007-10-30 Nick Clifton <nickc@redhat.com>
* reloc.c (BFD_RELOC_MN10300_ALIGN): Add.
diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
index 959e8b3..6afd9d1 100644
--- a/bfd/elf-bfd.h
+++ b/bfd/elf-bfd.h
@@ -1814,9 +1814,6 @@ extern bfd_boolean _bfd_elf_dynamic_symbol_p
extern bfd_boolean _bfd_elf_symbol_refs_local_p
(struct elf_link_hash_entry *, struct bfd_link_info *, bfd_boolean);
-extern bfd_boolean bfd_elf_match_symbols_in_sections
- (asection *, asection *, struct bfd_link_info *);
-
extern void bfd_elf_perform_complex_relocation
(bfd *, asection *, bfd_byte *, Elf_Internal_Rela *, bfd_vma);
diff --git a/bfd/elflink.c b/bfd/elflink.c
index ba2f540..084a6d2 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -6923,7 +6923,7 @@ elf_create_symbuf (bfd_size_type symcount, Elf_Internal_Sym *isymbuf)
/* Check if 2 sections define the same set of local and global
symbols. */
-bfd_boolean
+static bfd_boolean
bfd_elf_match_symbols_in_sections (asection *sec1, asection *sec2,
struct bfd_link_info *info)
{
@@ -6942,13 +6942,6 @@ bfd_elf_match_symbols_in_sections (asection *sec1, asection *sec2,
bfd1 = sec1->owner;
bfd2 = sec2->owner;
- /* If both are .gnu.linkonce sections, they have to have the same
- section name. */
- if (CONST_STRNEQ (sec1->name, ".gnu.linkonce")
- && CONST_STRNEQ (sec2->name, ".gnu.linkonce"))
- return strcmp (sec1->name + sizeof ".gnu.linkonce",
- sec2->name + sizeof ".gnu.linkonce") == 0;
-
/* Both sections have to be in ELF. */
if (bfd_get_flavour (bfd1) != bfd_target_elf_flavour
|| bfd_get_flavour (bfd2) != bfd_target_elf_flavour)
@@ -6957,15 +6950,6 @@ bfd_elf_match_symbols_in_sections (asection *sec1, asection *sec2,
if (elf_section_type (sec1) != elf_section_type (sec2))
return FALSE;
- if ((elf_section_flags (sec1) & SHF_GROUP) != 0
- && (elf_section_flags (sec2) & SHF_GROUP) != 0)
- {
- /* If both are members of section groups, they have to have the
- same group name. */
- if (strcmp (elf_group_name (sec1), elf_group_name (sec2)) != 0)
- return FALSE;
- }
-
shndx1 = _bfd_elf_section_from_bfd_section (bfd1, sec1);
shndx2 = _bfd_elf_section_from_bfd_section (bfd2, sec2);
if (shndx1 == -1 || shndx2 == -1)