ruby - OS X下安裝EventMachine報錯:cc1plus: error: unrecognized command line option "-arch"
ringa_lee
ringa_lee 2017-04-21 11:15:29
0
1
926

這個是我在SO上的提問,可以去看一下。

過程:

sudo gem install eventmachine

...

Building native extensions.  This could take a while...
/Users/kuankuan/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/rubygems/ext/builder.rb:48: warning: Insecure world writable dir /usr/local/bin/g4bin in PATH, mode 040777
ERROR:  Error installing eventmachine:
    ERROR: Failed to build gem native extension.

        /Users/kuankuan/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb
/Users/kuankuan/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:1344: warning: Insecure world writable dir /usr/local/bin/g4bin in PATH, mode 040777
checking for rb_trap_immediate in ruby.h,rubysig.h... no
checking for rb_thread_blocking_region()... yes
checking for inotify_init() in sys/inotify.h... no
checking for __NR_inotify_init in sys/syscall.h... no
checking for writev() in sys/uio.h... yes
checking for rb_thread_check_ints()... yes
checking for rb_time_new()... yes
checking for sys/event.h... yes
checking for sys/queue.h... yes
creating Makefile

make
compiling binder.cpp
cc1plus: error: unrecognized command line option "-arch"
make: *** [binder.o] Error 1

ruby版本:1.9.3 Mac OSX 10.8.3

ringa_lee
ringa_lee

ringa_lee

全部回覆(1)
黄舟

汗,我和你同樣的機器同樣的配置一條命令就1秒鐘就裝好了。這個好難回答。你的xcode版本多少,commandline升級了沒?一般mac下ruby環境出錯會跟這個有關。 。

熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板