2014-09-20 78 views
0

让我在这里疯狂。我无法安装bson_ext gem。我使用的RubyInstaller和DevKit安装得非常干净。无法安装bson_ext gem,但其他宝石安装正常

C:\DevKit>gem install bson_ext 
Temporarily enhancing PATH to include DevKit... 
Building native extensions. This could take a while... 
ERROR: Error installing bson_ext: 
     ERROR: Failed to build gem native extension. 

     C:/Ruby193/bin/ruby.exe extconf.rb 
checking for asprintf()... no 
checking for ruby/st.h... yes 
checking for ruby/regex.h... yes 
checking for ruby/encoding.h... yes 
creating Makefile 

make 
generating cbson-i386-mingw32.def 
compiling bson_buffer.c 
compiling cbson.c 
cbson.c:25:23: fatal error: arpa/inet.h: No such file or directory 
compilation terminated. 
make: *** [cbson.o] Error 1 


Gem files will remain installed in C:/Ruby193/lib/ruby/gems/1.9.1/gems/bson_ext- 
1.11.1 for inspection. 
Results logged to C:/Ruby193/lib/ruby/gems/1.9.1/gems/bson_ext-1.11.1/ext/cbson/ 
gem_make.out 

回答

0

这不再是一个问题,使用Ruby 2.1

2

好的,我得到了我的工作。

在为了试试这个,我做到了:

删除的基本文件宝石(下\ LIB \红宝石) 重新安装除蒙戈和bson_ext 运行命令“创业板安装蒙戈-v = 1.9所有其他宝石“ 运行命令‘创业板安装bson_ext -v = 1.9.2’

现在,尝试运行命令,看看它是否适用于雅

+0

对不起 - 哪个文件我删除?我只在\ lib \ ruby​​下看到四个子文件夹(它们是1.9.1,gems,site_ruby和vendor_ruby) – Phil 2014-09-23 01:05:25

+0

幸运的是,这看起来不再是Ruby 2.1的问题 – Phil 2015-06-11 15:15:09