[olug] question about compiling libraries...

Phil Brutsche phil at brutsche.us
Wed Jan 1 05:34:20 UTC 2003


A long time ago, in a galaxy far, far way, someone said...

> I'm a little lost here.
>
> I am compiling liblzo (lzo-1.08.tar.gz from
> http://www.oberhumer.com/opensource/lzo/) as a dependency for
> "transcode" which is in turn a dependency of DVD::Rip (Debian users,
> laugh now).
>
> Transcode is looking for liblzo.so, but when I compile I only get the
> following libs installed:
> /usr/local/lib/liblzo.a
> /usr/local/lib/liblzo.la

Try giving the configure script the '--enable-shared' option, like this
sequence:

make distclean
./configure --enable-shared <+ any other options you need to give it>
make
make install

I've done that many times over the last couple years :)

> Also, (while I've got your attention), can someone educate me the
> differences between .a/.la/.so files?

.a files are simple archives - like tar, only made using ar, with a
different format - containing .o (object) files.  These object files are
linked directly into the program you're compiling - or, the objects that
are necessary to take care of any unresolved symbols.  The .la files I see
are usually placeholders for .so files.  .so files are shared objects,
like DLLs under Windows, only with (optional) version information.

> Thanks for reading (and sorry for the newbie bother)...
> Eric Pierce

-- 

Phil Brutsche
phil at brutsche.us



More information about the OLUG mailing list