Skip to main content.
home | support | download

Back to List Archive

Re: LOL (Lack of libraries)

From: Bill Moseley <moseley(at)not-real.hank.org>
Date: Fri Apr 12 2002 - 20:05:33 GMT
At 10:31 AM 04/12/02 -0700, Colin Kuskie wrote:
>cp src/libswish-e.a /usr/local/lib/libswish-e.a
>
>No .so file.  Or is an .a file equivalent?

I'm not the one to answer, but swish only builds a static library.  Might
make sense if it was a .so if, say, you were using the perl module with
mod_perl -- I suppose that might end up sharing more memory.  Although
loading swish-e in the Apache parent might do the same.  But that's another
topic.



># nm src/libswish-e.a | grep compress2
>         U uncompress2
>         U uncompress2
>         U uncompress2
>         U compress2

Ok, indeed libswish-e is using compress2 (--with-zlib did that)

>>    ~/swish-e > ldd perl/blib/arch/auto/SWISHE/SWISHE.so
>>           libm.so.6 => /lib/libm.so.6 (0x40095000)
>>           libxml2.so.2 => /usr/local/lib/libxml2.so.2 (0x400b2000)
>>           libc.so.6 => /lib/libc.so.6 (0x4014c000)
>>           libz.so.1 => /usr/lib/libz.so.1 (0x40254000)
>>           /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
>
>Shouldn't there be a link to libswishe in there somewhere?

Nope, it's statically linked into SWISHE.so.


>
># ldd blib/arch/auto/SWISHE/SWISHE.so
>        libm.so.6 => /lib/libm.so.6 (0x40090000)
>        libc.so.6 => /lib/libc.so.6 (0x400ad000)
>        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)

There's the problem.  For some reason it's not finding your libz.  I would
have thought that ldconfig would have fixed that.

I never have understood how all that works, and why, for example you
sometimes don't need to specify libraries and sometimes you do.  I guess
the answer is in ldconfig (and google).

-- 
Bill Moseley
mailto:moseley@hank.org
Received on Fri Apr 12 20:07:06 2002