[parisc-linux] Fix for hppa-linux ld.so with newer binutils

Alan Modra amodra@bigpond.net.au
Sun, 21 Oct 2001 20:50:22 +0930


On Sat, Oct 20, 2001 at 02:01:53PM -0400, Carlos O'Donell Jr. wrote:
> 
> Why aren't .got entries being initialised?

The special reserved .got entries are still initialised.  The others
which have relocations don't need to be initialised as the reloc will
set the value.  It was only an accident that entries against _DYNAMIC
(_not_ the special reserved entry with the value of _DYNAMIC) were
previously being initialised.

> So you are saying we need to make all of our global symbols constant
> so that we can access them during the bootstrap? (No more _DYNMAIC?)
> 
> And that elf_machine_load_address is trying to access symbols that aren't
> setup yet, because ELF_DYNAMIC_RELOCATE() hasn't been run yet?
> And thus hasn't setup any of our offsets... where has my pic code gone ;(

As you say, the problem is solved by pic code, and that's exactly how
the new hppa version of elf_machine_dynamic works.

Note that glibc ld.so still has a problem on hppa if it ever hits any
of the asserts in dynamic-link.h:elf_get_dynamic_info, as these all try
to make reference to their string args at the unrelocated address.

Alan