This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: is --with-libexpat-prefix broken?
- From: Daniel Jacobowitz <drow at false dot org>
- To: Joel Brobecker <brobecker at adacore dot com>
- Cc: gdb at sourceware dot org
- Date: Thu, 28 Feb 2008 12:12:44 -0500
- Subject: Re: is --with-libexpat-prefix broken?
- References: <20080227234911.GC19729@adacore.com>
On Wed, Feb 27, 2008 at 03:49:11PM -0800, Joel Brobecker wrote:
> With the latest sources, I don't see the -I switch anymore, and
> I don't see the path to the archive either. All I see is that configure
> tries to build using -lexpat without specifying where the includes
> or the library might be found:
>
> > configure:7028: checking for libexpat
> > configure:7052: gcc -o conftest -g conftest.c -lncurses -lsocket -lnsl -lm -lexpat >&5
> > ld: fatal: library -lexpat: not found
> > ld: fatal: File processing errors. No output written to conftest
> > collect2: ld returned 1 exit status
>
> I'm looking into it, but it's really puzzling. It looks like this
> part is taken care of by config/lib-link.m4:AC_LIB_HAVE_LINKFLAGS.
> And yet, I don't see a change since 6.7.1 that could likely be
> responsible for this change of behavior.
This is a horribly overcomplicated macro, originally from (IIRC)
gettext. I used it because it was there and worked, but when it goes
wrong I'm at a loss. I recommend running the configure script with
sh -x to see what it's doing.
The only thing I noticed in the above was that there was no -I option,
but the test file obviously compiled. Could you have switched
compilers and/or added an expat installation in /usr/local/include
and /usr/local/lib? GCC is ornery about searching /usr/local/include
but not /usr/local/lib in some configurations.
--
Daniel Jacobowitz
CodeSourcery