On Jun 13, 2006, at 12:50 PM, Leslie Viljoen wrote: > On 6/13/06, John Gabriele <jmg3000 / gmail.com> wrote: >> On 6/12/06, Pat Maddox <pergesu / gmail.com> wrote: >> > I've got an app that requires the openssl library. Whenever I >> run it, >> > it just says "no such file to load -- openssl." Didn't know I >> had to >> > install anything special to get openssl in Ruby. What do I have to >> > do? >> >> As an aside, although it's not the Debian way, I've found it >> easier to >> not install the official Debian packages, but instead just install >> Ruby from source into its own --prefix=/opt/ruby-1.8.4, then install >> RubyGems, then get everything else as-needed using the gem command. >> >> Dunno if that would fix your ssl issue though. > > Can you give us a little howto on that? I have been battling gem vs. > apt forever. Last time I tried to compile Ruby there were a bunch of > dependencies and it took me quite a while to get it done. Which makes > me think.. if this is the best way to go, I'll keep track and write a > script to do it next time. Though if I wrote it in Ruby I'd have to > package it as an executable or something... > > I'd love to have a one-click installer under Linux that leaves all the > gems just working properly. > I have been using this shell script with much success on debian and OSX. Feel free to leave out packages you don't need from this. BUt if you just cd to your home dir and run this script with sudo you will get a fully functionaly ruby install including other niceties. Cheers- -Ezra #!/bin/sh mkdir src cd src # Readline curl -O ftp://ftp.gnu.org/gnu/readline/readline-5.1.tar.gz tar xzvf readline-5.1.tar.gz cd readline-5.1 ./configure --prefix=/usr/local make sudo make install cd .. # Ruby curl -O ftp://ftp.ruby-lang.org/pub/ruby/ruby-1.8.4.tar.gz tar xzvf ruby-1.8.4.tar.gz cd ruby-1.8.4 ./configure --prefix=/usr/local --with-readline-dir=/usr/local make sudo make install cd .. # Rubygems curl -O http://rubyforge.org/frs/download.php/5207/rubygems-0.8.11.tgz tar xzvf rubygems-0.8.11.tgz cd rubygems-0.8.11 sudo /usr/local/bin/ruby setup.rb cd .. # Rails sudo gem install rails --include-dependencies # FastCGI curl -O http://www.fastcgi.com/dist/fcgi-2.4.0.tar.gz tar xzvf fcgi-2.4.0.tar.gz cd fcgi-2.4.0 ./configure --prefix=/usr/local make sudo make install cd .. # Ruby-FastCGI Bindings curl -O http://sugi.nemui.org/pub/ruby/fcgi/ruby-fcgi-0.8.6.tar.gz tar xzvf ruby-fcgi-0.8.6.tar.gz cd ruby-fcgi-0.8.6 /usr/local/bin/ruby install.rb config --prefix=/usr/local /usr/local/bin/ruby install.rb setup sudo /usr/local/bin/ruby install.rb install cd .. sudo gem install fcgi # PCRE Prerequisite to Lighttpd curl -O ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/ pcre-6.4.tar.gz tar xzvf pcre-6.4.tar.gz cd pcre-6.4 ./configure --prefix=/usr/local make sudo make install cd .. # Lighttpd curl -O http://lighttpd.net/download/lighttpd-1.4.11.tar.gz tar xzvf lighttpd-1.4.11.tar.gz cd lighttpd-1.4.11 ./configure --prefix=/usr/local --with-pcre=/usr/local --with-openssl make sudo make install cd ..