[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: GPL-licensed packages with depend-chain to OpenSSL



David Schleef <ds@schleef.org> writes:

> On Thu, Aug 19, 2004 at 11:09:11AM +0200, Måns Rullgård wrote:
>> When using dynamic linking that is not necessarily the case.  Most
>> dynamic linkers use lazy loading of libraries, such that the openssl
>> libraries would not actually be mapped in to the process address space
>> until one of its functions is called.
>
> This is not how an ELF runtime linker works.  Run ldd on a binary --
> this lists all the shared object files that are mapped into the
> address space of the process before main() is called.

Sorry, I was a little too quick there.  The file is mapped, but is not
read from disk until the code is required.  The mapping is also shared
with other applications using the library.  Are all these applications
derived from each other?

> Symbol references are not necessarily resolved at that time, unless
> you define LD_BIND_NOW or are using prelinking.  There's really no
> method of doing "lazy linking" as you suggest with C, since it would
> either fail (such as with global variables in libraries) or be
> required to violate the ISO standard, such as taking the address of
> a function.

There is no requirement that the linker be written in C, or that it
follow any standard whatsoever as long as the interface and operation
visible to applications is as expected.

-- 
Måns Rullgård
mru@mru.ath.cx



Reply to: