Skip to content

Instantly share code, notes, and snippets.



Last active Aug 29, 2015
What would you like to do?
Compile ruby from source for rbenv on OS X
# Assumptions:
# - You are using rbenv, installed in ~/.rbenv
# - You are using homebrew
# - You want to install ruby 2.1.2 (for example)
# Make sure you have openssl installed first
brew install openssl
# Before you begin, download ruby source from
tar -zxvf ruby-2.1.2.tar.gz
cd ruby-2.1.2
./configure --prefix=`echo ~`/.rbenv/versions/2.1.2 --with-openssl-dir=`brew --prefix openssl`
make install
rbenv rehash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment