安装python模块时,遇到error: Unable to find vcvarsall.bat

参考博文:

http://stackoverflow.com/questions/2817869/error-unable-to-find-vcvarsall-bat


解决办法的前提是,系统中必须安装了vs的相关版本。

For Windows installations:

While running setup.py for package installations, Python 2.7 searches for an installed Visual Studio 2008. You can trick Python to use a newer Visual Studio by setting the correct path in VS90COMNTOOLS environment variable before calling setup.py.

If you have Visual Studio 2010 installed, execute

SET VS90COMNTOOLS=%VS100COMNTOOLS%

or with Visual Studio 2012 installed (Visual Studio Version 11)

SET VS90COMNTOOLS=%VS110COMNTOOLS%

or with Visual Studio 2013 installed (Visual Studio Version 12)

SET VS90COMNTOOLS=%VS120COMNTOOLS%

   


你可能感兴趣的:(安装python模块时,遇到error: Unable to find vcvarsall.bat)