Login  Register

Re: problems installing quantlib for python 3.4

Posted by Luigi Ballabio on Mar 16, 2016; 3:15pm
URL: http://quantlib.414.s1.nabble.com/problems-installing-quantlib-for-python-3-4-tp17342p17346.html

Hello,
    cl.exe is the Visual Studio compiler, which (I guess) the command prompt can't find because you replaced the PATH entirely instead of adding to it.  Instead of 

set PATH=C:\Anaconda3;C:\Anaconda3\Scripts;C:\Research\quant_lib\swigwin-3.0.8;C:\Research\quant_lib\QuantLib-1.7\lib

you should write

set PATH=C:\Anaconda3;C:\Anaconda3\Scripts;C:\Research\quant_lib\swigwin-3.0.8;C:\Research\quant_lib\QuantLib-1.7\lib;%PATH%

so that the previous value of PATH is appended.

Hope this helps,
    Luigi


On Wed, Mar 9, 2016 at 6:38 PM chitown2015 <[hidden email]> wrote:
I have a python 3.4 installed for anaconda. I have downloaded QuantLib-1.7
and successfully built it using Visual Studio 2010. The resulting file is
C:\Research\quant_lib\QuantLib-1.7\lib\QuantLib-vc100-mt.

However, I cannot seem to install quantlib for python. I've followed the
advice in this webpage:

https://vineetv.wordpress.com/2015/07/07/installing-quantlib-python-windows/

So here's what I've done:

1) I've opened Visual Studio Command Prompt 2010.
2) I've changed directory to Quantlib-SWIG folder:

cd C:\Research\quant_lib\QuantLib-SWIG-1.7\Python

3) I've modified the PATH to include necessary paths:

set
PATH=C:\Anaconda3;C:\Anaconda3\Scripts;C:\Research\quant_lib\swigwin-3.0.8;C:\Research\quant_lib\QuantLib-1.7\lib

4) I've defined QL_DIR:

set QL_DIR=C:\Research\quant_lib\QuantLib-1.7

5) I've included boost:

set INCLUDE=C:\Research\quant_lib\boost_1_60_0

6) I've set LIB:

set LIB=C:\Research\quant_lib\boost_1_60_0\lib32-msvc-10.0

7) I've adjusted the setup file:

echo [build] > setup.cfg
echo compiler=msvc >> setup.cfg

8) I run:

python setup.py wrap

I get the following:

running wrap
Generating Python bindings for QuantLib...
SWIG(1) : Warning 125: Use of the include path to find the input file is
deprecated and will not work with ccache. Please include the path when
specifying the input file.

9) The above warning seemed innocent so I've went ahead and run the
following:

python setup.py build

The result is:

running build
running build_py
copying QuantLib\QuantLib.py -> build\lib.win-amd64-3.4\QuantLib
running build_ext
building 'QuantLib._QuantLib' extension
cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -D__WIN32__ -DWIN32 -DNDEBUG
-D_WINDOWS -DNOMINMAX -IC:\Anaconda3\include -IC:\Anaconda3\include
-IC:\Research\quant_lib\QuantLib-1.7 -IC:\Research\quant_lib\boost_1_60_0
/TpQuantLib/quantlib_wrap.cpp
/Fobuild\temp.win-amd64-3.4\Release\QuantLib/quantlib_w
rap.obj /GR /FD /Zm250 /EHsc /bigobj /MD
error: command 'cl.exe' failed: No such file or directory

I am not sure which cl.exe it is looking for. But cannot get past this
point. Appreciate help.
















--
View this message in context: http://quantlib.10058.n7.nabble.com/problems-installing-quantlib-for-python-3-4-tp17342.html
Sent from the quantlib-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231&iu=/4140
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users