安装 yajl-ruby 有一些错误

There are some errors for install yajl-ruby

当我运行:

sudo gem install yajl-ruby

我看到错误:

Building native extensions.  This could take a while...
ERROR:  Error installing yajl-ruby:
        ERROR: Failed to build gem native extension.

/usr/bin/ruby extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/ruby.h


Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/yajl-ruby-1.2.1 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/yajl-ruby-1.2.1/ext/yajl/gem_make.out

我已经安装了yum install ruby rubygems ruby-devel,但是还是有这个问题

尝试:

$ sudo ln -s /usr/bin/llvm-gcc /usr/bin/gcc-4.2
$ sudo gem install yajl-ruby