This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Linker version script turning weak symbols into strong symbols


Kevin P. Fleming wrote:

> In spite of that, if I change test2 to not provide an alias for foo(),
> but instead use a plain weak symbol, then re-run the test, during the
> first phase (when test3 is not loaded), 'foo' in test2 is NULL, since it
> is a undefined weak symbol at that point. Loading test3 does not change
> that, as the symbol resolution for test2 has already been performed.

  I'd better add a disclaimer here that the behaviour of the ELF runtime
linker is at the edge of my knowledge, but if, as you say, symbol resolution
has been run on test2 when it was loaded and will not be run again when test3
is loaded yet you want test2 to know that a defintion of foo has now been made
available, aren't you just going to have to dlsym() it?

    cheers,
      DaveK


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]