本文介绍了安装 RedCloth-4.2.9 安装 Linux 时无法构建 gem 本机扩展的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在我的电脑上安装 Octopress
.我试着这样做
I want to install Octopress
in my computer.I try to do it like
当我跑步时
bundle install
我收到错误信息
An error occured while installing RedCloth (4.2.9), and Bundler cannot continue.
Make sure that `gem install RedCloth -v '4.2.9'` succeeds before bundling.
所以,我跑
sudo gem install RedCloth -v '4.2.9'
然后,我又收到一条错误消息:
then, I got a error message again:
ERROR: Error installing RedCloth:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- mkmf (LoadError)
from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from extconf.rb:1:in `<main>'
我对 ruby 一无所知.
I hadn't learn any knowledge about ruby.
推荐答案
您可能已升级到 Mountain Lion
并且尚未重建您的 ruby-1.9.2
安装尚未使用新的开发包.
You've probably upgraded to Mountain Lion
and have not rebuilt your ruby-1.9.2
install yet with the new development packages.
rvm --force install 1.9.2
gem install bundle --no-ri --no-rdoc
bundle install
如果您没有正确安装 Mountain Lion
开发包,请使用 ThoughtBot 说明.
If you don't have the Mountain Lion
dev packages installed correctly, use the ThoughtBot instructions.
这篇关于安装 RedCloth-4.2.9 安装 Linux 时无法构建 gem 本机扩展的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!