在Debian 6上安装nodejs

很多(旧的)post都提出,如果想在Debian 6上安装node.js(在我的情况下,这是我正在试验的Amazon EC2 t1.micro实例),那么需要编译自己的事实Debian软件包显着滞后于Node.js开发的疯狂步伐。

node.js网站列出了v0.10.17作为当前的稳定版本。 当前nodejs包的信息也很好的列出了(0.10.17〜dfsg1-2)这听起来不错吧? 毕竟不必做!

问题是这个请求:

sudo apt-get install nodejs 

产生这些结果:

 Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package nodejs 

所以我的问题是这样的:当我看到一个包是PLANNED但尚未创build,或者有可能是一些apt-get问题,我的安装只是看不到nodejs包,因此无法安装它? 我坚持不得不做一个? (顺便说一句,当我尝试它时炸毁了我)。

我不知道你从源代码编译的步骤。 这是我使用的,它在多个服务器上运行良好:

 sudo apt-get install git build-essential sudo apt-get install wget wget (link to node.js source -> found on nodejs.org/download/) tar xvf node(press tab to auto load the version you're on) pushd node(again, use tab) ./configure make sudo make install 

去testing:

 node 0.1 + 0.2 

你应该收到回复。 可以了,好了。