Build Error when Installing Socket.IO on Ubuntu 14.04
node.js, redis, socket.io, ubuntu
Solution
I don't see any errors here. `(node-gyp rebuild 2> builderror.log) || (exit 0)` is just the command which gets executed.
- `node-gyp rebuild` is the actual command.
- `2>`: Here `2` is stderr, `>` redirects stderr to the file `builderror.log`. In simpler words, error is written to `builderror.log`.
- `||` means "or". If `(node-gyp rebuild 2> builderror.log)` generates an error, exit code will be truthy (not 0). If the `node-gyp rebuild` command doesn't generate an error, the left hand side of the "or" statement will be falsy (0), and `(exit 0)` gets executed.
- `(exit 0)`: 0 is the status code for success.
Problem
I seem to be getting the same error over several times. I keep getting this (node-gyp rebuild 2> builderror.log) || (exit 0) message. What exactly is it? Also is the node.js redis module no longer included with socket.io? ``` ubuntu@ip-10-180-52-29:~$ sudo npm install socket.io > ws@0.4.31 install /home/ubuntu/node_modules/socket.io/node_modules/engine.io/node_modules/ws > (node-gyp rebuild 2> builderror.log) || (exit 0) make: Entering directory `/home/ubuntu/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build' CXX(target) Release/obj.target/bufferutil/src/bufferutil.o make: Leaving directory `/home/ubuntu/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build' > ws@0.4.31 install /home/ubuntu/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws > (node-gyp rebuild 2> builderror.log) || (exit 0) make: Entering directory `/home/ubuntu/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build' CXX(target) Release/obj.target/bufferutil/src/bufferutil.o make: Leaving directory `/home/ubuntu/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build' socket.io@1.0.6 node_modules/socket.io ├── debug@0.7.4 ├── has-binary-data@0.1.1 (isarray@0.0.1) ├── socket.io-parser@2.2.0 (isarray@0.0.1, emitter@1.0.1, json3@3.2.6) ├── socket.io-adapter@0.2.0 (socket.io-parser@2.1.2) ├── engine.io@1.3.1 (base64id@0.1.0, debug@0.6.0, engine.io-parser@1.0.6, ws@0.4.31) └── socket.io-client@1.0.6 (to-array@0.1.3, indexof@0.0.1, component-bind@1.0.0, object-component@0.0.3, component-emitter@1.1.2, parseuri@0.0.2, engine.io-client@1.3.1) ```