Re: g_module extension



>>>>> "mb" == Martin Baulig <martin@home-of-linux.org>
>>>>> wrote the following on Thu, 22 Oct 1998 13:31:33 +0200 (CEST)

mb> On Thu, 22 Oct 1998, Michael Lausch wrote:
>> Some days ago i sent this message to Tim Janik, and he told me to
>> resend it to the gtk list, because it might be of potential interest
>> to this list.
>> 
>> I have the problem that i want to load a shared library which depends
>> on other shared libraries. There's no portable way of storing this
>> dependency in the *.so file. Therefore libtool uses the *.la files for
>> linking and extracts the additional libraries from this file. This
>> method doesn't work with the current g_module implementation which
>> "only" does a dlopen(). Maybe the g_module module should also use the 
>> information from the *.la files to load additional libraries.

mb> I have done something similar with my gmodule plugins for gEdit - it's
mb> in ~/gnomecvs/gedit/src/gE_plugin.c.

mb> Basic idea is not to use the *.so or *.la files but to have a
mb> description file for each module:

mb> [Plugin]
mb> name=GDB Source Editor
mb> library_name=libsource_edit.so
mb> deplib_0=/home/baulig/INSTALL/lib/libgdb_corba.so

I think a general method with makefile support should be used. Perhaps 
a g_module_query_dependcies function and some automake rules. The
problem is where should this be. In the g_module module there's no
support for config files and therefore this isn't such a good idea to
put it into glib. I don't know if gtk will use non-trivial plugins in
the future, but if it will, gtk should be the place where it's
implemented. Otherwise libgnome should provide it and goad will use
it because module loading might also be used without CORBA. 

mb> But you mentioned shared library CORBA servers for the GNOME project -
mb> well I think we can use the *.goad description files and add support
mb> for shared library dependencies into them, this can even be done with
mb> some autoconf/make tricks ...

mb> Then we can make the libgnorba keep track of the dependencies and we
mb> don't need to worry about them any longer ...

I've already done this in my private gnorba version, so that i can do
some tests. It still uses the *.la file for lookup, but this not good
(libgnorba has no idea about the ld.so.conf file and usually won't
find the *.la file). So we would need a simple script to convert the
*.la file content into some gnorba config file entries.

mb> Martin
--
Michael Lausch/g.a.m.s. edv dienstleistungen gmbh
See my web page <http://www.lausch.at/> or query PGP key server for PGP key.
"Reality is that which, when you stop believing in it, doesn't go away".
                -- Philip K. Dick





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