ruby-debug 由于某种原因无法创建 Makefile,可能缺少必要的库和/或头文件 [英] ruby-debug Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers

查看:56
本文介绍了ruby-debug 由于某种原因无法创建 Makefile,可能缺少必要的库和/或头文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的 Rails 是 3.2.1.4,Ruby 是 1.9.3p448.

My Rails is 3.2.1.4, Ruby is 1.9.3p448.

我在安装 ruby-debug 时遇到错误:

I got an error when I install ruby-debug:

Building native extensions.  This could take a while...
ERROR:  Error installing ruby-debug:
        ERROR: Failed to build gem native extension.

    /home/hxh/.rvm/rubies/ruby-1.9.3-p448/bin/ruby extconf.rb
Can't handle 1.9.x yet
*** 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=/home/hxh/.rvm/rubies/ruby-1.9.3-p448/bin/ruby


Gem files will remain installed in /home/hxh/.rvm/gems/ruby-1.9.3-p448/gems/linecache-0.46 for inspection.
Results logged to /home/hxh/.rvm/gems/ruby-1.9.3-p448/gems/linecache-0.46/ext/gem_make.out

谁能告诉我错误在哪里?

Who can tell me where the error is?

推荐答案

错误在 mkmf.log 文件中.该文件应位于 /home/hxh/.rvm/gems/ruby-1.9.3-p448/gems/linecache-0.46/ext/linecache/mkmf.log.

The error is in the mkmf.log file. That file should be located at /home/hxh/.rvm/gems/ruby-1.9.3-p448/gems/linecache-0.46/ext/linecache/mkmf.log.

如果没有,你可以使用

sudo find / -name mkmf.log

找到它.

要进一步排除故障,请参阅​​如何使用 mkmf.log 安装 Nokogiri Ruby gem 说找不到 libiconv?"

To troubleshoot further, see "How to install Nokogiri Ruby gem with mkmf.log saying libiconv not found?"

这篇关于ruby-debug 由于某种原因无法创建 Makefile,可能缺少必要的库和/或头文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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