2011-12-18 10 views
2

rb-appscriptをインストールする際に大きな問題が発生しました。 私はxCodeの最新バージョンをすでにインストールしています&私はLionを使っています。rb-appscriptをインストール中にエラーが発生しました

あなたが私に助けてくれることを願っています。ありがとうございました!

これはエラーメッセージです:何かがあなたのRubyがインストールに問題があるよう

sudo gem install rb-appscript 
Building native extensions. This could take a while... 
ERROR: Error installing rb-appscript: 
    ERROR: Failed to build gem native extension. 

     /usr/local/bin/ruby extconf.rb 
create /usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1/src/osx_ruby.h ... 
create /usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1/src/osx_intern.h ... 
creating Makefile 

make 
Makefile:188: warning: overriding commands for target `/usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1/lib' 
Makefile:182: warning: ignoring old commands for target `/usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1/lib' 
gcc -I. -I/usr/local/lib/ruby/1.8/i686-darwin9.7.0 -I/usr/local/lib/ruby/1.8/i686-darwin9.7.0 -Isrc -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -fno-common -D_XOPEN_SOURCE=1 -fno-common -pipe -fno-common -Wall -c src/rbae.c 
gcc -I. -I/usr/local/lib/ruby/1.8/i686-darwin9.7.0 -I/usr/local/lib/ruby/1.8/i686-darwin9.7.0 -Isrc -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -fno-common -D_XOPEN_SOURCE=1 -fno-common -pipe -fno-common -Wall -c src/SendThreadSafe.c 
cc -dynamic -bundle -undefined suppress -flat_namespace -o ae.bundle rbae.o SendThreadSafe.o -L. -L/usr/local/lib -L. -framework Carbon -framework ApplicationServices -lruby -lpthread -ldl -lobjc 
ld: warning: ignoring file /usr/local/lib/libruby.dylib, file was built for unsupported file format which is not the architecture being linked (x86_64) 
ld: in /usr/local/lib/libxml2.2.dylib, file was built for unsupported file format which is not the architecture being linked (x86_64) for architecture x86_64 
collect2: ld returned 1 exit status 
make: *** [ae.bundle] Error 1 


Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1 for inspection. 
Results logged to /usr/local/lib/ruby/gems/1.8/gems/rb-appscript-0.6.1/./gem_make.out 

答えて

0

は思えます。ここで間違ったアーキテクチャについて文句を言う

ld: warning: ignoring file /usr/local/lib/libruby.dylib, file was built for unsupported file format which is not the architecture being linked (x86_64) 
ld: in /usr/local/lib/libxml2.2.dylib, file was built for unsupported file format which is not the architecture being linked (x86_64) for architecture x86_64 

ルビが正しくインストールされていることを確認してください。 Rubyのインストールは非常に簡単ですが、Ruby Version Managerをお勧めします - >https://rvm.io

+0

ありがとうございました! "$ bash <<(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)"というコマンドを使ってこれを試してみました。インストールが正常に終了したら、rb-appscriptコマンドをもう一度実行してみました。問題は私のxCodeから来る可能性はありますか? (4.2.1がインストールされています)< - どこかで読んだら、これはルビーに問題があるかもしれませんか?どのようにそれを修正するための任意のアイデア? – Tobias

+0

"osx-gcc-installer"は私の問題を解決できましたか?ちょうどそれを見つけた... – Tobias

+0

私はOSXではないので、それを助けることはできません。あなたはrvmによってインストールされたルビーバージョンを使用していますか? 'rvm install 1.8.7'と 'rvm 1.8.7'を試して、すべてが正しく機能するかどうか確認してください。 – ben

関連する問題