gpt4 book ai didi

ruby-on-rails - 在 Mac OSX 10.9.4 上安装 Ruby 1.9.3 时遇到问题

转载 作者:太空宇宙 更新时间:2023-11-03 17:05:10 27 4
gpt4 key购买 nike

在终端和命令行方面,我相当业余,因此我想我可以在这里提出我的问题,希望漫游这个论坛的众多聪明人中的一位能帮助我理解我在这里做错了什么.我正在尝试在我的 Mac 上为 Team Treehouse 上的项目安装 1.9.3。我已经安装了 2.0.0。任何帮助都会很棒。谢谢。这是从日志中读出的。

roberts-imac:~ Jones$ rvm install 1.9.3
Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.9/x86_64/ruby-1.9.3-p547.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx.
Error: No available formula for gcc46
Installing requirements for osx.
Updating system.......
Error running 'requirements_osx_brew_update_system ruby-1.9.3-p547',
showing last 15 lines of /Users/Jones/.rvm/log/1404462414_ruby-1.9.3-p547/update_system.log
https://github.com/Homebrew/homebrew/wiki/Common-Issues
and make sure `brew update` works before continuing.'
++ rvm_pretty_print stderr
++ case "${rvm_pretty_print_flag:=auto}" in
++ case "${TERM:-dumb}" in
++ case "$1" in
++ [[ -t 2 ]]
++ return 1
++ printf %b 'Failed to update Homebrew, follow instructions here:
https://github.com/Homebrew/homebrew/wiki/Common-Issues
and make sure `brew update` works before continuing.\n'
Failed to update Homebrew, follow instructions here:
https://github.com/Homebrew/homebrew/wiki/Common-Issues
and make sure `brew update` works before continuing.
++ return 1
Requirements installation failed with status: 1.
roberts-imac:~ Jones$

更新:所以我继续安装 xcode 并运行 brew update,这就是我在尝试安装 1.9.3 后在日志中得到的内容。

Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.9/x86_64/ruby-1.9.3-p547.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx.
Error: No available formula for gcc46
Installing requirements for osx.
Updating system....
Installing required custom packages: homebrew/versions.
Installing required packages: gcc46............
Certificates in '/usr/local/etc/openssl/cert.pem' are already up to date.
Requirements installation successful.
Installing Ruby from source to: /Users/Jones/.rvm/rubies/ruby-1.9.3-p547, this may take a while depending on your cpu(s)...
ruby-1.9.3-p547 - #downloading ruby-1.9.3-p547, 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 9801k 100 9801k 0 0 170k 0 0:00:57 0:00:57 --:--:-- 120k
ruby-1.9.3-p547 - #extracting ruby-1.9.3-p547 to /Users/Jones/.rvm/src/ruby-1.9.3-p547....
ruby-1.9.3-p547 - #applying patch /Users/Jones/.rvm/patches/ruby/GH-488.patch.
ruby-1.9.3-p547 - #configuring.
Error running './configure --prefix=/Users/Jones/.rvm/rubies/ruby-1.9.3-p547 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --without-tcl --without-tk --disable-install-doc --enable-shared',
showing last 15 lines of /Users/Jones/.rvm/log/1404502752_ruby-1.9.3-p547/configure.log
[2014-07-04 13:16:23] ./configure
current path: /Users/Jones/.rvm/src/ruby-1.9.3-p547
GEM_HOME=/Users/Jones/.rvm/gems/ruby-2.1.2
PATH=/usr/local/opt/gcc46/bin:/usr/local/opt/pkg-config/bin:/usr/local/opt/libtool/bin:/usr/local/opt/automake/bin:/usr/local/opt/autoconf/bin:/Users/Jones/.rvm/gems/ruby-2.1.2/bin:/Users/Jones/.rvm/gems/ruby-2.1.2@global/bin:/Users/Jones/.rvm/rubies/ruby-2.1.2/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/Jones/Library/Enthought/Canopy_64bit/User/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/Users/Jones/.rvm/bin
GEM_PATH=/Users/Jones/.rvm/gems/ruby-2.1.2:/Users/Jones/.rvm/gems/ruby-2.1.2@global
command(7): ./configure --prefix=/Users/Jones/.rvm/rubies/ruby-1.9.3-p547 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --without-tcl --without-tk --disable-install-doc --enable-shared
configure: WARNING: unrecognized options: --without-tcl, --without-tk
checking build system type... i386-apple-darwin13.3.0
checking host system type... i386-apple-darwin13.3.0
checking target system type... i386-apple-darwin13.3.0
checking whether the C compiler works... no
configure: error: in `/Users/Jones/.rvm/src/ruby-1.9.3-p547':
configure: error: C compiler cannot create executables
See `config.log' for more details
There has been an error while running configure. Halting the installation.

最佳答案

Error: No available formula for gcc46

尝试:

rvm install 1.9.3 --with-gcc=clang

或者安装xcode:

xcode-select --install

关于ruby-on-rails - 在 Mac OSX 10.9.4 上安装 Ruby 1.9.3 时遇到问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24569954/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com