Following instructions from: Build QuantLib for Python(SWIG)
python setup.py build --compiler=msvc
I wonder why vcvarsall.bat
cannot be found. Actually, this batch
file is found at:
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC
Furthermore, I've copied it to:
C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools
and have finally added the latter path to the System variables -> PATH
, without any improvement.
Ps: A similar topic has been raised on error-microsoft-visual-c-10-0-is-required-unable-to-find-vcvarsall-bat(DUPLICATE), but none of the solutions advocated have so far helped me in overcoming this matter.
Any relevant feedback would therefore be appreciated.
OS: Windows 10
Studio: Express 2013 for Windows Desktop
Boost: v.1_58_0
SWIG: v.1_6
QuantLib: v.1_6
IDE: PTVS v.2.2.2
Thanks in advance
1 - EDIT: See below the screenshot (incl. error)
Alternatively:
=======================================================================
C:\local\QuantLib_SWIG_1_6\Python>python setup.py build --compiler=msvc
running build
running build_py
running build_ext
building 'QuantLib._QuantLib' extension
error: Unable to find vcvarsall.bat
========================================================================
2 - EDIT:
I've even gone further by updating the get_build_version()
method from the module: msvc9compiler.py
held in
C:\Users\user\Miniconda3\Lib\distutils
To:
#if majorVersion >= 13: updated
if majorVersion > 13:
# v13 was skipped and should be v14
majorVersion += 1
elif majorVersion == 13: #v13 no more skipped, UPDATED on 11/13/2016
majorVersion -= 1 # pointing specifically to v.12
since my Python 3.5.2
was compiled under MSC 1900 <=> VS 2015
. However it's look like the compiler cannot be found as console (cmd
) still returns
error:Unable to find vcvarsall.bat
Ps: Totally amazed with this installation. Solution of last resort: Install VS2015 Community
that I was postponing
3 - EDIT:
set MSSdk=1
set DISTUTILS_USE_SDK=1
python setup.py build
Error:
The program can't start because mspdb120.dll is missing from your computer.
Try reinstalling the program to fix this problem
error: command 'C:\Program Files (x86)\Microsoft Visual Studio
12.0\VC\bin\x86_amd64\cl.exe Failed with exit status - 10737441515
Solution:
Copy mspdb120.dll
To C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64
python setup.py build
quantlib_wrap.cpp
QuantLib/quantlib_wrap.cpp: fatal error C1902: Program database manager
mismatch; please check your installation
error: command 'C:\Program Files (x86)\Microsoft Visual Studio
12.0\VC\bin\x86_amd64\cl.exe Failed with exit status 2