[Ruby] [Linux] install and configure the ruby Development Environment on centos

Source: Internet
Author: User
1. Install the compiling environment gcc
Install GCC online using Yum install

2. Install the ruby Development Environment
First download Linux Installation File: ruby-1.8.6-p111.tar.gz
Run

  1. Tar-zxvf ruby-1.8.6-p111.tar.gz
  2. CD ruby-1.8.6-p111
  3. ./Configure -- prefix =/usr/local/Ruby
  4. Make
  5. Make install

3. Install rubygems. rubygems is a module used to install the ruby extension package. It must be installed.
Installation: zlib-1.2.3.tar.gz
Rubygems-0.9.4.tgz
Run

  1. Tar-zxvf zlib-1.2.3.tar.gz
  2. CD zlib-1.2.3
  3. # Install static lib
  4. ./Configure
  5. Make Test
  6. Make install
  7. Make clean
  8. # Install share lib
  9. ./Configure -- shared
  10. Make Test
  11. Make install
  12. # Copy header files
  13. CP zutil. h/usr/local/include
  14. CP zutil. c/usr/local/include
  15. # Ruby zlib
  16. CD ruby-1.8.6/EXT/zlib
  17. Ruby extconf. RB -- With-zlib-include =/usr/include -- With-zlib-Lib =/usr/lib
  18. Make
  19. Make install
  20. CD ../..
  21. Make clean
  1. Tar-zxvf rubygems-0.9.4.tgz
  2. CD rubygems-0.9.4
  3. Ruby setup. Rb

You can install the gem package under rubyforge at will. Run the gem install-y-l filename. Gem command to install the package.
 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.