我正在尝试使用 RVM 安装 Ruby(最终是 Rails)。这是我收到的错误消息:
Error running 'env LDFLAGS=-L/opt/sm/pkg/active/lib CFLAGS=-I/opt/sm/pkg/active/include CPATH=/opt/sm/pkg/active/include ./configure --disable-install-doc --prefix=/Users/Mayank/.rvm/rubies/ruby-1.9.3-p374 --with-opt-dir=/Users/Mayank/.rvm/usr --disable-shared', please read /Users/Mayank/.rvm/log/ruby-1.9.3-p374/configure.log
There has been an error while running configure. Halting the installation.
这是configure.log:
[2013-01-31 00:13:22] ./configure
checking build system type... x86_64-apple-darwin12.2.0
checking host system type... x86_64-apple-darwin12.2.0
checking target system type... x86_64-apple-darwin12.2.0
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
我跑了
export CC=/usr/local/bin/gcc-4.2
并验证那里有一个 gcc-4.2。
RVM 总是进入“配置”阶段,然后似乎进入一个循环,bash 和 env 交替显示在终端窗口的顶部。
我尝试重新运行 RailsInstaller,但没有做任何事情。
这一切的开始是因为
heroku db:push
1.9.3 不支持并且 1.9.2 未安装。
我什至不知道如何搜索这样的错误,但我已经尝试了所有对其他人有用的方法。
编辑。我刚刚运行了rvm debug并得到了这个:
ruby-1.9.3-p374:
/Users/Mayank/.rvm/bin/ruby: line 6: /Users/Mayank/.rvm/bin/ruby: Argument list too long
/Users/Mayank/.rvm/bin/ruby: line 6: /Users/Mayank/.rvm/bin/ruby: Undefined error: 0