Installing Ruby 1.9.1 & Rails From Source on Ubuntu Screencast

Here’s the screencast that shows me performing the install of Ruby 1.9.1 Preview 1 on Ubuntu. I’m installing it from the source code.

This is very raw video and as I promised, I’ll get better with more practice, so bare with me. It’s just that I need to learn how to breathe and learn to speak without anyone in front of me.

I also started a channel on Vimeo. I plan to capture my coding sessions(non-work stuff obviously) and put them up there as well.

Compiling Ruby 1.9.1 Preview 1 on Ubuntu from Joon You on Vimeo.

Installing Ruby 1.9.1 Preview 1 + Rails on Ubuntu 8.04LTS Hardy Heron

*** Update ***
The screencast of this is up at http://blog.rubyhead.com/2009/01/14/installing-ruby-191-from-source-on-ubuntu-screencast/ This instruction is valid for the final 1.9.1 release.

I will have a screencast of this soon, but here’s how I installed Ruby 1.9.1 Preview 1 from source code on my Ubuntu 8.04 Hardy Heron machine (works on 8.10 as well). Please be advised that this is a fresh install. If you already have 1.8.x installed, then here are the list of things you need to be aware of:

  • sudo make install will not overwrite any symlink. You’ll have to do that manually.
  • This version of Ruby comes with Gem 1.3.1. You’ll have to link it to proper version
  • You’ll have to reinstall all gems. They are kept in separate directory.
  • Mongrel can’t be installed due to fastthread.

Step 1
You’ll need to get the necessary tools.

sudo apt-get install build-essential autoconf wget libreadline5-dev libncurses5-dev zlib1g-dev libsqlite3-dev libssl-dev

zlib1g -> that’s number one, not letter L.

Step 2
Get the source code from Ruby site and extract it.

wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-preview1.tar.gz
tar xvzf ruby-1.9.1-preview1.tar.gz
cd ruby-1.9.1-preview1

Step 3
Compile and install

autoconf
./configure --prefix=/usr --enable-pthread
make
sudo make install

Step 4
Install Rails and bare Gems. You have to be aware that test-unit gem is crucial here.

sudo gem install rails sqlite3-ruby rubygems-update test-unit capistrano

That’s basically it. Make sure you dont’ delete the source code as you’ll need to install components in the future. I’ll go over that next.

Self.reflect :year => 2008, :subject => me_as_rubyhead

2008 has been one of the most interesting year of my life. It’s interesting not because of this year, I got to dive in and got my hands dirty coding. In the process, got reminded what it is like to work in the trenches. I’ve been in CTO position for very long time and my expectations have not kept up to date.

Here’s a list of other things I gained:

  • I can code so much better and faster than I did before. And trust me, that’s saying alot.
  • Practiced enough Ruby to be extremely dangerous and stupid
  • Thanks to current employer, got to program in C++ and got a fresh reminder why I hate it so much
  • Appreciation for Ruby and new things coming out

I need to thank my family and especially my wife for making sacrifices so that I can take a year doing what I enjoyed and what I thought I needed. It wasn’t easy going back to being a developer, especially from financial standpoint, but we made out okay, even with the massive decline in our net worth.

« Previous Page

Powered by Olark