contextify
contextify copied to clipboard
Issue with npm install (node-gyp rebuild)
windows 10 npm 2.15.9 node 4.5.0
$ npm install -g contextify
> [email protected] install C:\Users\edvins.antonovs\AppData\Roaming\npm\node_modules\contextify
> node-gyp rebuild
C:\Users\edvins.antonovs\AppData\Roaming\npm\node_modules\contextify>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
TRACKER : error TRK0005: Failed to locate: "CL.exe". The system cannot find the file specified. [C:\Users\edvins.antonovs\AppData\Roaming\npm\node_modules\contextify\build\contextify.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\edvins.antonovs\AppData\Roaming\npm\node_modules\contextify
gyp ERR! node -v v4.5.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "contextify"
npm ERR! node v4.5.0
npm ERR! npm v2.15.9
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the contextify package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs contextify
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!
npm ERR! npm owner ls contextify
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! D:\repos\contextify\npm-debug.log
Fixed it by installing Common Tools for C++ as an update for VS15.
Already had
- Win 10
- Python 2.7 and Python 3.6
- Visual Studio 2017 (Community Edition)
- Yeoman generated angular-fullstack project code for one of our customers.
Needed
- Node 6.14.4 (got NPM 3.10.10 along with Node installation itself)
- Bower (
npm install --global bower) - Yeoman with Angular-fullstack 3.5.0 (
npm install -g express yo grunt-cli [email protected])
Got error
npm ERR! node v6.14.4
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the contextify package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs contextify
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls contextify
npm ERR! There is likely additional logging output above.
Additional setup done
- Got to know about https://github.com/nodejs/node-gyp#option-1
- Installed VS 2017 build tools from https://visualstudio.microsoft.com/downloads/#build-tools-for-visual-studio-2017
- Launched command shell in Admin mode (with'Run as Administrator')
- Setup NPM configuration
npm config set python c:\Python27 --globalnpm config set msvs_version 2017 --global
npm install(for the project)- Got same error as above
- Upgraded NPM (
npm install -g npm@next)
- Setup NPM configuration
- Redid project dependencies (
npm install)
Got
added 9 packages from 95 contributors and audited 20159 packages in 175.14s
found 160 vulnerabilities (77 low, 49 moderate, 29 high, 5 critical)
run `npm audit fix` to fix them, or `npm audit` for details
So far ... good. Hope this helps somebody.