gpt4 book ai didi

ruby-on-rails -/usr/bin/gcc-4.2 : No such file or directory. 错误。符号链接(symbolic link)修复不起作用

转载 作者:行者123 更新时间:2023-12-03 16:03:53 33 4
gpt4 key购买 nike

我正在尝试升级我的 rails 3.2.3 应用程序。我已将 gemfile 更新为 gem 'rails', '3.2.11'并运行 bundle update rails但出现以下错误:

    Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

/Users/Arel/.rvm/rubies/ruby-1.9.3-head/bin/ruby extconf.rb
creating Makefile

make
compiling generator.c
make: /usr/bin/gcc-4.2: No such file or directory
make: *** [generator.o] Error 1


Gem files will remain installed in /Users/Arel/.rvm/gems/ruby-1.9.3-head/gems/json-1.7.6 for inspection.
Results logged to /Users/Arel/.rvm/gems/ruby-1.9.3-head/gems/json-1.7.6/ext/json/ext/generator/gem_make.out
An error occured while installing json (1.7.6), and Bundler cannot continue.
Make sure that `gem install json -v '1.7.6'` succeeds before bundling.

因此,我尝试了随处可见的解决方案,使用以下命令创建符号链接(symbolic link):
sudo ln -s /usr/bin/gcc /usr/bin/gcc-4.2
但这只是返回错误:
ln: /usr/bin/gcc-4.2: File exists
我不太了解使用终端在 OSX 中导航,所以我在这里有点挣扎。有任何想法吗?

最佳答案

/usr/bin/gcc-4.2可能已经是一个符号链接(symbolic link),但是一个损坏的链接指向一个不存在的文件。

关于ruby-on-rails -/usr/bin/gcc-4.2 : No such file or directory. 错误。符号链接(symbolic link)修复不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14271373/

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