I have installed Ruby, latest version. I have installed XCode, latest version. I have installed CommandLine tools for XCode too.
Then I want to install Ruby on Rails, but I got the following error:
Fetching: json-1.7.5.gem (100%) Building native extensions. This could take a while... ERROR: Error installing rails: ERROR: Failed to build gem native extension.
/Users/JonyIve/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb creating Makefile
make compiling generator.c make: /usr/bin/gcc-4.2: No such file or directory make: * [generator.o] Error 1
Gem files will remain installed in /Users/JonyIve/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/gems/1.9.1/gems/json-1.7.5 for inspection. Results logged to /Users/JonyIve/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/gems/1.9.1/gems/json-1.7.5/ext/json/ext/generator/gem_make.out