felixrieseberg / windows-build-tools

:package: Install C++ Build Tools for Windows using npm
MIT License
3.4k stars 237 forks source link

Window10 +node v12.16.2+npm v6.14.4 fail to install #247

Open minhuan520 opened 3 years ago

minhuan520 commented 3 years ago

log: info lifecycle windows-build-tools@5.2.2~postinstall: windows-build-tools@5.2.2 4204 verbose lifecycle windows-build-tools@5.2.2~postinstall: unsafe-perm in lifecycle true 4205 verbose lifecycle windows-build-tools@5.2.2~postinstall: PATH: D:\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;D:\nodejs\npm_global\node_modules\windows-build-tools\node_modules.bin;D:\nodejs\npm_global\node_modules.bin;D:\Xshell6\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;D:\nodejs\;C:\ProgramData\chocolatey\bin;D:\nodejs\npm_global;D:\ADB;C:\Program Files\dotnet\;D:\Git\cmd;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;D:\openCV\opencv\build\x64\vc14\bin;D:\python\Scripts\;D:\python\;C:\Users\MH\AppData\Local\Microsoft\WindowsApps;C:\Users\MH\AppData\Roaming\npm;D:\Fiddler;C:\Users\MH.dotnet\tools;D:\WebStorm 2019.3.3\bin;;D:\Microsoft VS Code\bin;C:\Users\MH\AppData\Local\Microsoft\WindowsApps; 4206 verbose lifecycle windows-build-tools@5.2.2~postinstall: CWD: D:\nodejs\npm_global\node_modules\windows-build-tools 4207 silly lifecycle windows-build-tools@5.2.2~postinstall: Args: [ '/d /s /c', 'node ./dist/index.js' ] 4208 silly lifecycle windows-build-tools@5.2.2~postinstall: Returned: code: 1 signal: null 4209 info lifecycle windows-build-tools@5.2.2~postinstall: Failed to exec postinstall script 4210 timing action:postinstall Completed in 3059ms 4211 verbose unlock done using D:\nodejs\npm_cache_locks\staging-d1805f799b47b19e.lock for D:\nodejs\npm_global\node_modules.staging 4212 timing stage:rollbackFailedOptional Completed in 297ms 4213 timing stage:runTopLevelLifecycles Completed in 7100ms 4214 verbose stack Error: windows-build-tools@5.2.2 postinstall: node ./dist/index.js 4214 verbose stack Exit status 1 4214 verbose stack at EventEmitter. (D:\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:332:16) 4214 verbose stack at EventEmitter.emit (events.js:310:20) 4214 verbose stack at ChildProcess. (D:\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14) 4214 verbose stack at ChildProcess.emit (events.js:310:20) 4214 verbose stack at maybeClose (internal/child_process.js:1021:16) 4214 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5) 4215 verbose pkgid windows-build-tools@5.2.2 4216 verbose cwd C:\Users\MH 4217 verbose Windows_NT 10.0.19042 4218 verbose argv "D:\nodejs\node.exe" "D:\nodejs\node_modules\npm\bin\npm-cli.js" "install" "--global" "--production" "windows-build-tools" 4219 verbose node v12.16.2 4220 verbose npm v6.14.4 4221 error code ELIFECYCLE 4222 error errno 1 4223 error windows-build-tools@5.2.2 postinstall: node ./dist/index.js 4223 error Exit status 1 4224 error Failed at the windows-build-tools@5.2.2 postinstall script. 4224 error This is probably not a problem with npm. There is likely additional logging output above. 4225 verbose exit [ 1, true ]