npm install fails while configuring rocket chat electron codebase
Rocket.Chat Version: 2.9.0-develop (Electron) Running Instances: Windows 8.1 DB Replicaset OpLog: Node Version: v6.9.2
I am trying to setup the rocketchat electron latest codebase in visual studio. I have successfully checked out the code. Then I opened the command prompt and navigated to the code base and executed the "npm install" command. I am getting the following the error:
`C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron>npm install
[email protected] postinstall C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron install-app-deps && electron-rebuild
Rebuilding native production dependencies for win32:x64 Error: C:\Program Files\nodejs\node.exe exited with code 1 Output:
@paulcbetts/[email protected] install C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules@paulcbetts\system-idle-time node-gyp rebuild
C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules@paulcbetts\system-idle-time>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. C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targets(356,5): error MSB6006: "CL.exe" exited with code -1073741701. [C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules@paulcbetts\system-idle-time\build\system_idle_time.vcxproj]
Error output:
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe fail
ed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules
npm\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:191:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_proces
s.js:215:12)
gyp ERR! System Windows_NT 6.3.9600
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\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules@paulcbetts\system-idle-time
gyp ERR! node -v v6.9.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @paulcbetts/[email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @paulcbetts/[email protected] 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\dan_chris\AppData\Roaming\npm-cache_logs\2017 -06-29T15_23_25_154Z-debug.log
at ChildProcess.childProcess.once.code (C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\electron-builder-util\src\util.ts:135:14)
at ChildProcess.g (events.js:291:16)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:877:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
From previous event:
at spawn (C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\electron-builder-util\src\util.ts:103:3)
at C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.
Electron\node_modules\electron-builder\src\yarn.ts:138:5
From previous event:
at rebuild (C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\electron-builder\out\yarn.js:93:22)
at C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.
Electron\node_modules\electron-builder\src\yarn.ts:16:11
at next (native)
at runCallback (timers.js:637:20)
at tryOnImmediate (timers.js:610:5)
at processImmediate [as _immediateCallback] (timers.js:582:5)
From previous event:
at installOrRebuild (C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\electron-builder\out\yarn.js:33:21)
at C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.
Electron\node_modules\electron-builder\src\cli\install-app-deps.ts:32:2
at next (native)
at runCallback (timers.js:637:20)
at tryOnImmediate (timers.js:610:5)
From previous event:
at main (C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\electron-builder\out\cli\install-app-deps.js:36:21)
at Object.install-app-deps && electron-rebuild
npm ERR! Exit status 4294967295
npm ERR!
npm ERR! Failed at the [email protected] postinstall 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\dan_chris\AppData\Roaming\npm-cache_logs\2017-06-29T15_23_25_251Z-debug.log`
Please help me to configure this
May be same like in https://github.com/RocketChat/Rocket.Chat.Electron/issues/472
I've tried to build the Electron Client for Windows too and it was not possible from the develop branch. The master branch (2.8.0) is working fine.
Thank you. Today I tried with master codebase, however I have no luck. Currently I am trying to understand the following lines in the error log:
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targets(356,5): error MSB6006: "CL.exe" exited with code -1073741701.
[C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\spellchecker\build\hunspell.vcxproj]
Please share your thoughts
Now I am stucked with another issue, seems the Spell checker is creating the issue:
`> [email protected] install C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\spellchecker
node-gyp rebuild
C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\spellchecker>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 "node C:\Users\dan_chris\AppData \Roaming\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild ) module.js:471 throw err; ^
Error: Cannot find module 'C:\Users\dan_chris\Documents\Git\Dev\Rocket-Chat\Rocket.Chat.Electron\node_modules\spellchecker\node C:\Users\dan_chris\AppData\Roaming\npm\node_modules\node-gyp\bin\node-gyp.js' at Function.Module._resolveFilename (module.js:469:15) at Function.Module._load (module.js:417:25) at Module.runMain (module.js:604:10) at run (bootstrap_node.js:394:7) at startup (bootstrap_node.js:149:9) at bootstrap_node.js:509:3 npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] 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\dan_chris\AppData\Roaming\npm-cache_logs\2017-06-30T06_51_20_440Z-debug.log`
Please advise me on this
Please reopen this issue in here https://github.com/RocketChat/Rocket.Chat.Electron . Thanks!