ruby-on-rails - 如何修复 Mavericks 上 Gemfile 的 libv8 错误?

标签 ruby-on-rails ruby gem bundle osx-mavericks

当我运行 bundle install 时,我得到了

An error occurred while installing libv8 (3.11.8.17), and Bundler cannot continue.
Make sure that `gem install libv8 -v '3.11.8.17'` succeeds before bundling.

Libv8 是 lunchytherubyracer gems 的依赖项。

我已经在 3.11.8.17 上锁定了我的 Gemfile.lock libv8 gem

但是我发现我可以降级到3.3.10.4

bundle install / update: libv8 (therubyracer) installation fails (with native extensions)

怎么做?

我还找到了可以工作的 3.11.8.17 gem,但不知道如何在我的系统上实现它。 https://github.com/cowboyd/libv8/issues/107#issuecomment-26146673

最佳答案

您实际上可以在 Mavericks 上安装该版本:

gem install libv8 -v 3.11.8.17 -- --with-system-v8

我可以确认这适用于 rbenv 和 ruby​​ 1.9.3p448

在此处查看类似主题 Installing libv8 gem on OS X 10.9+

关于ruby-on-rails - 如何修复 Mavericks 上 Gemfile 的 libv8 错误?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19568852/

相关文章:

html - 在复选框和单选按钮图像周围显示 1 px 边框

ruby - 在 Ruby 中枚举字符的 Unicode 属性?

ruby - 从现有数据库生成数据映射器模型

javascript - Morris.js 如何为特定类型创建图表

ruby-on-rails - 如何将应用程序布局打包到 Ruby gem 中?

javascript - Rails 4 应用程序不包括 Assets 中的 bootstrap css?

ruby-on-rails - Sqlite3 事件记录 :order => "time DESC" doesn't sort

ruby-on-rails - "stack level too deep"编译 Assets 时

ruby-on-rails - 添加您自己的自定义路线来设计

ruby 在 `gem_original_require' : no such file to load -- CloudyScripts (LoadError)