[ELF] Relocatable executables issues

Fabio Alemagna falemagn@studenti.unina.it
Tue Jan 14 15:31:00 GMT 2003


On Tue, 14 Jan 2003, Fabio Alemagna wrote:
> That said, the 3rd approach I can think of is like the 1st one, except
> that the relocations have to be relative to the sections symbols, not to
> the single symbols. The question is: how do I do that? Could you please
> tell me where should I start looking at? Basically, what I'm looking for,
> is a way to do a sort of "prerelocation" by transforming a relocation
> relative to a symbol into a relocation relative to the beginning of the
> section where that symbol is in.

Oh, I forgot to say that, of course, these relocations should use symbols
from a different symbol section than the normal one, otherwise strip will
still need to be used with the --strip-unneeded. I think the DYNSYM
section could be used for that. Question: how do I make ld emit such
section?

Regards,
Fabio Alemagna



More information about the Binutils mailing list