libtool
[Top][All Lists]
Advanced

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

Re: Libtool modules and symbol clashes


From: Ralf Wildenhues
Subject: Re: Libtool modules and symbol clashes
Date: Tue, 6 Nov 2007 18:21:40 +0100
User-agent: Mutt/1.5.17 (2007-11-04)

Hello Simon,

* Simon White wrote on Tue, Nov 06, 2007 at 04:03:48PM CET:
> 
> I have some modules with the same exported interface.  All modules are
> built to hide all symbols by default with only the public ones being
> marked as __attribute__((visibility("default"))).  They are designed
> to be drop in replacements, however sometimes more than one of these
> modules may need to be loaded at he same time.
> 
> I've successfully lt_dlopen'ed multiple libraries and used lt_dlsym to
> resolve the names in each.  Calling via the returned pointers works as
> expected.
> 
> However if one of those modules internally calls a function that is
> also marked as being exported it does not necessarily call the
> function in its own library.  Depending on order it may call the
> function that exists in the other library instead.  Note that both
> modules are only manually loaded and neither are loading symbols from
> each other.
> 
> Is this expected behaviour and/or is there a way to stop it?

The libltdl from Libtool HEAD by default dlopen's with RTLD_LOCAL
(actually, it's configurable), unlike 1.5.x which used RTLD_GLOBAL.
So I'm afraid you'll have to use that or patch your 1.5.x.

Cheers,
Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]