Re: Making a private lib for linking

On 28/07/2003 11:34 AM, Curtis C. Hovey wrote:

On Sun, 2003-07-27 at 23:09, James Henstridge wrote:
On 28/07/2003 11:03 AM, Curtis C. Hovey wrote:

I recently upgraded my autotools while using jhbuild, but I discovered
Medusa wasn't making its .a private libs after that even though its
Makefile contains 'LDFLAGS = -static'.  I removed AM_DISABLE_STATIC and
all is better.  Is this the right thing to do when I'm making a private
lib to link into my main lib?  Is there a better way?

Does your jhbuildrc file tell jhbuild to pass the "--disable-static" option to autogen scripts?

No it does not.  Medusa was definitely knackered after the autotool
change, not by jhbuild.  I added a Medusa dependency to jhbuild to see
if it could build Medusa using the new tools, and the answer was no.

I was seeing this message that implied the medusa-idled .a was wacked:
../libmedusa-internal/.libs/ undefined reference to

I updated following the example of a few other libs built
by jhbuild and Medusa is building right, manually and by jhbuild.

But the question remains, was Medusa building right because I was using
a old set of autotools to compile old code?  Is my fix correct?  The
libtools 1.5 docs suggest using AC_DISABLE_STATIC, and AC_PROG_LIBTOOL,
instead of AM_.  Should I update to use the AC_ versions of the macros
since I want something that builds well with GNOME 2.4?
It is probably a bug in your makefiles and/or configure script. Other packages such as Pango build fine with the newer libtool.

The AM_DISABLE_STATIC macro does exactly the same thing as AC_DISABLE_STATIC (in fact it just calls the AC_ version). These macros just make --disable-static the default (rather than --enable-static). So this is not very likely to be the problem.

One other thing to try is building from a clean source tree -- libtool-1.5 handles .lo files in a different way to 1.4.x, so if you have any .lo files left over from a previous build, they could be causing problems.

If that doesn't help, see if automake printed any errors/warnings when generating the makefiles when was run. Note that newer versions of automake do a better job at picking up errors in's compared to 1.4.


Email: james daa com au

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