Ruby 2.4.10 のインストール中に「__rvm_make -j8」の実行中にエラーが発生する
概要
私が使用している Ruby 2.4.10 コマンドをインストールするのを手伝ってください。
rvm install ruby-2.4.10
macOS に Ruby 2.4.10 をインストールしようとすると、次のエラーが発生します。
Error running '__rvm_make -j8',
please read /usr/local/rvm/log/1692528113_ruby-2.4.10/make.log
There has been an error while running make. Halting the installation.
make.log ファイルのログは次のとおりです。
../.././include/ruby/ruby.h:1753:24: note: expanded from macro 'rb_intern'
__extension__ (RUBY_CONST_ID_CACHE((ID), (str))) : \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../.././include/ruby/ruby.h:1743:5: note: expanded from macro 'RUBY_CONST_ID_CACHE'
}
^
closure.c:136:29: note: ')' token is here
ret = rb_funcall2(self, rb_intern("call"), argc, RARRAY_CONST_PTR(params));
^~~~~~~~~~~~~~~~~
../.././include/ruby/ruby.h:1753:56: note: expanded from macro 'rb_intern'
__extension__ (RUBY_CONST_ID_CACHE((ID), (str))) : \
^
closure.c:263:14: error: call to undeclared function 'ffi_prep_closure'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
result = ffi_prep_closure(pcl, cif, callback, (void *)self);
^
6 warnings and 1 error generated.
make[2]: *** [closure.o] Error 1
make[1]: *** [ext/fiddle/all] Error 2
make: *** [build-ext] Error 2
++ return 2
Ruby 2.4.10のインストールを手伝ってください。 私が使用したコマンド:rvm install Ruby-2.4.10
解決策
今後の参考のために、誰かが RVM で同様の問題に直面している場合は、brew を使用して openssl@3 をアンインストールし、代わりに [email protected] をインストールしてください。