未找到适用于msversion的cmake vs编译器:4(windows7)

时间:2019-07-18 09:37:55

标签: .net cmake

apppium-doctor显示opencv4nodejs cannot be found。因此,我尝试使用opencv4nodejs安装npm -g install opencv4nodejs。但是我遇到了这个错误:

info install opencv version: 3.4.6
info install with opencv contrib: yes
info install custom build flags:
info install
info install executing: git --version
info install git --version: git version 2.22.0.windows.1
info install
info install executing: cmake --version
info install cmake --version: cmake version 3.15.0
info install
info install CMake suite maintained and supported by Kitware (kitware.com/cmake).
info install
info find-msbuild failed to find vs2017 via powershell: unexpected powershell output
info find-msbuild attempting to find msbuild via registry query...
info find-msbuild trying the following msbuild paths:
info find-msbuild version: 4, path: C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe
info find-msbuild version: 3.5, path: C:\Windows\Microsoft.NET\Framework\v3.5\msbuild.exe
info install using msbuild: { version: 4,
info install   path:
info install    'C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\msbuild.exe' }
ERR! Error: no cmake vs compiler found for msversion: 4
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! opencv-build@0.1.4 install: `node ./install.js`
npm ERR! Exit status 1

我从https://cmake.org/download/获得了cmake v3.15。日志是什么意思?如何正确安装opencv4nodejs

2 个答案:

答案 0 :(得分:0)

尝试:npm install -g windows-build-tools之前的npm install opencv4nodejs

答案 1 :(得分:0)

尝试一下:npm install --global Windows-build-tools --vs2015