[Top][All Lists]

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

g++ is not used by libtool

From: Christoph Bartoschek
Subject: g++ is not used by libtool
Date: Tue, 7 Jun 2005 20:57:26 +0200
User-agent: KMail/1.8.1


I'm trying to compile fam-2.6.10 from

The problem is that fam is a C++ library and libtool is not capable of C++.  

In the linking step the following command is issued:

/bin/sh ../libtool --mode=link g++  -g -O2   -o 
-rpath /usr/local/lib -export-symbols fam.sym Client.lo fam.lo -lstdc++

libtool translates this to several commands and this one:

gcc -shared  Client.lo fam.lo  /usr/lib/  -Wl,-soname 
-Wl, -Wl,-retain-symbols-file -Wl,fam.sym 
-o .libs/

Why is not g++ called?  Why is /usr/lib/ added to the command 
line?   The correct command line would be:

g++ -shared  Client.lo fam.lo -Wl,-soname -Wl, 
-Wl,-retain-symbols-file -Wl,fam.sym -o .libs/

How can I achieve that  g++ is called and not gcc?  And how to get rid 
of  /usr/lib/ correctly?  I've found the line

libfam_la_LIBADD = -lstdc++ 

in  I guess the fam developers added this line, because libtool 
was not able to use g++ and they could not figure out how to change this 
situation.  When I remove this line. libtool is not called with  -lstdc++ 
which is also correct, but  libtool itself still calls gcc.

How to resolve this situation?

Christoph Bartoschek

reply via email to

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