ror installation
My steps to install Ruby On Rails 1.8.5 over ubuntu 6.0.6
Prep
Make sure you have gcc complier and zlib development package installed. If not sure, please run
apt-get install build-essestialRuby
apt-get install zlib1g-dev
Download ruby-1.8.5-p12.tar.gz from http://www.rubyonrails.org
tar xzvf ruby-1.8.5-p12.tar.gzIf you saw lots of text fly by but didn’t get that error, it means that we should now have a brand new Ruby installed.
cd ruby-1.8.5-p12
./configure --prefix=/usr/local --enable-pthread
make
sudo make install
sudo make install-doc
cd ..
We can verify this (as well as a correct path setting) by typing the following command:
ruby -vYou should see something like this:
ruby 1.8.5 (2006-12-04 patchlevel 2) [i686-linux]zLib
Download zlib package from
http://www.blue.sky.or.jp/atelier/ruby/ruby-zlib-0.6.0.tar.gz
tar zxvf ruby-zlib-0.6.0.tar.gzRubyGems
cd ruby-zlib-0.6.0
ruby extconf.rb
make
sudo make install
cd ..
Download rubygems package rubygems-0.9.2.tgz from
http://rubyforge.org/projects/rubygems/
RubyOnRailstar xzvf rubygems-0.9.2.tgz
cd rubygems-0.9.2
sudo /usr/local/bin/ruby setup.rb
cd ..
With RubyGems installed, Rails is a simple, one-line install:
* gem respects the following variables for proxy settingssudo gem install rails --include-dependencies
- http_proxy
- HTTP_PROXY
- NO_PROXY
2 則留言:
The first two lines should be
apt-get install build-essential
apt-get install zlib1g-dev
Just typo ~
when installing ruby 1.8.6, it may show this error
"/usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/initializer.rb:159:in
`require_frameworks': no such file to load -- openssl (RuntimeError)"
To solve this
(1) sudo apt-get install libssl-dev
(2) go to ruby_source/ext/openssl and run extconf.rb (and
then make; make install)
After than the error should be gone
發佈留言