问题无法在laravel vagrant homestead中安装socket.io。抛出了波纹错误。
命令 npm install socket.io
错误
> ws@0.5.0 install /home/vagrant/Code/dota2/nodejs/node_modules/socket.io/node_m
odules/engine.io/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)
make: Entering directory `/home/vagrant/Code/dota2/nodejs/node_modules/socket.io
/node_modules/engine.io/node_modules/ws/build'
CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
SOLINK_MODULE(target) Release/obj.target/bufferutil.node
SOLINK_MODULE(target) Release/obj.target/bufferutil.node: Finished
COPY Release/bufferutil.node
CXX(target) Release/obj.target/validation/src/validation.o
SOLINK_MODULE(target) Release/obj.target/validation.node
SOLINK_MODULE(target) Release/obj.target/validation.node: Finished
COPY Release/validation.node
make: Leaving directory `/home/vagrant/Code/dota2/nodejs/node_modules/socket.io/
node_modules/engine.io/node_modules/ws/build'
npm ERR! Error: UNKNOWN, symlink '../ws/bin/wscat'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-30-generic
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install"
npm ERR! cwd /home/vagrant/Code/dota2/nodejs
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! path ../ws/bin/wscat
npm ERR! code UNKNOWN
npm ERR! errno -1
npm ERR! not ok code 0
答案 0 :(得分:1)
Vagrant / Homestead虚拟机无法处理二进制链接。
而不是
npm install socket.io
使用
npm install socket.io --no-bin-links