Do GModules require *.la files?

Warren Togami wtogami at redhat.com
Tue Oct 25 06:37:37 UTC 2005


Toshio Kuratomi wrote:
> Well, now that I've taken two controversial stances in the past week, I
> guess it's time to put an end to my foolishness with a "third time's the
> charm" question.  Here's a quote from the HACKING file for the new
> libqof:
> 
> 2.1 libqof-backend-qsf.la is REQUIRED in libqof1
> 
> Unlike many other packages, libqof1 REQUIRES the inclusion of the .la
> file for the QSF backend module into the main binary package - it is NOT
> acceptable to put it in the -dev or -devel package! This is for
> portability and to make it easier to use GModule to load the backend.
> This method will be used for all subsequent QOF backend modules and .la
> files for those backends will also need to be installed by the libqof1
> package without requiring a dependency on the development package.
> 
> Can someone more conversant with GModule and/or libtool comment on this?
> The little I know about libtool's *.la files doesn't support this but my
> utter lack of experience with GModules means I need some more
> information before I know what to do.
> 
> -Toshio
> 

<alex> warren: gmodule does not require .la files.
<alex> warren: at least in general
<alex> warren: maybe he does something bizzare with it
<alex> warren: maybe he uses it to get the correct shobject filename 
extension
<alex> warren: but thats not needed, gmodule adds the system one 
automatically if you don't specify one
<alex> warren: You should ask him exactly why it is needed
<warren> alex, he doesn't know, he was quoting from a readme from libqof
<mclasen> warren: should be very easy to test if libqof succeeds in 
loading its modules when you rm the .la files
<alex> warren:
<alex>  /* All available QOF backends need to be described here
<alex> and the last entry must be three NULL's.
<alex> Remember: Use the libdir from the current build environment
<alex> and use the .la NOT the .so - .so is not portable! */
<alex> struct backend_providers backend_list[] = {
<alex>         { QOF_LIB_DIR, "libqof-backend-qsf.la", 
"qsf_provider_init" },
<alex> warren: He should just pass "libqof-backend-qsf" instead
<alex> warren: g_module adds the right extension anyway

Short on time and exhausted so I didn't grok and paraphrase this.  I 
hope this is useful.

Warren Togami
wtogami at redhat.com




More information about the fedora-extras-list mailing list