安装pycrypto坑太多,分享博文参考:https://blog.csdn.net/weixin_42345642/article/details/95305159
https://jingyan.baidu.com/article/95c9d20d7784ebec4f75616e.html
我是报的error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.26.28801\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
解决办法是:
参照博文设置用户环境变量:注意变量值根据实际路径来
2. win+R运行cmd,执行命令set CL=/FI”%VCINSTALLDIR%\Tools\MSVC\14.26.28801\include\stdint.h” %CL%
这里stdint.h也要根据实际路径来
3.命令行窗口重新执行pip install pycrypto -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
安装成功