[gandalf@winds.org: Trying to figure out a change in latest binutils for linux]
Alan Modra
amodra@bigpond.net.au
Tue Oct 22 17:14:00 GMT 2002
On Tue, Oct 22, 2002 at 02:42:58PM -0700, H. J. Lu wrote:
> Alan, Any ideas?
Yeah. The expression "err_not386 - _start" is not resolving because
err_not386 is in a different section and _start is global. Since
global ELF syms can be overridden, this sort of expression isn't
really proper; You'd need to emit a reloc against _two_ symbol for
this to work assuming ELF semantics. If the subtrahend were a local
label gas would happily turn this into a pcrel reloc against
err_not386.
Versions of gas prior to my write.c changes ignored the global
characteristics of ELF symbols used as subtrahends, treating them as
local syms. I guess I may need to return to this behaviour for the
sake of assembly code, since that seems to be the generally expected
thing. Opinions anyone?
--
Alan Modra
IBM OzLabs - Linux Technology Centre
More information about the Binutils
mailing list