Complete.Org: Mailing Lists: Archives: freeciv-dev: November 1998:
Re: [Freeciv-Dev] Linker error?
Home

Re: [Freeciv-Dev] Linker error?

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Reinier Post <rp@xxxxxxxxxx>
Cc: Freeciv developers <freeciv-dev@xxxxxxxxxxx>
Subject: Re: [Freeciv-Dev] Linker error?
From: Mitch Davis <mjd@xxxxxxxxxxxxxxxx>
Date: Wed, 04 Nov 1998 09:16:56 +1100

einier Post wrote:
> 
> % grep strerror /usr/include/string*
> /usr/include/string.h:extern char *strerror(int);
> 
> strerror() is there all right, on this Solaris box at least.

Well, that's the prototype, but which .a/.so does the code appear in?

> BTW I'm having a different problem: when I tell ./configure where to find
> its XPM, it can no longer find the X11 libraries:
> 
> % setenv LD_LIBRARY_PATH /usr/local/lib:/usr/openwin/lib
> % ./configure
> loading cache ./config.cache
> [...]
> checking for X... libraries /usr/openwin/lib, headers /usr/openwin/include
> [...]
> checking for XOpenDisplay in -lX11... no
> configure: error: Need X11
> % setenv LD_LIBRARY_PATH /usr/openwin/lib
> $ ./configure
> [now it won't fail on XOpenDisplay, but it will fail on XPM
>   which is in /usr/local/lib]

The LD_LIBRARY_PATH tells the run-time linker where to find shared
libraries at run time.  This variable is not consulted at link time,
which is when I suspect configure is deciding you don't have
those libraries.

Personally, I do this:

./configure --x-includes="/usr/openwin/include -I/usr/local/include"
--x-libraries="/usr/openwin/lib -L/usr/local/lib"

Note the tricky -I and -L bits.  It's yuck, but it works.

You still need the LD_LIBRARY_PATH, but that's when you want to
run your final exe

Hope this helps.

Regards,

Mitch.




[Prev in Thread] Current Thread [Next in Thread]