-
-
Notifications
You must be signed in to change notification settings - Fork 189
Ruby
Shannon Skipper edited this page Dec 17, 2024
·
100 revisions
CRuby or MRI (Matz's Ruby Implementation), is the defacto Ruby and sets the standards for other Ruby implementations.
| Operating System | Command |
|---|---|
| Debian / Ubuntu |
|
| RedHat / Fedora |
|
| openSUSE |
sudo zypper install gcc automake bison libffi-devel libyaml-devel openssl-devel readline-devel zlib-devel |
| Arch Linux |
|
| FreeBSD |
|
| NetBSD |
|
| macOS |
|
| Alpine Linux |
|
wget https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.6.tar.xz
tar -xJvf ruby-3.3.6.tar.xz
cd ruby-3.3.6
./configure --prefix=/opt/rubies/ruby-3.3.6
make
sudo make install
Note: macOS users must properly specify ./configure --with-openssl-dir=... --with-opt-dir=... to compile Ruby against Homebrew's packages:
curl --remote-name https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.6.tar.xz
tar -xvf ruby-3.3.6.tar.xz
cd ruby-3.3.6
./configure \
--prefix="$HOME/.rubies/ruby-3.3.6" \
--with-libyaml-dir="$(brew --prefix libyaml)" \
--with-openssl-dir="$(brew --prefix openssl@3)" \
--with-readline-dir="$(brew --prefix readline)" \
--with-zlib-dir="$(brew --prefix zlib)" \
--with-opt-dir="$(brew --prefix gmp):$(brew --prefix jemalloc)" \
--with-jemalloc
make -j8
make install