TaKO8Ki / frum

A little bit fast and modern Ruby version manager written in Rust
MIT License
628 stars 15 forks source link

fixing OpenSSL errors #105

Closed dechimp closed 2 years ago

dechimp commented 2 years ago

OpenSSL 3 was just released. However installing ruby with it does not work.

The solution I found was installing ruby with specifying an older version of openssl:

frum install 3.0.2 --with-openssl-dir=`brew --prefix openssl@1.1`

lots of similar tips in this rvm thread https://github.com/rvm/rvm/issues/4562

muz3 commented 2 years ago

hopefully it will support openssl@3 soon

x1wins commented 10 months ago

But sometime it was not working with --with-openssl-dir=`brew --prefix openssl@1.1

I found solution https://gist.github.com/josephrexme/428c6c3a578728bb83d0cea379cb2660 I change path of openssl@1.1 in .zprofile

brew --prefix openssl@1.1 # Check path of openssl@1.1
/opt/homebrew/opt/openssl@1.1
vim ~/.zprofile
export LDFLAGS="-L/opt/homebrew/opt/openssl@1.1/lib"
export CPPFLAGS="-I/opt/homebrew/opt/openssl@1.1/include"
export PKG_CONFIG_PATH="/opt/homebrew/opt/openssl@1.1/lib/pkgconfig"
export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$(brew --prefix openssl@1.1)"
source ~/.zprofile
exit

Restart terminal Because bundler will do not working.

frum install 3.0.4 --with-openssl-dir=$(brew --prefix openssl@1.1)
gem install 2.3.14
bundle install