在尝试安装nio4r gem时。我试过了
gem install nio4r -v '1.0.0'弹出的错误是:
Building native extensions. This could take a while...
ERROR: Error installing nio4r:
ERROR: Failed to build gem native extension.
/.rvm/rubies/ruby-2.2.1/bin/ruby -r ./siteconf20150406-11564-1qtifmf.rb extconf.rb
checking for rb_thread_blocking_region()... no
checking for sys/select.h... yes
checking for poll.h... yes
checking for sys/epoll.h... no
checking for sys/event.h... yes
checking for sys/queue.h... yes
checking for port.h... no
checking for sys/resource.h... yes
creating Makefile
make "DESTDIR=" clean
make "DESTDIR="
compiling monitor.c
In file included from monitor.c:6:
In file included from ./nio4r.h:10:
/.rvm/rubies/ruby-2.2.1/include/ruby-2.2.0/ruby/backward/rubyio.h:2:2: warning: use "ruby/io.h" instead of "rubyio.h" [-W#warnings]
warning use "ruby/io.h" instead of "rubyio.h"
...我做错什么了?我的RVM有问题吗?
发布于 2015-04-07 09:44:16
有了一些基本的更新,我才能让它开始工作。
bundle update
然后
bundle
安装宝石。
多亏了https://github.com/celluloid/nio4r/issues/46
另一种方法是使用RVM安装更高版本的ruby并再次执行bundle。这两种方法都很有效
https://stackoverflow.com/questions/29476596
复制相似问题