If you’re running into the readline compile problem on ubuntu 14.04,
this is one fix:
Download the readline.patch file from this gist (click on “raw” and
download that link).
Go into your ruby-2.1.1 dir. Type this:
patch -p0 <path/to/the/readline.patch
I had to delete the last hunk from the patch file for it to work. (The
last hunk is only comments.)