libtool
[Top][All Lists]
Advanced

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

Re: libtool C++ link bug with -lm functions with Sun Workshop compiler


From: Bob Friesenhahn
Subject: Re: libtool C++ link bug with -lm functions with Sun Workshop compiler
Date: Thu, 20 Mar 2008 09:48:57 -0500 (CDT)

On Thu, 20 Mar 2008, Tim Mooney wrote:

Perhaps it is not best to run most of your configure script using the C++ compiler. Only run the C++ compiler to test C++ things.

I don't disagree, but at the same time, if everything a project is going
to build is going to be compiled by the C++ compiler, doesn't it make
sense for the C++ compiler to actually do the tests?  If it's the C++

Good point. However, it may be that some autoconf tests intended for C don't work properly when used with the C++ compiler.

compiler that needs to see the prototype for sqrt(), and it's the C++
compiler that's going to initiate the link, it doesn't make a lot of
sense for the tests to be conducted by the C compiler.  That's hardly a
good test; there are several reasons why what the C compiler can see for
prototypes or test link might differ from what the C++ compiler would.

There are projects out there, beyond GNU aspell, that are using the C++
compiler for many of the configure tests.  Are they all wrong to do so?

I don't recall if you mentioned the libtool version you are using. Libtool 2.2 usually uses the C++ compiler to link C++ programs and libraries. I just re-verified that it does do so for Solaris 10 with the Studio 12 compiler. Upgrading to 2.2, or the first subsequent release (scheduled for April 1st) may be the solution you are looking for.

Bob
======================================
Bob Friesenhahn
address@hidden, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/





reply via email to

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