【发布时间】:2011-09-06 13:04:39
【问题描述】:
我正在尝试在我的 Debian 机器上安装遏制 gem,但我很难使用本机扩展构建 gem。我正在使用 RVM。
只是我正在使用的东西的列表:
- debian
- 捆绑器
- rvm
- ruby-1.9.2-p180
- 路边
有人告诉我必须安装以下软件包,我已经这样做了:
sudo apt-get install libcurl3 libcurl3-gnutls libcurl4-openssl-dev
当我继续这样做时:
gem 安装路边
Building native extensions. This could take a while...
ERROR: Error installing curb:
ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-1.9.2-p180/bin/ruby extconf.rb
正在检查 curl-config... 是 检查 curlinfo_redirect_time... * extconf.rb 失败 * 由于某种原因无法创建 Makefile,可能缺少 必要的库和/或头文件。查看 mkmf.log 文件了解更多信息 细节。您可能需要配置选项。
提供的配置选项:
--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
--没有-make-prog
--srcdir=。
--curdir
--ruby=/usr/local/rvm/rubies/ruby-1.9.2-p180/bin/ruby
--with-curl-dir
--with-curl-include
--without-curl-include=${curl-dir}/include
--with-curl-lib
--without-curl-lib=${curl-dir}/lib
/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:368:in try_do': The complier failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:446:intry_compile'
来自 extconf.rb:51:in block in have_constant'
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:693:inblock in checks_for'
来自 /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:280:in block (2 levels) in postpone'
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:254:inopen'
来自 /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:280:in block in postpone'
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:254:inopen'
来自 /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:276:in postpone'
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/mkmf.rb:692:inchecking_for'
来自 extconf.rb:43:in have_constant'
from extconf.rb:60:in'
我没有办法解决这个问题,有什么想法吗?
谢谢各位。
【问题讨论】:
-
我在 OSX 上使用 rvm 针对 libcurl 安装了类似的问题,该 libcurl 以前与我自己安装的 ruby 和遏制一起使用。你找到解决办法了吗?
-
在 Mountain Lion (OSX 10.8) 上遇到同样的问题。我有两次安装,在 iMac 上工作在 MBA 上失败,我还看不出任何差异。