Redhat up2date service has a ruby rpm but it is older, so install ruby from source.
Make sure you have zlib-devel installed, otherwise the following installation of Ruby Gems fails. This needs to be done before the ./configure step of the ruby install.
up2date zlib-devel
Determine what Ruby RPMs you have installed:
$ rpm -qa | egrep '(ruby)|(irb)'
Then uninstall, for example:
$ rpm -e ruby-docs-1.8.1-7.EL4.2 \
ruby-1.8.1-7.EL4.2 \
irb-1.8.1-7.EL4.2 \
ruby-libs-1.8.1-7.EL4.2 \
ruby-mode-1.8.1-7.EL4.2 \
ruby-tcltk-1.8.1-7.EL4.2 \
ruby-devel-1.8.1-7.EL4.2
wget ftp://ftp.ruby-lang.org/pub/ruby/ruby-1.8.4.tar.gz
tar xvzf ruby-1.8.4.tar.gz
cd ruby-1.8.4
./configure --prefix=/usr
make
make install
cd
wget <a href="http://rubyforge.org/frs/download.php/5207/rubygems-0.8.11.tgz">http://rubyforge.org/frs/download.php/5207/rubygems-0.8.11.tgz</a>
tar xvzf rubygems-0.8.11.tgz
cd rubygems-0.8.11
ruby setup.rb
cd
gem update
gem update --system
rm `gem env gempath`/source_cache
rm -f ~/.gem/source_cache
gem update
gem install rails --include-dependencies
category: Howto
kayess Small note: I kept getting “hook /root/rubygems-0.8.11/./post-install.rb failed: wrong # of arguments(2 for 1)” until I used “sudo ruby setup.rb”.
Redhat up2date service has a ruby rpm but it is older, so install ruby from source.
Make sure you have zlib-devel installed, otherwise the following installation of Ruby Gems fails. This needs to be done before the ./configure step of the ruby install.
up2date zlib-devel
Determine what Ruby RPMs you have installed:
$ rpm -qa | egrep '(ruby)|(irb)'
Then uninstall, for example:
$ rpm -e ruby-docs-1.8.1-7.EL4.2 \
ruby-1.8.1-7.EL4.2 \
irb-1.8.1-7.EL4.2 \
ruby-libs-1.8.1-7.EL4.2 \
ruby-mode-1.8.1-7.EL4.2 \
ruby-tcltk-1.8.1-7.EL4.2 \
ruby-devel-1.8.1-7.EL4.2
wget ftp://ftp.ruby-lang.org/pub/ruby/ruby-1.8.4.tar.gz
tar xvzf ruby-1.8.4.tar.gz
cd ruby-1.8.4
./configure --prefix=/usr
make
make install
cd
wget <a href="http://rubyforge.org/frs/download.php/5207/rubygems-0.8.11.tgz">http://rubyforge.org/frs/download.php/5207/rubygems-0.8.11.tgz</a>
tar xvzf rubygems-0.8.11.tgz
cd rubygems-0.8.11
ruby setup.rb
cd
gem update
gem update --system
rm `gem env gempath`/source_cache
rm -f ~/.gem/source_cache
gem update
gem install rails --include-dependencies
category: Howto
kayess Small note: I kept getting “hook /root/rubygems-0.8.11/./post-install.rb failed: wrong # of arguments(2 for 1)” until I used “sudo ruby setup.rb”.