首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >试图安装therubyracer时出错

试图安装therubyracer时出错
EN

Stack Overflow用户
提问于 2015-03-17 20:40:10
回答 1查看 200关注 0票数 0

当我试图安装创业板therubyracer时,我会得到以下错误:

代码语言:javascript
运行
复制
gem install therubyracer
Building native extensions.  This could take a while...
ERROR:  Error installing therubyracer:
        ERROR: Failed to build gem native extension.

        /opt/ruby-enterprise-1.8.7-2012.02/bin/ruby extconf.rb
checking for main() in -lpthread... yes
Warning! Unable to load libv8 ~> 3.16.14.
*** 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=/opt/ruby-enterprise-1.8.7-2012.02/bin/ruby
    --with-pthreadlib
    --without-pthreadlib
    --enable-debug
    --disable-debug
/opt/ruby-enterprise-1.8.7-2012.02/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require': no such file to load -- libv8 (LoadError)
    from /opt/ruby-enterprise-1.8.7-2012.02/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require'
    from extconf.rb:29

Gem files will remain installed in /home/speedup18meses/.gems/gems/therubyracer-0.12.1 for inspection.
Results logged to /home/speedup18meses/.gems/gems/therubyracer-0.12.1/ext/v8/gem_make.out

我使用共享服务器,因此,我没有sudo访问我的用户。我正在一个Rails应用程序中使用这个。我试过这个:

代码语言:javascript
运行
复制
gem install libv8 -v '3.16.14.3' -- --with-system-v8
gem install therubyracer

代码语言:javascript
运行
复制
gem install libv8
gem install therubyracer

我试图安装一个特殊的版本,并编辑Gemfile,但两者都不起作用。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-03-17 20:52:16

我正在一个Rails应用程序上使用这个

然后在Gemfile中添加行:

代码语言:javascript
运行
复制
gem 'therubyracer'

那就做:

代码语言:javascript
运行
复制
$ bundle install

然后,邦德勒将处理安装依赖项。

当我试图安装gem therubyracer时,我会得到以下错误:

我不明白那个错误。扔掉你的电脑,把我的电脑和我安装的软件一起拿去。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/29109234

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档