Nodejs : Depends: rlwrap but it is not installable

aptnode.jsubuntu-14.04

Just bought a new fresh virtual server in the cloud, Ubuntu 14.04.

I updated my packages with apt-get update.

Got problems when trying to install node js. I followed this guide: https://github.com/joyent/node/wiki/installing-node.js-via-package-manager

When I run sudo apt-get install -y nodejs I get this:

user@server sudo apt-get install nodejs
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 nodejs : Depends: rlwrap but it is not installable
E: Unable to correct problems, you have held broken packages.

What is this rlwrap? I googled but did not find how to install it.

Update

I tried the suggestions below. No success. I downgraded to 12.04. Everything worked there.

Best Answer

I had the same exact problem in Ubuntu 14.04. The solution:

  1. Download rlwrap from http://packages.ubuntu.com/trusty/rlwrap. Here is a Direct Link
  2. Install it sudo dpkg -i rlwrap_0.34-2_amd64.deb
  3. Install nodejs sudo apt-get install nodejs