Install Ruby 2.0 with OpenSSL and ReadLine support
Solution 1:
In your source location, cd ext/openssl
and then ruby extconf.rb
. This will generate a makefile in the ext/openssl directory. Simply make && sudo make install
it to build the ruby openssl extension, and install the .so into the appropriate location.
Ditto ext/readline
for readline support.
Then you should be able to make
ruby properly.
Edit: in case I wasn't clear enough:
pushd ext/openssl
ruby extconf.rb
make && sudo make install
popd
pushd ext/readline
ruby extconf.rb
make && sudo make install
popd
make
sudo make install
Solution 2:
I ran into the same issue, I had to install the following two packages
libssl-dev
libreadline-dev
in fact I found I had to install the following packages to get ruby 2.0.0 and postgres 9.2 to compile on ubuntu 13.04 with openssl and readline so I thought I would share them
sudo apt-get -y update
sudo apt-get install -y make g++
sudo apt-get install -y curl git-core python-software-properties
sudo apt-get install -y build-essential zlib1g-dev libyaml-dev libssl-dev
sudo apt-get install -y libgdbm-dev libreadline6-dev libncurses5-dev
sudo apt-get install -y libpq-dev libffi-dev
Solution 3:
for me it was a case of missing dependencies.
i thought i had all the dependencies required to install ruby, but i too was getting an openSSL and readline error.
i attempted to install ruby with RVM without root privileges which failed but gave me a list of missing dependencies. i then installed the dependencies with a package manager. i then re-attempted to install ruby from source from the beginning, and everything worked OK
the dependencies that were missing, for me, were:
patch libyaml-devel autoconf gcc-c++ readline-devel libffi-devel openssl-devel automake libtool bison sqlite-devel
but they may be different for you.
update: i don't originally remember where exactly i found this list, but a quick search found similar lists on the following pages, which might also help you:
https://www.digitalocean.com/community/tutorials/how-to-install-ruby-on-rails-on-centos-6-with-rvm
http://www.itzgeek.com/how-tos/linux/ubuntu-how-tos/install-ruby-on-rails-on-centos-ubuntu-fedora-from-source.html