libtool-patches
[Top][All Lists]
Advanced

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

Re: discard “Configured with” line from gcc -v output


From: Ralf Wildenhues
Subject: Re: discard “Configured with” line from gcc -v output
Date: Tue, 8 Sep 2009 21:06:16 +0200
User-agent: Mutt/1.5.20 (2009-08-09)

Hello Alexandre,

thanks for the report.

* Alexandre Oliva wrote on Tue, Sep 08, 2009 at 05:17:28PM CEST:
> Since the latest libtool update in GCC, I've had problems building
> libstdc++-v3 on x86_64-linux-gnu.  The symptom was an incomplete link
> command line, resulting from a trailing «'» character in a -L flag added
> by libtool.

FWIW, it is not clear to me why this shouldn't have hurt you earlier.

> It turned out to be improperly auto-detected from the gcc -shared -v
> output.  The issue is that, after zero or perhaps more reconfigurations
> of the gcc top-level, the arguments passed to the gcc configure, and
> that are reported by gcc -v in the build tree, look like this:
[...]
> The attentive reader will notice the -L flag at the end of
> CXX_FOR_TARGET.  libtool.m4 is not clever enough to realize that the
> trailing «'» is just closing the one before CXX_FOR_TARGET, and to
> disregard the whole thing, so it takes the argument at face value, with
> a trailing apostrophe and all.  That doesn't quite work.

Yep.

> The fix I came up with was to avoid lines that didn't contain the
> information libtool was interested in.  It turns out that only lines
> started with blanks contain the actual commands line that GCC runs, so I
> narrowed the grep for -L flags to such lines.
> 
> Here's what I'm going to installing in the GCC tree momentarily.  I
> suggest libtool to adopt something along the same lines.

The patch is not ok for upstream Libtool, which unfortunately also has
to support other compilers that pretend to be GCC, but produce different
'-v -shared' output (ICC and PathScale are in this boat IIRC).  ICC
won't match your changed grep, I think.  Yes, it's ugly and they should
be punished for being an imperfect impersonation, but that's not
something you can tell users.

Have you checked older GCC versions for the format?

One possibility would be to grep out "Configured with" lines.  I'll look
into it.

Thanks,
Ralf




reply via email to

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