我试图在OS X 10.9上安装Ruby GSL.我正在使用RVM安装Ruby 2.0.0.根据它的网站,我需要先安装GSL.有了这个,我用Homebrew安装了GSL(brew install gsl
).接下来,我做了gem install gsl
,但是给出了此错误消息:
compiling fft.c fft.c:270:60: warning: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32] for (i = 0; i < table->nf; i++) gsl_vector_int_set(v, i, table->factor[i]); ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~ fft.c:614:18: warning: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32] shape[0] = n; ~ ^ fft.c:706:18: warning: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32] shape[0] = n; ~ ^ fft.c:773:18: warning: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32] shape[0] = n; ~ ^ fft.c:910:48: error: use of undeclared identifier 'forward' rb_define_const(mgsl_fft, "Forward", INT2FIX(forward)); ^ /Users/yihangho/.rvm/rubies/ruby-2.0.0-p353/include/ruby-2.0.0/ruby/ruby.h:241:45: note: expanded from macro 'INT2FIX' #define INT2FIX(i) ((VALUE)(((SIGNED_VALUE)(i))<<1 | FIXNUM_FLAG)) ^ fft.c:911:48: error: use of undeclared identifier 'forward' rb_define_const(mgsl_fft, "FORWARD", INT2FIX(forward)); ^ /Users/yihangho/.rvm/rubies/ruby-2.0.0-p353/include/ruby-2.0.0/ruby/ruby.h:241:45: note: expanded from macro 'INT2FIX' #define INT2FIX(i) ((VALUE)(((SIGNED_VALUE)(i))<<1 | FIXNUM_FLAG)) ^ fft.c:912:49: error: use of undeclared identifier 'backward' rb_define_const(mgsl_fft, "Backward", INT2FIX(backward)); ^ /Users/yihangho/.rvm/rubies/ruby-2.0.0-p353/include/ruby-2.0.0/ruby/ruby.h:241:45: note: expanded from macro 'INT2FIX' #define INT2FIX(i) ((VALUE)(((SIGNED_VALUE)(i))<<1 | FIXNUM_FLAG)) ^ fft.c:913:49: error: use of undeclared identifier 'backward' rb_define_const(mgsl_fft, "BACKWARD", INT2FIX(backward)); ^ /Users/yihangho/.rvm/rubies/ruby-2.0.0-p353/include/ruby-2.0.0/ruby/ruby.h:241:45: note: expanded from macro 'INT2FIX' #define INT2FIX(i) ((VALUE)(((SIGNED_VALUE)(i))<<1 | FIXNUM_FLAG)) ^ 4 warnings and 4 errors generated. make: *** [fft.o] Error 1
知道如何解决这个问题吗?