Как мне установить ruby ​​с rvm на Mac без этой ошибки? - PullRequest
1 голос
/ 08 ноября 2019

Я пытаюсь установить Ruby с помощью rvm, но постоянно получаю сообщение об ошибке.

$ rvm install ruby

Я бы хотел, чтобы ruby ​​установился идеально. Вместо этого я получаю следующее сообщение об ошибке:

Warning, new version of rvm available '1.29.9', you are using older version '1.29.9-next'.
You can disable this warning with:   echo rvm_autoupdate_flag=0 >> ~/.rvmrc
You can enable auto-update with:     echo rvm_autoupdate_flag=2 >> ~/.rvmrc
You can update manually with:        rvm get VERSION                         (e.g. 'rvm get stable')

ruby-2.6.5 - #removing src/ruby-2.6.5..
Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.14/x86_64/ruby-2.6.5.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx.
We don't know how to ensure that selected compiler 'x86_64-apple-darwin13.4.0-clang' exists.
Certificates bundle '/usr/local/etc/openssl@1.1/cert.pem' is already up to date.
Requirements installation successful.
Warning: found user selected compiler 'x86_64-apple-darwin13.4.0-clang', this will suppress RVM auto detection mechanisms.
Installing Ruby from source to: /Users/simonthompson/.rvm/rubies/ruby-2.6.5, this may take a while depending on your cpu(s)...
ruby-2.6.5 - #downloading ruby-2.6.5, this may take a while depending on your connection...
ruby-2.6.5 - #extracting ruby-2.6.5 to /Users/simonthompson/.rvm/src/ruby-2.6..|
ruby-2.6.5 - #configuring..
Error running './configure --prefix=/Users/simonthompson/.rvm/rubies/ruby-2.6.5 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/libksba:/usr/local/opt/readline:/usr/local/opt/zlib:/usr/local/opt/openssl@1.1 --disable-install-doc --enable-shared',
please read /Users/simonthompson/.rvm/log/1573168940_ruby-2.6.5/configure.log
There has been an error while running configure. Halting the installation.

Когда я проверяю рассматриваемый файл configure.log, я вижу следующее:

[2019-11-08 07:22:55] ./configure
current path: /Users/simonthompson/.rvm/src/ruby-2.6.5
PATH=/usr/local/opt/coreutils/bin:/usr/local/opt/pkg-config/bin:/usr/local/opt/libtool/bin:/usr/local/opt/automake/bin:/usr/local/opt/autoconf/bin:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/Users/simonthompson/.rbenv/shims:/anaconda3/bin:/anaconda3/condabin:/Library/Frameworks/Python.framework/Versions/3.7/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/simonthompson/.rvm/bin
command(5): ./configure --prefix=/Users/simonthompson/.rvm/rubies/ruby-2.6.5 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/libksba:/usr/local/opt/readline:/usr/local/opt/zlib:/usr/local/opt/openssl@1.1 --disable-install-doc --enable-shared
checking for ruby... /usr/bin/ruby
tool/config.guess already exists
tool/config.sub already exists
checking build system type... x86_64-apple-darwin18.0.0
checking host system type... x86_64-apple-darwin18.0.0
checking target system type... x86_64-apple-darwin18.0.0
checking whether the C compiler works... no
configure: error: in `/Users/simonthompson/.rvm/src/ruby-2.6.5':
configure: error: C compiler cannot create executables
See `config.log' for more details
...