Unable to install json 1.8.3 in ruby 2.2.1
simple fix delete your gem.lock file and run bundle install this should rebuild the gemlock file and fix the issue, i was getting the same error when trying to move my development environment from nitrous.io to cloud9,. hope this help
copy from migs120's answer https://github.com/flori/json/issues/253
I use macOS sierra, it's work fine.
Install the following package in ubuntu
sudo apt-get install libgmp3-dev
For more informationhttps://github.com/flori/json/issues/253