我试图安装Python包dulwich:
pip install dulwich
Run Code Online (Sandbox Code Playgroud)
但我得到一个神秘的错误信息:
error: Unable to find vcvarsall.bat
Run Code Online (Sandbox Code Playgroud)
如果我尝试手动安装包,也会发生同样的情况:
> python setup.py install
running build_ext
building 'dulwich._objects' extension
error: Unable to find vcvarsall.bat
Run Code Online (Sandbox Code Playgroud) 我有Visual Studio 2010 SP1和Windows sdk 7.1.我还有VS2012和Windows套件8.
当我运行Windows SDK 7.1 Command Prompt并运行node-gyp build --msvs_version=2010它给我错误:
error MSB3411: Could not load the Visual C++ component "VCBuild.exe".
If the component is not installed,
either 1) install the Microsoft Windows SDK for Windows Server 2008 and .NET Fr
amework 3.5, or 2) install Microsoft Visual Studio 2008.
Run Code Online (Sandbox Code Playgroud)
它是否正在尝试查找VCBuild.exe.
这是一个有效的错误吗?
我还发现在Windows 7中,对于.NET 3.5,您只需要从控制面板打开它.关于stackoverflow的其他问题,请看这里和这个.
但问题是,由于vcbuild.exe在vs2010系统中不存在,那么为什么node-gyp正在搜索它?或者我错过了什么?
我该如何解决这个错误?