Undefined symbol linking using Forte 6.2 CC on Solaris 8

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Undefined symbol linking using Forte 6.2 CC on Solaris 8

Goldblatt, Daniel [CAI]
Hi,

Getting "Undefined symbol" when trying to link a simple executable. Any help would be appreciated.

I am compiling using Forte 6.2 CC on a Solaris 8 unix machine.

Here is main.c:

/////////////////////////////////////////////////////////////////////////////////
#include <ql/quantlib.hpp>

int main( int argc, char** argv )
{
QuantLib::DepositRateHelper rh( 5.04 / 100.0, 6, QuantLib::Months, 2,
                                QuantLib::Calendar( ), QuantLib::ModifiedFollowing, QuantLib::Actual360() );
}
/////////////////////////////////////////////////////////////////////////////////

It compiles fine, but when I link, I get the error:

Undefined                       first referenced
 symbol                             in file
boost::shared_ptr<QuantLib::Observable>::shared_ptr<QuantLib::Observable>#Nvariant 1(__type_1*) /home/src/quantlib/ql/SPARC_5.8_D/libquantlib.a(XVV6j7r3rNMoF5PSVDUH.o)
ld: fatal: Symbol referencing errors. No output written to SPARC_5.8_D/main

Here is the command line of my link command:

/Forte/sun4/6.2/5.8p2/WS6U2/bin/CC  -g SPARC_5.8_D/main.o -Bstatic -Bstatic -L/home/src/quantlib/ql/SPARC_5.8_D -lquantlib  -L/usr/lib/sparcv9 -Bstatic -lC -lCstd -Bdynamic -lnsl -ldl -lm -lsocket -library=no%rwtools7 -o SPARC_5.8_D/main

Thanks,
Daniel