autoconf
[Top][All Lists]
Advanced

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

Re: C++ program incorrectly linked as C?


From: Ralf Wildenhues
Subject: Re: C++ program incorrectly linked as C?
Date: Fri, 21 May 2010 07:39:32 +0200
User-agent: Mutt/1.5.20 (2009-10-28)

Hello Natalie,

* Natalie Tasman wrote on Fri, May 21, 2010 at 02:26:02AM CEST:
> > I've set LT_INIT and LT_LANG([C++]); .cxx files are compiled correctly
> > with g++ but linking is happening with gcc and failing (missing all
> > the basic c++ stuff).   I don't know if this is relevant but in
> > Makefile.in the default "LINK" definition uses CC rather than CXX.

> Apologies- this seems to be due to an issue with cross-compiling, not
> with autoconf.

I'm not sure how cross compilation can be the reason, and I'm not sure
whether you're saying you've fixed the issue now; but if you haven't,
then showing the Makefile.am parts relevant for the C++ program as well
as (relevant parts of) a build log would probably help to analyze the
issue.

Automake uses LINK only for linking of C-only code; when it realizes
that C++ is in the game, it will use CXXLINK.  You may need to add
AC_PROG_CXX to configure.ac and run autoreconf for it to set and use
this variable.

(Without knowing what the issue is, it could be due to any of the
autotools; there's really no need to jump to another mailing list
for that, though, IMVHO.)

Hope that helps.

Cheers,
Ralf



reply via email to

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