NPM软件包未在Windows 8.1上构建-失败,出现以下错误:,
error MSB4019: The imported project "C:\Microsoft.Cpp.Default.props" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.
我试过以下方法,
- 将环境变量
VCTargetsPath
设置为C:\Program Files (x86)\MSBuild\12.0\
(错误会相应更改,但2012构建工具没有Microsoft.Cpp.Default.props
). - 按照this answer安装VisualStudio 2010环境(先卸载,然后按正确顺序安装)
- 完全删除了VisualStudio 2010,并try 了VisualStudio 2012,它应该可以按照
Node-gyp
wiki的标准工作 - 根据this answer增加了注册表项
- 根据this answer,try 使用Windows 7.1 SDK命令提示符
- 在按照this answer运行npm之前,try 设置
VisualStudioVersion
- 试着按照this answer分通过
--msvs_version=2012
分
以上这些都不起作用.
我已经在这上面花了很长时间了.有没有人有一个明确的有效答案?