From: "Shot (Piotr Szotkowski)" Date: 2008-10-20T05:26:09+09:00 Subject: Re: Running Multiple Versions of Ruby on Debian? --sdtB3X0nJg68CQEu Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable John Griffiths: > Has anyone had any experiences in running > multiple versions of Ruby on Debian Etch? I run hand-compiled Ruby 1.8.6, 1.8.7 and 1.9.0 alongside each other by putting them in ~/opt with, for example, =2E/configure --prefix=3D/home/shot/opt/ruby-1.8.7-p72 I then have ~/opt/ruby-1.8.7 symling poiting to it, plus export PATH_ORIG=3D"$PATH" export PATH=3D"/var/lib/gems/1.8/bin:$PATH_ORIG" in my ~/.bashrc plus alias r7=3D'export PATH=3D"/home/shot/opt/ruby-1.8.7/bin:$PATH_ORIG"' alias r8=3D'export PATH=3D"/home/shot/opt/ruby-1.8.6/bin:$PATH_ORIG"' alias r9=3D'export PATH=3D"/home/shot/opt/ruby-1.9.0/bin:$PATH_ORIG"' in my ~/.bash_aliases =E2=80=93 this way I get the system=E2=80=99s Ruby+Ru= byGems by default and can switch to my hand-compiled environment when I want to run Ruby 1.8.6, 1.8.7 or 1.9.0. Ruby 1.9 comes with RubyGems, in the cases of Ruby 1.8 you need to download the tarball and then run `ruby setup.rb` with the proper, hand-compiled Ruby binary. I hand-compile 1.8.6 because Debian and Ubuntu by default --enable-pthreads which is a performance killer. export CFLAGS=3D'-O3 -march=3Dnative' should also boost performance, but in my case the differences are neglible. -- Shot --=20 It's sobering to think that the people who forward chain email can also vote. -- Scott Adams --sdtB3X0nJg68CQEu Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) iD8DBQFI+5mSi/mCfdEo8UoRAmPHAJ9eqfd7yPhvS0Bm6LlX6WoEhwGjQgCffR9c bopZNdyos0XwYNMn4W0vxEc= =6+He -----END PGP SIGNATURE----- --sdtB3X0nJg68CQEu--