Install Ruby via Source Ubuntu
This blog post is for old style programmer who wish to install ruby via compiling the source code, like how I do it. This blog post is written in a just to know basis.
The source code of ruby can be downloaded from ruby’s official website http://www.ruby-lang.org/en/downloads/.
Dependency for Ruby and Ruby on Rails : libreadline, libyaml, libxml, libssl, zlib1g.
In ubuntu you can have these libraries installed via the command line ( or if you are so old fashion you may google and find the source code for these packages as well)
|
|
After installing the dependency download the source code and extract it ( please not the installation will proceed if you miss some of the dependencies but missing then would make gem, bundle, irb to not function properly).
First extarct the code :
|
|
the configure the source code
|
|
the finally you make and install
|
|
To check if ruby is install you can use the command
|
|
or try out interactive ruby (irb)
|
|
Now for those who are wondering how to install the latest version of rails, use the command:
|
|