小编Luc*_*rna的帖子

无法在 ubuntu 中捆绑安装 json gem

我已经使用 rvm 在 rails 上安装了 ruby​​。我正在尝试捆绑安装我在以前的电脑上安装的旧项目,但是当我运行 bundle install 命令时出现以下错误:

Installing json 1.8.3 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /home/florin/.rvm/rubies/ruby-2.2.3/bin/ruby -r ./siteconf20151003-5986-vme5ji.rb extconf.rb
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
compiling generator.c
linking shared-object json/ext/generator.so
/usr/bin/ld: cannot find -lgmp
collect2: error: ld returned 1 exit status
make: *** [generator.so] Error 1

make failed, exit code 2

Gem files will remain installed in /home/florin/.rvm/gems/ruby-2.2.3/gems/json-1.8.3 for inspection.
Results logged to /home/florin/.rvm/gems/ruby-2.2.3/extensions/x86_64-linux/2.2.0/json-1.8.3/gem_make.out
An error occurred while installing json (1.8.3), …
Run Code Online (Sandbox Code Playgroud)

ruby rails gem 14.04 ruby-on-rails

3
推荐指数
1
解决办法
5073
查看次数

标签 统计

14.04 ×1

gem ×1

rails ×1

ruby ×1

ruby-on-rails ×1