weak handling
H . J . Lu
hjl@lucon.org
Wed Jun 7 20:33:00 GMT 2000
On Wed, Jun 07, 2000 at 08:08:12PM -0700, Ulrich Drepper wrote:
> I just checked in a patch which brings the handling of weak
> definitions at runtime in line with the official[*] ELF
> interpretation. That is weak symbol definitions are treated like
> normal definitions during dynamic linking. The weak attribute is only
> used in the static linker (and for references).
>
> This came up some time ago during the ELF discussions HJ and I are
> participating in. I cannot think of a program which would have
> problems because of this change. In case there is one the user can
> switch back to the old behaviour by having LD_DYNAMIC_WEAK in the
> environment.
>
> The reason I've made this change is not really to be more conformant
> (it's nice but no reason since nobody complained about the old
> behaviour). The real reason is that some more features (like lazy
> loading) depend on this interpretation of weak definitions.
>
> If you have or see problems with this let me know.
I could be wrong. What will happen to those libc symbols defined in
the dynamic linker used for bootstrap? I thought those symbols were
weak in ld.so and would be overridden by the strong ones in libc.so.
H.J.
More information about the Libc-hacker
mailing list