|
From: Andreas S. <an...@sp...> - 2009-02-18 19:44:40
|
Hi Luigi, Luigi Ballabio schrieb: > Looking at your command line: > >> libtool: compile: CC -DHAVE_CONFIG_H -I. -I. -I../../ql -I../.. -I../.. >> -I/home/spenglan/local/include/boost-1_38 >> -erroff=wvarhidemem,hidevf,hidevfinvb,wbadinitl,badargtypel2w -errtags=yes >> -KPIC -features=rtti -template=wholeclass -instances=global -g -xs -fast >> -library=rwtools7,iostream,no%stlport4,Crun -xarch=v8plusa -fsimple=1 -mt >> -Drindex=rindex -Dindex=index -D__solaris_sparc__ -O3 -c >> exchangeratemanager.cpp -KPIC -DPIC -o .libs/exchangeratemanager.o > > a likely candidate would be -template=wholeclass. I don't have a Solaris > box available to check it, but if it tells the compiler to instantiate > all methods in a template class instead of just the ones that are used, > then it would cause the error above. May you have a look at your > compiler documentation and check whether the above works as I guessed > (and if so, how can you specify the correct behavior instead?) I should have guessed it. Unfortunately I somehow thought, that memberwise comparison is added implicitly (like the copy constructor and assignment operator are)... I looked up this in the Sun compiler C++ user reference - and will try it out tomorrow: "When the compiler implicitly instantiates a template class, it instantiates the static data members, the constructor, and the destructor. However, the compiler does not implicitly instantiate any other member function unless the function is explicitly referenced. To force the compiler to instantiate all member functions when implicitly instantiating a class, use the -template=wholeclass compiler option. To turn this option off, specify -template=no%wholeclass, which is the default." Rgds, Andreas |