安装 coccon gem 时出现此错误。有没有人有同样的问题?我正在使用 Ruby 2.0.0p353、Rails 4.0 和 RVM
ERROR: Error installing cocoon:
ERROR: Failed to build gem native extension.
/home/user/.rvm/rubies/ruby-2.0.0-p353/bin/ruby extconf.rb
checking for st.h... yes
creating Makefile
make
compiling handler.c
compiling gram.c
compiling token.c
token.re: In function ‘sycklex_yaml_utf8’:
token.re:541:36: warning: variable ‘lvl’ set but not used [-Wunused-but-set-variable]
compiling syck.c
compiling rubyext.c
rubyext.c: In function ‘mktime_do’:
rubyext.c:292:19: warning: unused variable ‘offset’ [-Wunused-variable]
rubyext.c: In function ‘rb_syck_load_handler’:
rubyext.c:664:5: warning: implicit declaration of function ‘rb_hash_size’ [-Wimplicit- function-declaration]
rubyext.c: In function ‘rb_syck_err_handler’:
rubyext.c:684:12: warning: format ‘%d’ expects argument of type ‘int’, but argument 5 has type ‘long int’ [-Wformat]
rubyext.c: In function ‘syck_const_find’:
rubyext.c:1047:5: warning: implicit declaration of function ‘rb_ary_size’ [-Wimplicit-function-declaration]
rubyext.c: In function ‘syck_scalar_value_set’:
rubyext.c:1481:27: error: ‘struct RString’ has no member named ‘ptr’
rubyext.c: In function ‘syck_seq_initialize’:
rubyext.c:1509:15: warning: variable ‘node’ set but not used [-Wunused-but-set-variable]
rubyext.c: In function ‘syck_node_type_id_set’:
rubyext.c:1741:25: error: ‘struct RString’ has no member named ‘ptr’
make: *** [rubyext.o] Error 1