Dear Quantlib users, I would like to use QuantLib under MS Excel. To this end I have followed the steps described in the "Build Tutorial" of QuantLibAddin (http://quantlib.org/quantlibaddin/build_tutorial.html), i.e. I have: 1) Installed Visual C++ and the SDK 2) Installed Python 2.4.4 3) Installed and Built Boost 4) Installed and Built QuantLib The QuantLib Testsuite ran successfully. However, the tutorial says that " ... In other words the QuantLibAddin compilation will expect to find * QuantLib header files in directory $(QL_DIR)\include * QuantLib lib file QuantLib-vc80-mt-s-0_3_14.lib in directory $(QL_DIR)\lib" But, after both compiling and successfully testing QuantLib the directory $(QL_DIR)\include does not exist. Is that normal? 5) Installed and built log4cxx the build process created the file "log4cxx-0.9.7b\msvc\lib\log4cxxs-vc80-mt-s.lib" as expected. 6) Installed gensrc 7) Installed and built ObjectHandler Compilation was successfully completed. However, while the tutorial says that * "The build process creates file ObjectHandler\ohxl\ohxllib\lib\ObjectHandler-vc80-mt-s-0_1_5.lib." the folder ObjectHandler-0.1.5 contains only "\ohxl\ohxllib\" and not "\lib\". Is that normal? * After compilation the ObjectHandler-0.1.5\lib\ folder contains two files: "ObjectHandler-xllib-vc80-mt-s-0_1_5.lib" and "xlsdk-vc80-mt-s.lib" but the file "ObjectHandler-vc80-mt-s-0_1_5.lib" does not exist. 8) Installed QuantLibAddin-0.3.14.exe and QuantLibXL-src-0.3.14.exe, built QuantLibAddin Compilation of QuantLibAddin failed. I obtained the following errors: 1) couponvectors.cpp .\qlo\couponvectors.cpp(76) : error C2039: 'SimpleCashFlow' : is not a member of 'QuantLib' .\qlo\couponvectors.cpp(76) : error C2065: 'SimpleCashFlow' : undeclared identifier .\qlo\couponvectors.cpp(77) : error C2039: 'SimpleCashFlow' : is not a member of 'QuantLib' .\qlo\couponvectors.cpp(77) : error C2783: 'boost::shared_ptr<T> boost::dynamic_pointer_cast(const boost::shared_ptr<U> &)' : could not deduce template argument for 'T' C:\Boost\include\boost-1_33_1\boost/shared_ptr.hpp(385) : see declaration of 'boost::dynamic_pointer_cast' .\qlo\couponvectors.cpp(77) : error C2512: 'boost::shared_ptr' : no appropriate default constructor available .\qlo\couponvectors.cpp(78) : error C2451: conditional expression of type 'boost::shared_ptr' is illegal No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called 2) shortratemodels.cpp .\Functions\shortratemodels.cpp(71) : error C2039: 'convexityBias' : is not a member of 'QuantLib' .\Functions\shortratemodels.cpp(71) : error C3861: 'convexityBias': identifier not found I'm new in QuantLib and in compiling source code. I followed exactly the tutorial but perhaps I do something wrong or the compiler is not configured/installed correctly. Do you have any idea of what is going wrong and how to correct it? My System composed by Window XP Professional, Version 2002, Service Pack 2 MS Visual Studio 2005 Version 8.0.50727.762 (SP.050727-7600) Microsoft Visual C++ 2005 76542-000-0000011-00125 Microsoft .NET Framework Version 2.0.50727 Many thanks in advance Claudio ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Claudio,
On 1/28/07, Ortelli Claudio <[hidden email]> wrote: > > Dear Quantlib users, > > I would like to use QuantLib under MS Excel. To this end I > have followed the steps described in the "Build Tutorial" of > QuantLibAddin (http://quantlib.org/quantlibaddin/build_tutorial.html), > i.e. I have: > > 1) Installed Visual C++ and the SDK > 2) Installed Python 2.4.4 > 3) Installed and Built Boost > 4) Installed and Built QuantLib > The QuantLib Testsuite ran successfully. > > However, the tutorial says that > " ... In other words the QuantLibAddin compilation will expect to find > * QuantLib header files in directory $(QL_DIR)\include > * QuantLib lib file QuantLib-vc80-mt-s-0_3_14.lib in directory $(QL_DIR)\lib" > > But, after both compiling and successfully testing QuantLib the directory $(QL_DIR)\include does not > exist. Is that normal? That's a mistake in the document. It should say $(QL_DIR)\ql. You need to manually set the environment variable QL_DIR to the top level QuantLib directory. for example, on my machine, QuantLib is installed to C:\projects\QuantLib and I've set the value of environment variable QL_DIR equal to the above string. > 5) Installed and built log4cxx > the build process created the file "log4cxx-0.9.7b\msvc\lib\log4cxxs-vc80-mt-s.lib" as expected. > > 6) Installed gensrc > 7) Installed and built ObjectHandler > Compilation was successfully completed. > However, while the tutorial says that > * "The build process creates file ObjectHandler\ohxl\ohxllib\lib\ObjectHandler-vc80-mt-s-0_1_5.lib." > the folder ObjectHandler-0.1.5 contains only "\ohxl\ohxllib\" and not "\lib\". Is that normal? > > * After compilation the ObjectHandler-0.1.5\lib\ folder contains two files: > "ObjectHandler-xllib-vc80-mt-s-0_1_5.lib" and > "xlsdk-vc80-mt-s.lib" > but the file "ObjectHandler-vc80-mt-s-0_1_5.lib" does not exist. The documentation of the ObjectHandler directories is wrong, and all the files you identify above are correct. We shuffled things around and I forgot to update the document. > 8) Installed QuantLibAddin-0.3.14.exe and QuantLibXL-src-0.3.14.exe, built QuantLibAddin > > Compilation of QuantLibAddin failed. I obtained the following errors: > > 1) > couponvectors.cpp > .\qlo\couponvectors.cpp(76) : error C2039: 'SimpleCashFlow' : is not a member of 'QuantLib' That I don't understand. Near the top of file QuantLibAddin\qlo\couponvectors.cpp it says #include <ql/CashFlows/simplecashflow.hpp> Which, assuming QL_DIR is set correctly, should cause you to pick up file QuantLib\ql\CashFlows\simplecashflow.hpp which of course contains the definition of SimpleCashFlow. The #include of ql/CashFlows/simplecashflow.hpp must have succeeded because otherwise the error message would have been .\qlo\couponvectors.cpp(31) : fatal error C1083: Cannot open include file: 'ql/CashFlows/simplecashflow.hpp': No such file or directory So I can't understand why the #include succeeded, but the compilation failed. Is QL_DIR pointing to an older version of QuantLib or something? Apologies for the errors in the documentation, that will be fixed shortly. Regards, Eric ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Eric,
thank you very much for your quick answer and for the time you invest in this project. >Hi Claudio, >On 1/28/07, Ortelli Claudio <[hidden email]> wrote: >> >> Dear Quantlib users, >> >> I would like to use QuantLib under MS Excel. To this end I >> have followed the steps described in the "Build Tutorial" of >> QuantLibAddin (http://quantlib.org/quantlibaddin/build_tutorial.html), >> i.e. I have: >> >> 1) Installed Visual C++ and the SDK >> 2) Installed Python 2.4.4 >> 3) Installed and Built Boost >> 4) Installed and Built QuantLib >> The QuantLib Testsuite ran successfully. >> >> However, the tutorial says that >> " ... In other words the QuantLibAddin compilation will expect to find >> * QuantLib header files in directory $(QL_DIR)\include >> * QuantLib lib file QuantLib-vc80-mt-s-0_3_14.lib in directory $(QL_DIR)\lib" >> >> But, after both compiling and successfully testing QuantLib the directory $(QL_DIR)\include does not >> exist. Is that normal? >That's a mistake in the document. It should say $(QL_DIR)\ql. >You need to manually set the environment variable QL_DIR to the top >level QuantLib directory. for example, on my machine, QuantLib is >installed to > C:\projects\QuantLib >and I've set the value of environment variable QL_DIR equal to the above string. Regarding the system, I have the following (User) environment variables: (note that I'm "Administrator" of my PC) QL_DIR = C:\Project\QuantLib-0.3.14 GENSRC_DIR = C:\Project\gensrc-0.1.5 LOG4CXX_DIR = C:\Project\log4cxx-0.9.7b OBJECT_HANDLER_DIR = C:\Project\ObjectHandler-0.1.5 PYTHONPATH = C:\Python24 QUANTLIBADDIN_DIR = C:\Project\QuantLibAddin-0.3.14 QUANTLIBXL_DIR = C:\Project\QuantLibXL Regarding the compiler, I have the following configuration: Tools -> Options -> Projects and Solutions -> VC++ Directories: Platform: Win32 Show directories for: Executable files 1) C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Bin 2) $(VCInstallDir)bin 3) $(VCInstallDir)PlatformSDK\bin 4) $(VSInstallDir)Common7\Tools\bin 5) $(VSInstallDir)Common7\tools 6) $(VSInstallDir)Common7\ide 7) $(ProgramFiles)\HTML Help Workshop 8) $(FrameworkSDKDir)bin 9) $(FrameworkDir)$(FrameworkVersion) 10) $(VSInstallDir) 11) $(PATH) Show directories for: Include files 1) $(VCInstallDir)include 2) C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include 3) C:\Boost\include\boost-1_33_1 4) C:\Boost\include\boost-1_33_1\boost 5) $(VCInstallDir)PlatformSDK\include 6) $(FrameworkSDKDir)include Show directories for: Library files 1) C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Lib 2) C:\Boost\lib 3) $(VCInstallDir)lib 4) $(VCInstallDir)PlatformSDK\lib 5) $(FrameworkSDKDir)lib 6) $(VSInstallDir) 7) $(VSInstallDir)lib >> 5) Installed and built log4cxx >> the build process created the file "log4cxx-0.9.7b\msvc\lib\log4cxxs-vc80-mt-s.lib" as expected. >> >> 6) Installed gensrc >> 7) Installed and built ObjectHandler >> Compilation was successfully completed. >> However, while the tutorial says that >> * "The build process creates file ObjectHandler\ohxl\ohxllib\lib\ObjectHandler-vc80-mt-s-0_1_5.lib." >> the folder ObjectHandler-0.1.5 contains only "\ohxl\ohxllib\" and not "\lib\". Is that normal? >> >> * After compilation the ObjectHandler-0.1.5\lib\ folder contains two files: >> "ObjectHandler-xllib-vc80-mt-s-0_1_5.lib" and >> "xlsdk-vc80-mt-s.lib" >> but the file "ObjectHandler-vc80-mt-s-0_1_5.lib" does not exist. >The documentation of the ObjectHandler directories is wrong, and all >the files you identify above are correct. We shuffled things around >and I forgot to update the document. >> 8) Installed QuantLibAddin-0.3.14.exe and QuantLibXL-src-0.3.14.exe, built QuantLibAddin >> >> Compilation of QuantLibAddin failed. I obtained the following errors: >> >> 1) >> couponvectors.cpp >> .\qlo\couponvectors.cpp(76) : error C2039: 'SimpleCashFlow' : is not a member of 'QuantLib' >That I don't understand. Near the top of file > QuantLibAddin\qlo\couponvectors.cpp >it says > #include <ql/CashFlows/simplecashflow.hpp> >Which, assuming QL_DIR is set correctly, should cause you to pick up file > QuantLib\ql\CashFlows\simplecashflow.hpp >which of course contains the definition of SimpleCashFlow. As I reported before my QL_DIR variable is equal to C:\Project\QuantLib-0.3.14 Should I have to remove the version number? >The #include of ql/CashFlows/simplecashflow.hpp must have succeeded >because otherwise the error message would have been >.\qlo\couponvectors.cpp(31) : fatal error C1083: Cannot open include >file: 'ql/CashFlows/simplecashflow.hpp': No such file or directory >So I can't understand why the #include succeeded, but the compilation >failed. Is QL_DIR pointing to an older version of QuantLib or >something? No, this is the first time I install QuantLib and C:\Project\QuantLib-0.3.14 is the only place where I have installed QuantLib. >Apologies for the errors in the documentation, that will be fixed shortly. No problem, I thank you for all the work you are doing. I will try the suggestion I have found in the FAQ, i.e. Build and Execute Prerequisite Examples If you're having trouble getting QuantLibAddin to build, try compiling and executing simpler example projects. For example the following list constitutes a progression in build complexity: ObjectHandler project ExampleCpp ObjectHandler project ExampleXLL (static or dynamic) QuantLibAddin project ClientCppDemo QuantLibAddin project AddinExcel (static or dynamic) Kind regards claudio ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Free forum by Nabble | Edit this page |