I am going through a Rails tutorial and I\'m not able to complete \'bundle install\' due to a problem with the json gem. When I attempt to install it directly:
Json 1.8.3 seems to have some issues with Ruby 2.2.3 (though I expect some future patches of Ruby will probably fix the problem). Downgrading Ruby to 2.2.2 worked for me.
(That said, so did sudo apt-get install libgmp3-dev
, as @alf suggested - but if you're not able to do that, downgrading ruby might be a feasible alternative.)
Try running rvm implode
and then following this guide http://ryanbigg.com/2014/10/ubuntu-ruby-ruby-install-chruby-and-you/
I suspect RVM did not include the correct headers for you.
cannot find -lgmp
means that it can't find the gmp library. Try running:
sudo apt-get install libgmp3-dev
https://github.com/flori/json/issues/253