This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: hppa64-hp-hpux11.00: invalid string offset for section .dynstr
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- To: hjl at lucon dot org (H . J . Lu)
- Cc: ross dot alexander at uk dot neceur dot com, law at redhat dot com, amodra at bigpond dot net dot au, binutils at sources dot redhat dot com, binutils-owner at sources dot redhat dot com
- Date: Wed, 19 Jun 2002 17:57:50 -0400 (EDT)
- Subject: Re: hppa64-hp-hpux11.00: invalid string offset for section .dynstr
> It sounds like a SHF_MERGE bug. I just fixed a SHF_MERGE bug on
> ELF/mips. Do
Well I can see that
--- bfd/elf-hppa.h.jj Fri Oct 5 13:02:02 2001
+++ bfd/elf-hppa.h Thu Nov 22 11:38:37 2001
@@ -1325,10 +1325,7 @@ elf_hppa_relocate_section (output_bfd, i
/* This is a local symbol. */
sym = local_syms + r_symndx;
sym_sec = local_sections[r_symndx];
- relocation = ((ELF_ST_TYPE (sym->st_info) == STT_SECTION
- ? 0 : sym->st_value)
- + sym_sec->output_offset
- + sym_sec->output_section->vma);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sym_sec, rel);
and the corresponding bit for elf32-hppa.c don't appear correct because we
are now adding in "sym->st_value" in all cases. Maybe the addend is wrong
as well.
It also seems that section merging has mucked up the offsets in relocatable
links as well.
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)