node-gyp: npm install fails due to node-gyp errors
- Node Version: v14.1.0
- Platform: Microsoft Windows 10 Home, 10.0.18363 Build 10.0.18363
- Compiler: MSBuild 15.0, using VS 2019 and Python 3
- Module: Any module, in this case robotjs
Verbose output (from npm or node-gyp):
npm --verbose npm info it worked if it ends with ok npm verb cli [ npm verb cli ‘C:\nodejs\node.exe’, npm verb cli ‘C:\nodejs\node_modules\npm\bin\npm-cli.js’, npm verb cli ‘–verbose’ npm verb cli ] npm info using npm@6.14.4 npm info using node@v14.1.0
Usage: npm <command>
where <command> is one of: access, adduser, audit, bin, bugs, c, cache, ci, cit, clean-install, clean-install-test, completion, config, create, ddp, dedupe, deprecate, dist-tag, docs, doctor, edit, explore, fund, get, help, help-search, hook, i, init, install, install-ci-test, install-test, it, link, list, ln, login, logout, ls, org, outdated, owner, pack, ping, prefix, profile, prune, publish, rb, rebuild, repo, restart, root, run, run-script, s, se, search, set, shrinkwrap, star, stars, start, stop, t, team, test, token, tst, un, uninstall, unpublish, unstar, up, update, v, version, view, whoami
npm <command> -h quick help on <command> npm -l display full usage info npm help <term> search for help on <term> npm help npm involved overview
Specify configs in the ini-formatted file: C:\Users\Shubham Bhardwaj.npmrc or on the command line via: npm <command> --key value Config info can be viewed via: npm help config
npm@6.14.4 C:\nvm\v14.1.0\node_modules\npm
Error Description
> robotjs@0.6.0 install C:\nodejs\node_modules\robotjs > prebuild-install || node-gyp rebuildprebuild-install WARN install No prebuilt binaries found (target=14.1.0 runtime=node arch=x64 libc= platform=win32)
gyp ERR! UNCAUGHT EXCEPTION
gyp ERR! stack Error: spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\MSBuild.exe ENOENT
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:268:19)
gyp ERR! stack at onErrorNT (internal/child_process.js:468:16)
gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:84:21)
gyp ERR! System Windows_NT 10.0.18363
gyp ERR! command “C:\nodejs\node.exe” “C:\nodejs\node_modules\node-gyp\bin\node-gyp.js” “rebuild”
gyp ERR! cwd C:\nodejs\node_modules\robotjs
gyp ERR! node -v v14.1.0
gyp ERR! node-gyp -v v6.1.0
gyp ERR! This is a bug in node-gyp
.
gyp ERR! Try to update node-gyp and file an Issue if it does not help:
gyp ERR! https://github.com/nodejs/node-gyp/issues
npm ERR! code ELIFECYCLE
npm ERR! errno 7
npm ERR! robotjs@0.6.0 install: prebuild-install || node-gyp rebuild
npm ERR! Exit status 7
npm ERR!
npm ERR! Failed at the robotjs@0.6.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\Shubham Bhardwaj\AppData\Roaming\npm-cache_logs\2020-05-03T09_31_41_003Z-debug.log
I tried a lot of solutions, but of no use. Please guide the way forward. I’ve been stuck on this for 2-3 days now.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 3
- Comments: 23 (8 by maintainers)
UPDATE :
This works for me 😃