summaryrefslogtreecommitdiff
path: root/bfd/elf32-xtensa.c
diff options
context:
space:
mode:
authorH.J. Lu <hjl@lucon.org>2009-06-17 18:08:35 +0000
committerH.J. Lu <hjl@lucon.org>2009-06-17 18:08:35 +0000
commitf0c48fe3cefb05390cbff64c756cb33a536cd506 (patch)
treec5ac26ed4a0e872093a877b56b4a5788770c3b34 /bfd/elf32-xtensa.c
parentaf4ef0275bdc67c30508511694a477ab9d98b56a (diff)
downloadbinutils-redhat-f0c48fe3cefb05390cbff64c756cb33a536cd506.tar.gz
2009-06-17 H.J. Lu <hongjiu.lu@intel.com>
* elf32-arm.c (create_got_section): Get existing .rela.got section. * elf32-hppa.c (elf32_hppa_create_dynamic_sections): Likewise. * elf32-lm32.c (create_got_section): Likewise. * elf32-m32r.c (create_got_section): Likewise. * elf32-ppc.c (ppc_elf_create_got): Likewise. * elf32-s390.c (create_got_section): Likewise. * elf32-sh.c (create_got_section): Likewise. * elf32-xtensa.c (elf_xtensa_create_dynamic_sections): Likewise. * elf64-s390.c (create_got_section): Likewise. * elfxx-sparc.c (create_got_section): Likewise. * elflink.c (_bfd_elf_create_got_section): Properly initialize the GOT size.
Diffstat (limited to 'bfd/elf32-xtensa.c')
-rw-r--r--bfd/elf32-xtensa.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/bfd/elf32-xtensa.c b/bfd/elf32-xtensa.c
index 09e81ad82e..4200f6fbdb 100644
--- a/bfd/elf32-xtensa.c
+++ b/bfd/elf32-xtensa.c
@@ -1404,6 +1404,7 @@ elf_xtensa_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info)
htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
htab->sgot = bfd_get_section_by_name (dynobj, ".got");
htab->sgotplt = bfd_get_section_by_name (dynobj, ".got.plt");
+ htab->srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
/* Create any extra PLT sections in case check_relocs has already
been called on all the non-dynamic input files. */
@@ -1419,12 +1420,6 @@ elf_xtensa_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info)
|| ! bfd_set_section_flags (dynobj, htab->sgotplt, flags))
return FALSE;
- /* Create ".rela.got". */
- htab->srelgot = bfd_make_section_with_flags (dynobj, ".rela.got", flags);
- if (htab->srelgot == NULL
- || ! bfd_set_section_alignment (dynobj, htab->srelgot, 2))
- return FALSE;
-
/* Create ".got.loc" (literal tables for use by dynamic linker). */
htab->sgotloc = bfd_make_section_with_flags (dynobj, ".got.loc", flags);
if (htab->sgotloc == NULL