OS: Fedora 24 Ruby: 2.3.1p112 Rails: 5.0.0
始终无法安装 json 1.8.1,macro "rb_str_new" 函数缺少一个参数?
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory: /home/mwong/.rvm/gems/ruby-2.3.1/gems/json-1.8.1/ext/json/ext/generator
/home/mwong/.rvm/rubies/ruby-2.3.1/bin/ruby -r ./siteconf20160723-13339-1j64org.rb extconf.rb
creating Makefile
current directory: /home/mwong/.rvm/gems/ruby-2.3.1/gems/json-1.8.1/ext/json/ext/generator
make "DESTDIR=" clean
current directory: /home/mwong/.rvm/gems/ruby-2.3.1/gems/json-1.8.1/ext/json/ext/generator
make "DESTDIR="
compiling generator.c
In file included from generator.c:1:0:
../fbuffer/fbuffer.h: In function ‘fbuffer_to_s’:
../fbuffer/fbuffer.h:175:47: error: macro "rb_str_new" requires 2 arguments, but only 1 given
VALUE result = rb_str_new(FBUFFER_PAIR(fb));
^
../fbuffer/fbuffer.h:175:20: warning: initialization makes integer from pointer without a cast [-Wint-conversion]
VALUE result = rb_str_new(FBUFFER_PAIR(fb));
^~~~~~~~~~
Makefile:238: recipe for target 'generator.o' failed
make: *** [generator.o] Error 1
make failed, exit code 2
Gem files will remain installed in /home/mwong/.rvm/gems/ruby-2.3.1/gems/json-1.8.1 for inspection.
Results logged to /home/mwong/.rvm/gems/ruby-2.3.1/extensions/x86_64-linux/2.3.0/json-1.8.1/gem_make.out