加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

ruby-on-rails – 安装eventmachine(1.0.3)时发生错误,Bundler无

发布时间:2020-12-17 04:02:26 所属栏目:百科 来源:网络整理
导读:我试图在我的运行os x 10.10的mac上设置 ruby on rails.我试图让服务器运行开源项目kandan但是当我尝试在eventmachine 1.0.3 gem上捆绑安装时遇到错误.我不确定我到底在看什么,有人可以帮我解决这个问题吗? bundle installFetching gem metadata from https
我试图在我的运行os x 10.10的mac上设置 ruby on rails.我试图让服务器运行开源项目kandan但是当我尝试在eventmachine 1.0.3 gem上捆绑安装时遇到错误.我不确定我到底在看什么,有人可以帮我解决这个问题吗?

bundle install
Fetching gem metadata from https://rubygems.org/.............
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Using rake 10.4.2
Using i18n 0.6.11
Using multi_json 1.10.1
Using activesupport 3.2.21
Using builder 3.0.4
Using activemodel 3.2.21
Using erubis 2.7.0
Using journey 1.0.4
Using rack 1.4.5
Using rack-cache 1.2
Using rack-test 0.6.2
Using hike 1.2.3
Using tilt 1.4.1
Using sprockets 2.2.3
Using actionpack 3.2.21
Using mime-types 1.25.1
Using polyglot 0.3.5
Using treetop 1.4.15
Using mail 2.5.4
Using actionmailer 3.2.21
Using arel 3.0.3
Using tzinfo 0.3.42
Using activerecord 3.2.21
Using activeresource 3.2.21
Using addressable 2.3.6
Using awesome_print 1.2.0
Using json 1.8.1
Using mini_portile 0.5.3
Using nokogiri 1.6.1
Using uuidtools 2.1.4
Using aws-sdk 1.38.0
Using bcrypt 3.1.7
Using coderay 1.1.0
Using better_errors 1.1.0
Using debug_inspector 0.0.2
Using binding_of_caller 0.7.2
Using sass 3.2.13
Using bootstrap-sass 3.1.1.0
Using thor 0.19.1
Using bourbon 3.1.8
Using columnize 0.8.9
Using debugger-linecache 1.2.0
Using byebug 3.2.0
Using cancancan 1.9.2
Using xpath 2.0.0
Using capybara 2.4.4
Using hitimes 1.2.2
Using timers 4.0.1
Using celluloid 0.16.0
Using ffi 1.9.6
Using childprocess 0.5.5
Using climate_control 0.0.3
Using cliver 0.3.2
Using cocaine 0.5.4
Using coffee-script-source 1.7.0
Using execjs 2.0.2
Using coffee-script 2.2.0
Using rack-ssl 1.3.4
Using rdoc 3.12.2
Using railties 3.2.21
Using coffee-rails 3.2.2
Using cookiejar 0.3.2
Using rest-client 1.6.7
Using docile 1.1.3
Using simplecov-html 0.8.0
Using simplecov 0.8.2
Using tins 1.1.0
Using term-ansicolor 1.3.0
Using coveralls 0.7.0
Using daemons 1.1.9
Using database_cleaner 1.2.0
Using orm_adapter 0.5.0
Using thread_safe 0.3.3
Using warden 1.2.3
Using devise 3.2.4
Using diff-lcs 1.2.5
Using eco-source 1.1.0.rc.1
Using eco 1.0.0
Installing eventmachine 1.0.3 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /Users/dan/.rbenv/versions/2.2.2/bin/ruby -r ./siteconf20150808-95277-1j9ketn.rb extconf.rb
checking for rb_trap_immediate in ruby.h,rubysig.h... no
checking for rb_thread_blocking_region()... no
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_wait_for_single_fd()... yes
checking for rb_enable_interrupt()... no
checking for rb_time_new()... yes
checking for sys/event.h... yes
checking for sys/queue.h... yes
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
compiling binder.cpp
compiling cmain.cpp
compiling ed.cpp
compiling em.cpp
em.cpp:827:9: error: use of undeclared identifier 'rb_thread_select'; did you mean 'rb_thread_fd_select'?
        return EmSelect (maxsocket+1,&fdreads,&fdwrites,&fderrors,&tv);
               ^~~~~~~~
               rb_thread_fd_select
./em.h:25:20: note: expanded from macro 'EmSelect'
  #define EmSelect rb_thread_select
                   ^
/Users/dan/.rbenv/versions/2.2.2/include/ruby-2.2.0/ruby/intern.h:454:5: note: 'rb_thread_fd_select' declared here
int rb_thread_fd_select(int,rb_fdset_t *,struct timeval *);
    ^
em.cpp:827:32: error: cannot initialize a parameter of type 'rb_fdset_t *' with an rvalue of type 'fd_set *'
        return EmSelect (maxsocket+1,&tv);
                                      ^~~~~~~~
/Users/dan/.rbenv/versions/2.2.2/include/ruby-2.2.0/ruby/intern.h:454:42: note: passing argument to parameter here
int rb_thread_fd_select(int,struct timeval *);
                                         ^
em.cpp:946:6: error: use of undeclared identifier 'rb_thread_select'; did you mean 'rb_thread_fd_select'?
                                        EmSelect (0,NULL,&tv);
                                        ^~~~~~~~
                                        rb_thread_fd_select
./em.h:25:20: note: expanded from macro 'EmSelect'
  #define EmSelect rb_thread_select
                   ^
/Users/dan/.rbenv/versions/2.2.2/include/ruby-2.2.0/ruby/intern.h:454:5: note: 'rb_thread_fd_select' declared here
int rb_thread_fd_select(int,struct timeval *);
    ^
3 errors generated.
make: *** [em.o] Error 1

make failed,exit code 2

Gem files will remain installed in /Users/dan/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/eventmachine-1.0.3 for inspection.
Results logged to /Users/dan/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-14/2.2.0-static/eventmachine-1.0.3/gem_make.out
An error occurred while installing eventmachine (1.0.3),and Bundler cannot
continue.
Make sure that `gem install eventmachine -v '1.0.3'` succeeds before bundling.

解决方法

Eventmachine 1.0.3与Ruby 2.2不兼容,尝试升级到更新版本.

阅读CHANGELOG:你应该至少升级到1.0.4:https://github.com/eventmachine/eventmachine/blob/master/CHANGELOG.md#104-december-19-2014

fix build on ruby 2.2 [#503]

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读