I am attempting to install RoR on my Lubuntu box just setup today, I have installed all of the rvm requirements installed Ruby. When I go to install rails I keep getting this error.
Running the command sudo gem install rails -V it looks like it’s trying to pull source for ruby 1.9.1 but I have 1.9.2 and then it fails out cannot load such file –mkmf (LoadError).
Any help would be much appreciated, this is my first adventure into Ruby so this is my first setup. Ask any questions and I will answer.

First, you need some RVM preinstallations, open terminal and type:
Then download and install RVM itself:
After installing is done, load RVM:
To check that RVM is installed as a function, type:
In order to work, RVM has some of it’s own dependencies that need to be installed. You can see what these are using:
For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
Once you are using RVM, installing Ruby is easy:
In newer version of Rails, you also need a Javascript runtime, so:
We can continue to use RVM to install gems:
Once everything is set up, it is time to install Rails:
P.S.
Postinstall & Troubleshooting.
When we disable GNOME Terminal’s “Run command as login shell”, rvm unable to load as a function, so typing:
outputs something like “rvm is /home/mercurial/.rvm/bin/rvm”.
In order fix this, edit ~/.bashrc and add the following line in the end of file: