Trying to install thrift or thrift gem as dependency and you are getting this error:
Building native extensions. This could take a while... ERROR: Error installing thrift: ERROR: Failed to build gem native extension. /Users/foo/.rvm/rubies/ruby-2.1.4/bin/ruby -r ./siteconf20160402-32256-7dzqel.rb extconf.rb checking for strlcpy() in string.h... yes creating Makefile
Try following command:
gem install thrift -- --with-cppflags=\"-D_FORTIFY_SOURCE=0 -Wno-shift-negative-value\"
Hopefully, this solved your problem.