oscartheduckin’ around

November 6, 2008

Installing rails 2.02 on ubuntu Intrepid with ruby 1.8.6

Filed under: how to, ruby, ubuntu — oscartheduck @ 5:26 pm

I’ve done this too many times to have not documented it somewhere.

Ruby 1.8.7 is the default on Intrepid; 1.8.6 is needed to run rails < 2.1, so it’s useful to know how to do it.

1. Install ruby from source.

http://ruby.mirrors-r-us.net/news/2007/03/12/ruby-1-8-6-released/index.html

2. install rubygems from source

http://files.rubyforge.vm.bytemark.co.uk/rubygems/rubygems-1.3.1.tgz

3. You’ll get the following error:

in `gem_original_require’: no such file to load — zlib (LoadError)

if you try to use rubygems.

To solve this, go into your ruby source directory:

cd ruby-1.8.6/

then:

cd ext/zlib

ruby extconf.rb

make

sudo make install

4. sudo gem install rails -v 2.0.2

6 Comments »

  1. Note that some gems require old versions of rubygems. I think memcached does, for example. In either case, I documented how to swap out versions of rubygems in the memcached post in this blog.

    Comment by oscartheduck — November 21, 2008 @ 6:35 pm

  2. Ubuntu 8.10 Downgrade Ruby 1.8.7 to 1.8.6

    http://railsgeek.com/2008/11/27/ubuntu-8-10-downgrade-ruby-1-8-7-to-1-8-6

    Comment by Mikhailov Anatoly — November 27, 2008 @ 11:46 am

  3. I have found the article about install Ruby 1.8.6 on Ubuntu 8.10 from repo.
    You can find this one at http://www.railsgeek.com

    Comment by mikhailov — November 27, 2008 @ 12:50 pm

  4. Incidentally, following these instructions did not work and I have not been able to repair the damage by using my package manager. I would suggest following the link in comment #2 if you’re using intrepid.

    Comment by Rick — January 20, 2009 @ 4:56 am

  5. Interesting. There’s nothing here that’d damage a system if you understand how you’re installing things from source; there’s usually a make uninstall option in the makefile that comes in the source tarball. If there’s not one, you can write one by looking through the makefile and seeing where everything was installed to, then submit it as a patch to the ruby team.

    Your package manager can have these things registered too, but I believe it involves making a dpkg out of them in ubuntu.

    Comment by oscartheduck — January 24, 2009 @ 1:48 am

  6. It is not my first time to visit this website, i am visiting this site dailly and obtain nice data from here every day.

    Comment by hack facebook account free 2013 — August 21, 2013 @ 8:15 am


RSS feed for comments on this post. TrackBack URI

Leave a comment

Create a free website or blog at WordPress.com.