PyCrypto Install error: Unable to find vcvarsall.bat

Today, there is a wechat SDK library called wechatpy, in which a dependency library is pycrypt

If you directly PIP install wechatpy, you will encounter error: unable to find vcvarsall.bat

Google, a bunch of solutions, are invalid, should be expired

Then I found two good articles

1. It introduces Microsoft Visual C + + compiler for Python 2.7

http://www.microsoft.com/en-us/download/details.aspx?id=44266

2. It introduces that if the version of setuptools is higher than 6.0, the compiler can be searched automatically

http://stackoverflow.com/questions/26140192/microsoft-visual-c-compiler-for-python-2-7

 

Then, first install 1, then check your own setup tools, version 3.6, and decisively upgrade to 7.0

pipinstall--upgradesetuptools

Then PIP install wechatpy again, everything goes well

Record it

Similar Posts: