when to link into shared libs???

Daniel Jacobowitz drow@mvista.com
Thu May 22 15:47:00 GMT 2003


On Wed, May 21, 2003 at 01:00:49AM -0400, Jack Howarth wrote:
>     I would appreciate any information on topic of when it
> when it is appropriate to eliminate undefined non-weak symbols
> in a shared lib. I understand the case where the program itself
> will provide the symbols (as is the case with libthread_db.so.1).
> However I am unclear on a couple details.
> 
> 1) Does it matter how the program provides these symbols?
> If undefined non-weak symbols exist in a shared lib, does
> the program have to define them itself or is it sufficient for
> the program to merely link in another shared lib that does so.

Doesn't matter which.

> 2) While I understand that prelinking does nothing for 
> reducing the load time of shared libs that are dlopen'd,
> it is still unclear to me whether there is any advantage
> to eliminating undefined non-weak symbols from such libs.
> That is if a shared lib is dlopen'd, does glibc perform
> the dlopen'ing any faster if the shared lib has been
> exhaustively linked so that no undefined non-weak symbols
> exist in it? Or doesn't it really matter in that case?

I believe it makes no difference.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer



More information about the Libc-alpha mailing list