You're reading for free via mim Armand's Friend Link. Become a member to access the best of Medium.
Member-only story
Only read if you see this error message!
How to Fix the “No Binary Rubies Available for: ruby-3” Error on Apple Silicon Mac
A Quick Workaround to Save You Some Headache
If you don’t have a membership yet, you can use this link to read this article for free! :)
If you’re reading this, chances are you’ve encountered the infamous error message:
No binary rubies available for: ruby-3
I recently faced this issue while setting up my Flutter development environment on a new MacBook Pro with the Apple Silicon (M series) chip. Here’s a short and sweet guide to help you avoid the hours of frustration I endured.
The Setup
While running flutter doctor
, I discovered I needed to install or update CocoaPods. However, every attempt to fix one issue led to another. Eventually, I realized I had to install Ruby version 3.x to resolve the chain of problems.
I decided to use RVM (Ruby Version Manager) to handle the Ruby installation. That’s when the real challenge began.
The Problem
Trying to install Ruby 3.x on a MacBook with Apple Silicon using RVM fails. Digging into the logs, I discovered the culprit: Ruby doesn’t yet support OpenSSL 3, which is installed by default via Homebrew on newer systems along the older version.
The Solution
To resolve this issue, you need to explicitly configure Ruby to use OpenSSL 1.1 during installation. Thankfully, RVM makes this straightforward with a special flag.
Here’s the command that worked for me:
rvm install ruby-3.2.2 --with-openssl-dir=/opt/homebrew/opt/openssl@1.1/
This command tells RVM to use OpenSSL 1.1 from Homebrew’s directory, bypassing the default OpenSSL 3.
End of transmission! :D