首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >Rails 3.1- therubyracer gem错误

Rails 3.1- therubyracer gem错误
EN

Stack Overflow用户
提问于 2011-10-23 08:01:07
回答 1查看 7.8K关注 0票数 5

使用Windows7内部的VirtualBox,它有Ubuntu。刚刚安装了rails 3.1,当我尝试使用therubyracer gem捆绑安装时,得到以下错误。

代码语言:javascript
运行
复制
Installing therubyracer (0.9.8) with native extensions
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

        /home/john/.rvm/rubies/ruby-1.9.2-p290/bin/ruby extconf.rb
creating Makefile

make
g++ -I. -I/home/john/.rvm/gems/ruby-1.9.2-p290@rails311/gems/libv8-3.3.10.2-x86-linux/lib/libv8/v8/include -I/home/john/.rvm/rubies/ruby-1.9.2-p290/include/ruby-1.9.1/i686-linux -I/home/john/.rvm/rubies/ruby-1.9.2-p290/include/ruby-1.9.1/ruby/backward -I/home/john/.rvm/rubies/ruby-1.9.2-p290/include/ruby-1.9.1 -I. -D_FILE_OFFSET_BITS=64  -Wall -g -rdynamic -fPIC -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC   -o v8_date.o -c v8_date.cpp
make: g++: Command not found
make: *** [v8_date.o] Error 127


Gem files will remain installed in /home/john/.rvm/gems/ruby-1.9.2-p290@rails311/gems/therubyracer-0.9.8 for inspection.
Results logged to /home/john/.rvm/gems/ruby-1.9.2-p290@rails311/gems/therubyracer-0.9.8/ext/v8/gem_make.out
An error occured while installing therubyracer (0.9.8), and Bundler cannot continue.
Make sure that `gem install therubyracer -v '0.9.8'` succeeds before bundling.
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2011-10-23 08:06:26

sudo apt-get install g++

为了确认,我还建议:

sudo apt-get install build-essential

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

https://stackoverflow.com/questions/7863445

复制
相关文章

相似问题

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