使用npm安装express时出现问题. [英] Problems installing express using npm.
问题描述
我正在尝试使用npm安装Express,并运行以下代码:
Im trying to install express using npm, running this code:
npm安装快递猫鼬玉较少快递
npm install express mongoose jade less expresso
但我一直收到此错误,
> make deps/jscoverage/node-jscoverage
sh: make: command not found
npm ERR! expresso@0.9.2 preinstall: `make deps/jscoverage/node-jscoverage`
npm ERR! `sh "-c" "make deps/jscoverage/node-jscoverage"` failed with 127
npm ERR! Failed at the expresso@0.9.2 preinstall script.
npm ERR! This is most likely a problem with the expresso package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! make deps/jscoverage/node-jscoverage
我搜索了很多东西,但似乎找不到答案.干杯.
I searched a lot and can't seem to find the answer. Cheers.
推荐答案
您没有make,必须安装它(它是gcc的一部分).
You don't have make, you must install it (it's a part of gcc).
如果您使用的是基于Debian的linux发行版:
If you're on a Debian-based linux distribution:
sudo apt-get install build-essential
如果您使用的是Mac OS X,则必须先安装XCode,然后再安装其命令行工具:
If you're on Mac OS X you must install XCode and then install its Command Line Tools:
安装XCode 4,然后将其打开,转到首选项"->下载"->组件"->单击命令行工具",然后单击其安装"按钮.
Install XCode 4 then open it, Got to Preferences -> Downloads -> Components -> Click on Command Line Tools and then click on its Install button.
我只是希望您不在Windows上,因为我将无法帮助您,呵呵-P
And I just hope you're not on Windows, because I won't be able to help you hehe :-P
希望这会有所帮助!
这篇关于使用npm安装express时出现问题.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!