Created
January 25, 2012 10:07
-
-
Save zheileman/1675713 to your computer and use it in GitHub Desktop.
Installing JRuby 1.6.5.1 / Ruby 1.9.2 on Mac OSX Lion with RVM
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure to use RVM latest version | |
bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer) | |
# You can check which known versions has RVM (make sure you can see jruby[-1.6.5.1]) | |
rvm list known | |
# To install JRuby 1.6.5.1 | |
rvm install jruby | |
# To start using it (with Ruby 1.9.2 instead of 1.8.7) | |
rvm jruby | |
rvm --default use jruby | |
export JRUBY_OPTS=--1.9 | |
# We now need to make some changes to the Gemfile | |
# Remove gem 'ruby-prof' if you're using it as it seems to be incompatible with JRuby | |
# If you're using sqlite3, remove gem "sqlite3-ruby", :require => "sqlite3" and replace with: | |
# gem 'activerecord-jdbcsqlite3-adapter', :require => 'jdbc-sqlite3', :require =>'arjdbc' | |
# Installing the gems | |
gem update --system | |
gem install bundler | |
bundle install | |
# NOTE: If you're getting errors compiling native extension for the following gem, just remove it for now and execute bundle install again. I don't know how to make it work at the moment: | |
# gem 'ruby-debug19' | |
# Check environment | |
bundle exec ruby -v | |
# jruby 1.6.5.1 (ruby-1.9.2-p136) (2011-12-27 1bf37c2) (Java ... | |
bundle exec rails -v | |
# Rails 3.0.11 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment