OS Sierra更新后,配置时RVM安装失败

时间:2016-10-25 10:21:39

标签: rvm macos-sierra

如果我这样做

$rvm install 2.3

我得到了

Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.12/x86_64/ruby-2.3.1.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for smf.
Certificates in '/opt/sm/pkg/versions/openssl/1.0.1c/ssl/cert.pem' are already up to date.
Requirements installation successful.
Installing Ruby from source to: /Users/usernamehere/.rvm/rubies/ruby-2.3.1, this may take a while depending on your cpu(s)...
ruby-2.3.1 - #downloading ruby-2.3.1, this may take a while depending on your connection...
% Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                             Dload  Upload   Total   Spent    Left  Speed
100 13.7M  100 13.7M    0     0  5214k      0  0:00:02  0:00:02 --:--:-- 5304k
ruby-2.3.1 - #extracting ruby-2.3.1 to /Users/usernamehere/.rvm/src/ruby-2.3.1....
ruby-2.3.1 - #configuring..

这就是问题开始的地方

Error running 'env LDFLAGS=-L/opt/sm/pkg/active/lib CFLAGS=-I/opt/sm/pkg/active/include CPATH=/opt/sm/pkg/active/include -L/opt/sm/pkg/active/lib ./configure --prefix=/Users/usernamehere/.rvm/rubies/ruby-2.3.1 --disable-install-doc --enable-shared',
showing last 15 lines of /Users/usernamehere/.rvm/log/1477389363_ruby-2.3.1/configure.log
[2016-10-25 10:56:07] ./configure
current path: /Users/usernamehere/.rvm/src/ruby-2.3.1
PATH=/opt/sm/pkg/active/bin:/usr/local/mysql/bin:/usr/local/rvm/gems/ruby-1.9.3-p194/bin:/usr/local/rvm/gems/ruby-1.9.3-p194@global/bin:/usr/local/rvm/rubies/ruby-1.9.3-p194/bin:/usr/local/rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/MacGPG2/bin:/opt/sm/bin:/opt/sm/pkg/active/sbin:/Users/usernamehere/.rvm/bin
GEM_PATH=/usr/local/rvm/gems/ruby-1.9.3-p194:/usr/local/rvm/gems/ruby-1.9.3-p194@global
command(6): env LDFLAGS=-L/opt/sm/pkg/active/lib CFLAGS=-I/opt/sm/pkg/active/include CPATH=/opt/sm/pkg/active/include -L/opt/sm/pkg/active/lib ./configure --prefix=/Users/usernamehere/.rvm/rubies/ruby-2.3.1 --disable-install-doc --enable-shared
checking for ruby... /usr/local/rvm/rubies/ruby-1.9.3-p194/bin/ruby
config.guess already exists
config.sub already exists
checking build system type... x86_64-apple-darwin16.0.0
checking host system type... x86_64-apple-darwin16.0.0
checking target system type... x86_64-apple-darwin16.0.0
checking whether the C compiler works... no
configure: error: in `/Users/usernamehere/.rvm/src/ruby-2.3.1':
configure: error: C compiler cannot create executables

我安装了一个编译器并在

工作
$ which gcc 
/usr/bin/gcc

0 个答案:

没有答案