[Rquantlib-devel] How to build RQuantLib on Windows

Dirk Eddelbuettel edd at debian.org
Tue Feb 25 19:59:23 CET 2014


Hi George,

On 25 February 2014 at 13:37, George Wang wrote:
| I don't really need 64bit binary, but all my PCs have 64bit Win7. I have tried
| following the following instructions trying to compile RQuantLib on windows,
| but always failed.
| http://blog.fosstrading.com/2010/12/build-rquantlib-on-32-bit-windows.html
| 
| I wonder if you have any web page or document with step by step instruction to
| set up the environment to build RQuantLib on Windows. I need to make some
| change to fixed rate bond to make price<->yield calculation match Bloomberg's
| result. Any help would be highly appreciated.
| 
| Thanks,
| George
| 
| P.S. Following is the details of the error.
| 
| $ C:/R/R-3.0.2/bin/i386/R CMD INSTALL RQuantLib
| * installing to library 'c:/R/R-3.0.2/library'
| * installing *source* package 'RQuantLib' ...
| files 'DESCRIPTION', 'src/Makevars.win', 'src/utils.cpp' have the wrong MD5
| checksums
| 
|    **********************************************
|    WARNING: this package has a configure script
|          It probably needs manual configuration
|    **********************************************
| 
| 
| ** libs
| 
| *** arch - i386
| g++ -m32 -I"c:/R/R-3.0.2/include" -DNDEBUG    -I"c:/R/R-3.0.2/library/Rcpp/
| include" -I"d:/RCompile/CRANpkg/extralibs64/local/include"  -I -I../inst/
| include -I. -I""   -O2 -Wall  -mtune=core2 -c asian.cpp -o asian.o
| asian.cpp:26:23: fatal error: rquantlib.h: No such file or directory
                   ^^^^^^^^^^^^^^^^^^^^^^^^

Look at src/Makevars.win.  It expects a QuantLib installation (or rather, the
headers and library) pointed to by a variable. If you don't have that, things
will fail.

I presume you have built QuantLib on Windows?

Dirk



| compilation terminated.
| make: *** [asian.o] Error 1
| Warning: running command 'make -f "Makevars.win" -f "c:/R/R-3.0.2/etc/i386/
| Makeconf" -f "c:/R/R-3.0.2/share/make/winshli
| b.mk" SHLIB_LDFLAGS='$(SHLIB_CXXLDFLAGS)' SHLIB_LD='$(SHLIB_CXXLD)' SHLIB=
| "RQuantLib.dll" OBJECTS="asian.o barrier_binary.o bermudan.o bonds.o
| calendars.o curves.o daycounter.o discount.o hullwhite.o implieds.o modules.o
| utils.o vanilla.o zero.o"' had status 2
| ERROR: compilation failed for package 'RQuantLib'
| * removing 'c:/R/R-3.0.2/library/RQuantLib'
| * restoring previous 'c:/R/R-3.0.2/library/RQuantLib'
| 
| ----------------------------------------------------------------------
| _______________________________________________
| Rquantlib-devel mailing list
| Rquantlib-devel at lists.r-forge.r-project.org
| https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rquantlib-devel
-- 
Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com


More information about the Rquantlib-devel mailing list