Skip to content

Instantly share code, notes, and snippets.

@ck3g
Last active January 2, 2020 19:07
Show Gist options
  • Save ck3g/8d1760aec42027e805258cc0f40beec0 to your computer and use it in GitHub Desktop.
Save ck3g/8d1760aec42027e805258cc0f40beec0 to your computer and use it in GitHub Desktop.
Installing Ruby gems on macOS

Some gems have issues installing on macOS. There is a list of possible solutions.

mysql2

https://gist.github.com/fernandoaleman/ee3ac6957c2ba4f7d7d33a251d58b191

brew install openssl
gem install mysql2 -v '0.5.2' -- --with-ldflags=-L/usr/local/opt/openssl/lib --with-cppflags=-I/usr/local/opt/openssl/include

ffi

ffi/ffi#342 (comment)

brew link libffi --force

therubyracer

brew install v8-315
gem install libv8 -v '3.16.14.19' -- --with-system-v8
gem install therubyracer -- --with-v8-dir=/usr/local/opt/v8@3.15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment