Re: strange problem w/ gnome-core and zlib



On Fri, Sep 11, 1998 at 08:34:10AM -0400, Tim Moore wrote:

...

> > I do have zlib (1.1.3) installed and the example program that comes with
> > zlib compiles just fine. I don't understand what causes those "undefined
> > reference" messages...
> > 
> > By the way, shouldn't configure check for zlib? Currently it doesn't.
> 
> Exactly the problem. Here are my patches. You'll need automake and
> autoconf installed for them to work.

...

I had the same problem. This was caused by /usr/X11R6/lib/libz.a.
If you install XFree-3.3.2 from sources, you will get /usr/X11R6/libz.a.
Since -L/usr/X11R6/lib is added to LDFLAGS, a build attempt will end up
trying to link against zlib in /usr/X11R6/lib instead of using newer version
installed, on my machine, in /usr/lib.

I circumvent this problem simply by setting LDFLAGS=-L/usr/lib before
invoking ./autogen.sh to enforce the linker to look for libraries in
/usr/lib first.

So if you are using Bash, following line should hopefully help you link
against your newer zlib, if you have it installed in /usr/lib. Otherwise
replace /usr/lib with a directory where you have zlib installed.

  # LDFLAGS=-L/usr/lib ./autogen.sh


kj
-- 
Kang-Jin Lee
lee@arco.met.fu-berlin.de



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