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

Linking C++ libraries

On Sep  5, Michael Koch (konqueror@gmx.de) wrote:
 > I maintain several libraries written in C++. Unfortunately the use gcc 
 > for linking. Currently I added added -lstdc++ explicitely to link all 
 > needed libraries which my libraries are depending on. Is ther a 
 > better way to tell libtool to use g++ for linking ?

With older versions of libtool (<1.5) you had to do something like this:

sed -e 's/CC="gcc"/CC="g++"/g' libtool > lt.tmp && mv -f lt.tmp libtool

after the call to configure.  But, libtool 1.5 (released into unstable about a
month ago) does this automatically.  You'll need to rerun the maintainer
scripts (automake, libtoolize, etc.) to pick up the effects.

Neil Roeth

Reply to: