我正在尝试在ubuntu 11.10上安装now.js(在带有wubi的windows上运行,如果这很重要)。我已经下载并安装了node,npm和socket.io就好了,但sudo npm install now
因某些原因失败了。我尝试过使用和不使用sudo,尝试全局安装,同样的错误。 Make安装得很好......节点代理包有问题吗?对于它的价值,尝试npm install node-proxy
会产生类似的错误。
节点版本0.6.2
npm版本1.0.106
ubuntu 11.10(与wubi一起使用的窗口)
当我尝试立即安装时,日志会显示:
npm WARN node-proxy@0.5.2 package.json: bugs['web'] should probably be bugs['url']
> node-proxy@0.5.2 install /home/my_name/node_modules/now/node_modules/node-proxy
> make
BUILDING: C++ Component
/bin/sh: node-waf: not found
cp: cannot stat `src/build/*/node-proxy.node': No such file or directory
make: *** [all] Error 1
npm ERR! error installing node-proxy@0.5.2 Error: node-proxy@0.5.2 install: `make`
npm ERR! error installing node-proxy@0.5.2 `sh "-c" "make"` failed with 2
npm ERR! error installing node-proxy@0.5.2 at ChildProcess. (/usr/lib/node_modules/npm/lib/utils/exec.js:49:20)
npm ERR! error installing node-proxy@0.5.2 at ChildProcess.emit (events.js:70:17)
npm ERR! error installing node-proxy@0.5.2 at maybeExit (child_process.js:359:16)
npm ERR! error installing node-proxy@0.5.2 at Process.onexit (child_process.js:395:5)
npm ERR! error installing now@0.7.6 Error: node-proxy@0.5.2 install: `make`
npm ERR! error installing now@0.7.6 `sh "-c" "make"` failed with 2
npm ERR! error installing now@0.7.6 at ChildProcess. (/usr/lib/node_modules/npm/lib/utils/exec.js:49:20)
npm ERR! error installing now@0.7.6 at ChildProcess.emit (events.js:70:17)
npm ERR! error installing now@0.7.6 at maybeExit (child_process.js:359:16)
npm ERR! error installing now@0.7.6 at Process.onexit (child_process.js:395:5)
npm ERR! node-proxy@0.5.2 install: `make`
npm ERR! `sh "-c" "make"` failed with 2
npm ERR!
npm ERR! Failed at the node-proxy@0.5.2 install script.
npm ERR! This is most likely a problem with the node-proxy package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! make
npm ERR! You can get their info via:
npm ERR! npm owner ls node-proxy
npm ERR! There is likely additional logging output above.
npm ERR!
npm ERR! System Linux 3.0.0-13-generic
npm ERR! command "node" "/usr/bin/npm" "install" "now"
npm ERR! cwd /home/my_name
npm ERR! node -v v0.6.2
npm ERR! npm -v 1.0.106
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/my_name/npm-debug.log
npm not ok
答案 0 :(得分:1)
问题似乎是缺少node-waf
。
node-waf是一个包含在节点中的工具,它允许编译二进制模块,例如node-proxy。
您可以通过在终端中键入node-waf
以查看是否可以找到该命令来测试node-waf是否可用。如果没有,您将需要重新安装节点(再次运行make install
)以确保node-waf可用。