我正在使用ruby 2.0.0p353(2013-11-22修订版43784)[x86_64-darwin12.5.0]
当我尝试运行bundle install
时,我得到以下输出:
Fetching gem metadata from https://rubygems.org/.........
Fetching additional metadata from https://rubygems.org/..
Resolving dependencies...
Using rake (10.1.1)
Using i18n (0.6.9)
Using minitest (4.7.5)
Using multi_json (1.8.4)
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/Users/jchirag/.rvm/rubies/ruby-2.0.0-p353/bin/ruby extconf.rb
creating Makefile
make
compiling atomic_reference.c
atomic_reference.c:53:9: warning: implicit declaration of function 'OSAtomicCompareAndSwap64' is invalid in C99 [-Wimplicit-function-declaration]
if (OSAtomicCompareAndSwap64(expect_value, new_value, &DATA_PTR(self))) {
^
1 warning generated.
linking shared-object atomic_reference.bundle
make install
/usr/bin/install -c -m 0755 atomic_reference.bundle ./.gem.20140205-2120-t32ean
Script: on: No such file or directory
Script started, output file is started
Script done, output file is started
/usr/bin/install: line 2: script:: command not found
Script: on: No such file or directory
Script started, output file is done
Script done, output file is done
make: *** [install-so] Error 15
Gem files will remain installed in /Users/jchirag/.rvm/gems/ruby-2.0.0-p353@railstutorial_rails_4_0/gems/atomic-1.1.14 for inspection.
Results logged to /Users/jchirag/.rvm/gems/ruby-2.0.0-p353@railstutorial_rails_4_0/gems/atomic-1.1.14/ext/gem_make.out
An error occurred while installing atomic (1.1.14), and Bundler cannot continue.
Make sure that `gem install atomic -v '1.1.14'` succeeds before bundling.
when I try to run gem install atomic -v '1.1.14' I get the following:
Building native extensions. This could take a while...
ERROR: Error installing atomic:
ERROR: Failed to build gem native extension.
/Users/jchirag/.rvm/rubies/ruby-2.0.0-p353/bin/ruby extconf.rb
creating Makefile
make
compiling atomic_reference.c
atomic_reference.c:53:9: warning: implicit declaration of function 'OSAtomicCompareAndSwap64' is invalid in C99 [-Wimplicit-function-declaration]
if (OSAtomicCompareAndSwap64(expect_value, new_value, &DATA_PTR(self))) {
^
1 warning generated.
linking shared-object atomic_reference.bundle
make install
/usr/bin/install -c -m 0755 atomic_reference.bundle ./.gem.20140205-2359-wp4uhi
Script: on: No such file or directory
Script started, output file is started
Script done, output file is started
/usr/bin/install: line 2: script:: command not found
Script: on: No such file or directory
Script started, output file is done
Script done, output file is done
make: *** [install-so] Error 15
Gem files will remain installed in /Users/jchirag/.rvm/gems/ruby-2.0.0-p353@railstutorial_rails_4_0/gems/atomic-1.1.14 for inspection.
Results logged to /Users/jchirag/.rvm/gems/ruby-2.0.0-p353@railstutorial_rails_4_0/gems/atomic-1.1.14/ext/gem_make.out
s
我已经执行了sudo gem update --system
我正在使用mac osx 10.8.5,我已经将我的xcode更新为最新版本。
任何线索都将受到高度赞赏。谢谢。
答案 0 :(得分:0)
对于类似的问题,我只需运行以下内容并按照提示进行操作
xcode-select --install