fix broken Xtensa bfd code for generating .got.loc sections
Bob Wilson
bwilson@tensilica.com
Thu Jul 24 00:14:00 GMT 2003
My previous changes to add the Xtensa-specific .got.loc section for dynamic
links missed a case where some of the Xtensa literal tables are discarded.
This patch fixes that by changing the discard_info_for_section function to
adjust the size of .got.loc when it removes literal table entries. Without
this patch, the linker fails without printing any error message, so the patch
also adds an error message in case similar failures occur in the future. It
also fixes a comment typo and some unrelated issues with error messages. I
tested this by building cross-binutils, cross-gcc and glibc for an
xtensa-linux target. The glibc build didn't completely finish but it failed
for unrelated reasons and got further than it ever has before with recent
tools. Committed on mainline.
2003-07-23 Bob Wilson <bob.wilson@acm.org>
* elf32-xtensa.c (plt_reloc_count): Fix typo in comment.
(elf_xtensa_size_dynamic_sections): Use elf_discarded_section.
(elf_xtensa_combine_prop_entries): Avoid returning non-zero without
first printing an error message.
(elf_xtensa_finish_dynamic_sections): Likewise.
(elf_xtensa_discard_info_for_section): Adjust size of .got.loc when
discarding literal table entries.
(elf_xtensa_merge_private_bfd_data): Remove newline from error
message.
(elf_xtensa_do_asm_simplify): Likewise.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix-bfd.diff
Type: text/x-diff
Size: 3828 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20030724/d717dc77/attachment.bin>
More information about the Binutils
mailing list