安装http_parser.rb时错误:无法生成gem本机扩展 [英] While installing http_parser.rb ERROR: Failed to build gem native extension

查看:32
本文介绍了安装http_parser.rb时错误:无法生成gem本机扩展的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的新手,但是当我尝试使用gem安装http_parser时出现此错误:

i'm new to all of this but i get this error when i try to install http_parser using gem:

dongl_000@LENNY ~/ava-home (master)
$ gem install http_parser.rb -v '0.6.0'
Building native extensions.  This could take a while...
ERROR:  Error installing http_parser.rb:
        ERROR: Failed to build gem native extension.

    c:/Ruby22-x64/bin/ruby.exe -r ./siteconf20160217-15056-1hoiyfc.rb extconf.rb

creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
generating ruby_http_parser-x64-mingw32.def
make: *** No rule to make target '/c/Ruby22-x64/include/ruby-2.2.0/ruby.h', need
ed by 'ruby_http_parser.o'.  Stop.

make failed, exit code 2

Gem files will remain installed in c:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/http_p
arser.rb-0.6.0 for inspection.
Results logged to c:/Ruby22-x64/lib/ruby/gems/2.2.0/extensions/x64-mingw32/2.2.0
/http_parser.rb-0.6.0/gem_make.out

红宝石版本:2.2.1

ruby version: 2.2.1

ruby​​Gem版本:2.4.5

rubyGem version: 2.4.5

谢谢!

推荐答案

我正在经历同样的问题.

I was going through this very same issue.

查找了Gem的Git信息库(HTTP_Parser),并找出了造成我问题的原因:

Looked up the Git Repository for the Gem (HTTP_Parser) and found out the reason for my problem:

HTTP_Parser当前不支持带空格的路径

所以我重命名了路径并解决了它.

So I renamed my path and solved it.

这篇关于安装http_parser.rb时错误:无法生成gem本机扩展的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆