【问题标题】:unable to install therubyracer arm chromebook无法安装 therubyracer arm chromebook
【发布时间】:2013-05-16 10:51:46
【问题描述】:

尝试安装 therubyracer gem 后出现以下错误。

当我已经下载了 gem 时,不知道为什么它抱怨 v8。

我最初在安装 libv8 时遇到了麻烦,但后来设法使用 --system-v8 标志进行安装,但现在它的 ruby​​racer 抱怨。

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

    /home/glenn/.rvm/rubies/ruby-1.9.3-p392/bin/ruby extconf.rb 
checking for main() in -lpthread... yes
checking for v8.h... no
*** 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/glenn/.rvm/rubies/ruby-1.9.3-p392/bin/ruby
    --with-pthreadlib
    --without-pthreadlib
    --enable-debug
    --disable-debug
    --with-v8-dir
    --without-v8-dir
    --with-v8-include
    --without-v8-include=${v8-dir}/include
    --with-v8-lib
    --without-v8-lib=${v8-dir}/
/home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/libv8-3.11.8.17/ext/libv8/location.rb:50:in `configure': You have chosen to use the version of V8 found on your system (Libv8::Location::System::NotFoundError)
and *not* the one that is bundle with the libv8 rubygem. However,
it could not be located. please make sure you have a version of
v8 that is compatible with 3.11.8.17 installed. You may
need to special --with-v8-dir options if it is in a non-standard
location

thanks,
The Mgmt

    from /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/libv8-3.11.8.17/lib/libv8.rb:7:in `configure_makefile'
    from extconf.rb:32:in `<main>'


Gem files will remain installed in /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/therubyracer-0.11.4 for inspection.
Results logged to /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/therubyracer-0.11.4/ext/v8/gem_make.out

【问题讨论】:

  • 我相信目前它不适用于 Chrome OS,因为它甚至不适用于 Windows(尽管 git 上提供了一些 gem 来提供 v8.dll 和其他支持)
  • gem "therubyracer", :require => 'v8' 将此添加到 gemfile 并检查

标签: ruby therubyracer


【解决方案1】:

我假设您在 Chromebook 上使用 Linux 发行版(直接或通过 chroot)。这是正确的吗?

它正在寻找 v8.h,因此您还需要安装 v8 开发包:它在 Debian/Ubuntu 上是 libv8-dev(在 RedHat 和类似系统上是 -devel)。

【讨论】:

  • 啊,比如 apt-get install libv8-dev?
猜你喜欢
  • 2012-03-25
  • 2013-08-27
  • 1970-01-01
  • 1970-01-01
  • 2013-11-10
  • 2012-12-09
  • 2012-11-10
  • 1970-01-01
  • 2021-04-24
相关资源
最近更新 更多