0

こんにちは、RVM を使用して Ruby 1.9.2 を 1.9.3 にアップグレードしようとしています。これは私がやっていることです:

rvm upgrade 1.9.2
Are you sure you wish to upgrade from ruby-1.9.2-p290 to     ruby-1.9.3-p0? (Y/n): y

次に、次のエラーが表示されます。

Installing new ruby ruby-1.9.3-p0
Installing Ruby from source to: /Users/jeanosorio/.rvm/rubies/ruby-1.9.3-p0, this may take a while depending on your cpu(s)...

ruby-1.9.3-p0 - #fetching 
ruby-1.9.3-p0 - #extracted to /Users/jeanosorio/.rvm/src/ruby-1.9.3-p0 (already extracted)
Fetching yaml-0.1.4.tar.gz to /Users/jeanosorio/.rvm/archives
Extracting yaml-0.1.4.tar.gz to /Users/jeanosorio/.rvm/src
Configuring yaml in /Users/jeanosorio/.rvm/src/yaml-0.1.4.
Compiling yaml in /Users/jeanosorio/.rvm/src/yaml-0.1.4.
Installing yaml to /Users/jeanosorio/.rvm/usr
ruby-1.9.3-p0 - #configuring 
ERROR: Error running ' ./configure --prefix=/Users/jeanosorio/.rvm/rubies/ruby-1.9.3-p0 --enable-shared --disable-install-doc --with-libyaml-dir=/Users/jeanosorio/.rvm/usr ', please read /Users/jeanosorio/.rvm/log/ruby-1.9.3-p0/configure.log
ERROR: There has been an error while running configure. Halting the installation.
ERROR: Unable to install ruby ruby-1.9.3-p0.         Please install it manually to continue.

XCODE 4.2.1 を使用しています。

これはconfigure.logです

[2012-06-20 11:31:41]  ./configure --prefix=/Users/jeanosorio/.rvm/rubies/ruby-1.9.3-p0 --enable-shared --disable-install-doc --with-libyaml-dir=/Users/jeanosorio/.rvm/usr 
configure: WARNING: unrecognized options: --with-libyaml-dir
checking build system type... x86_64-apple-darwin11.4.0
checking host system type... x86_64-apple-darwin11.4.0
checking target system type... x86_64-apple-darwin11.4.0
checking whether the C compiler works... no
configure: error: in `/Users/jeanosorio/.rvm/src/ruby-1.9.3-p0':
configure: error: C compiler cannot create executables
See `config.log' for more details
4

2 に答える 2

1
  1. RVM の更新curl -L get.rvm.io | bash -s stable && rvm reload
  2. osx-gcc-installerをインストールします
  3. 指示を読んで従うrvm requirements
  4. Ruby をインストールします: rvm install 1.9.3

新しいシステムのインストールには、 http://railsinsaler.orgを使用することもできます。

于 2012-06-20T17:24:34.557 に答える
0

Xcode 4.3 にアップグレードしてみてください。クリーン インストールで、1.9.3-p125 を動作させることができました。

それでもうまくいかない場合、RVM にはいくつかのヒントがあります: https://rvm.io/os/osx/

于 2012-06-20T15:49:18.110 に答える