17

每次我进行捆绑安装时,我似乎都无法使用我的应用程序安装 kgio。我得到这个错误!谁能帮我?我已经尝试过 5 次重新捆绑。

C:/RailsInstaller/Ruby1.9.3/bin/ruby.exe extconf.rb
    checking for CLOCK_MONOTONIC in time.h... no
    checking for CLOCK_MONOTONIC() in time.h... no
    checking for clockid_t in time.h... no
    checking for clock_gettime() in -lrt... no
    checking for t_open() in -lnsl... no
    checking for socket() in -lsocket... no
    checking for poll() in poll.h... no
    checking for getaddrinfo() in sys/types.h,sys/socket.h,netdb.h... no
    getaddrinfo required
    *** extconf.rb failed ***
    Could not create Makefile due to some reason, probably lack of
    necessary libraries and/or headers.  Check the mkmf.log file for more
    details.  You may need configuration options.

    Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=C:/RailsInstaller/Ruby1.9.3/bin/ruby
        --with-rtlib
        --without-rtlib
        --with-nsllib
        --without-nsllib
        --with-socketlib
        --without-socketlib
4

2 回答 2

26

实际上,答案是你不能在 windows 上使用 kgio。在找到答案之前,我花了 3 个小时来研究另一个答案。根据开发人员的说法,Kgio 需要一个类似 unix 的环境。

于 2013-03-17T04:45:30.440 回答
9

您可能缺少必需的库。

同样来自RubyInstaller Wiki

此失败是由于本机 gem 编译/安装过程使用 libiconv-2.dll 版本而不是集成到 DevKit 中的版本,因为 Windows 如何搜索 DLL

这可以通过在您的计算机上搜索文件 libiconv-2.dll 并重命名、删除或以其他方式移动任何找到的实例并重新运行本机 gem 安装过程或在您的情况下是 Bundle Install 来解决

建议如果您不知道将 libiconv-2.dll 文件放在找到它的目录中的原因或原因,则在编译所需的任何 gem 后将其移回。这可能会阻止其他应用程序中断。

编辑

kgio gem 仅在类 Unix 系统 ( http://bogomips.org/kgio/ ) 上构建和运行,它使用 Windows 本身不可用的功能。

如果您尝试使用 Unicorn,则只需更换网络服务器。

试试瘦。将以下行添加到您的 Gemfile:

gem 'thin'
于 2013-01-23T15:35:26.143 回答