libtool in configure for dejagnu confused was: Catch 5.0.x

Robert Lipe robertl@dgii.com
Mon Dec 22 22:47:00 GMT 1997


Jean-Pierre Radley wrote:
> A bit of a chicken and egg problem arose as I tried to recompile 
> the dejagnu and egcs releases of 12/22 on SCO OpenServer 5.0.4.
> 
> Configure, in both programs, finds gcc or cc, but it then insists on
> inserting -belf in the CFLAGS and occasionally in the LDFLAGS.

I've now found what's happening here.   Someone is going to have to 
help figure out why.   This is my first exposure to libtool, so my
understanding could be wrong.

There are two conditions called out in ltconfig.  gcc and everything 
else.  When walking through ltconfig by hand, it seems to do the right
thing for the gcc case and guess appropriate -shared and PIC flags.

The problem is that once the big autoconf machine drives it, it appears
to get the wrong flags.   For example, once configured, it finds gcc
yet it insists on writing out lines like this in expect/Makefile:

$(CC) $(XCFLAGS) -belf -Wl,-Bexport -o expect_ins

So, the mystery to solve is why libtool (autoconf?  configure?) knows
that CC=gcc, yet it's picking up these clearly native flags for the
OpenServer target.


RJL



More information about the Gcc mailing list