Posted by
Dirk Eddelbuettel on
URL: http://quantlib.414.s1.nabble.com/problems-building-on-linux-tp1099p1103.html
On 30 June 2007 at 13:03, Tito Ingargiola wrote:
| I'm having difficulty building quantlib-0.8.1 on a redhat system.
| I've built and installed boost-1.34 which the quantlib build seems to
| find without difficulties during compilation. But when it tries to
| link, it seems to be using the wrong names for the libraries.
| Specifically, the build looks for '-lboost_unit_test_framework'
| whereas the libraries are actually named things like
| 'libboost_unit_test_framework-gcc34-*' Looking at the boost install
| docs, this seems to be correct -
|
http://boost.org/more/getting_started/unix_variants.html#library_namingSeems to work for me on Debian just using the configure defaults. E.g. to
pick one of the binaries linked against the Boost libraries:
edd@basebud:~> ldd /usr/bin/quantlib-test-suite
linux-gate.so.1 => (0xffffe000)
libboost_unit_test_framework-gcc41-mt-1_34.so.1.34.0 => /usr/lib/libboost_unit_test_framework-gcc41-mt-1_34.so.1.34.0 (0xb7f82000)
libQuantLib-0.8.1.so => /usr/lib/libQuantLib-0.8.1.so (0xb78de000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0xb77f3000)
libm.so.6 => /lib/i686/cmov/libm.so.6 (0xb77cc000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xb77c1000)
libc.so.6 => /lib/i686/cmov/libc.so.6 (0xb767e000)
librt.so.1 => /lib/i686/cmov/librt.so.1 (0xb7674000)
libpthread.so.0 => /lib/i686/cmov/libpthread.so.0 (0xb765d000)
/lib/ld-linux.so.2 (0xb7fde000)
The library does indeed have one of those absurdly boost names, but QL
figured all this out by itself. From the log created when the package was
built, I see that the linking was done via
g++ -g0 -O2 -D_REENTRANT -fpermissive -o .libs/quantlib-benchmark quantlibbenchmark.o americanoption.o asianoptions.o barrieroption.o basketoption.o batesmodel.o digitaloption.o dividendoption.o europeanoption.o hestonmodel.o jumpdiffusion.o libormarketmodel.o libormarketmodelprocess.o lowdiscrepancysequences.o quantooption.o riskstats.o shortratemodels.o old_pricers.o utilities.o -lboost_unit_test_framework-mt ./.libs/libUnitMain.a ../ql/.libs/libQuantLib.so
i.e. the library is being made available via -lboost_unit_test_framework-mt
You may need to see if you can build some standalone boost tests. Try to
avoid the bjam stuff which is just too confusing :)
Hth, Dirk
--
Hell, there are no rules here - we're trying to accomplish something.
-- Thomas A. Edison
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users