First I installed rvm for multi-user using script
\curl -L https://get.rvm.io | sudo bash -s stable and I added users to rvm group.
and rvm seems worked fine. so I installed ruby 1.9.3 and set 1.9.3 as default
and now I tried to install rails with command
gem install rails It seems worked fine, but when fetching json-1.7.6.gem and an error occurs.
ERROR: Error installing rails: ERROR: Failed to build gem native extension. /usr/local/rvm/rubies/ruby-1.9.3-p374/bin/ruby extconf.rb creating Makefile make sh: make: Permission denied Gem files will remain installed in /usr/local/rvm/gems/ruby-1.9.3-p374/gems/json-1.7.6 for inspection. Results logged to /usr/local/rvm/gems/ruby-1.9.3-p374/gems/json-1.7.6/ext/json/ext/generator/gem_make.out So I thought it would be related with permission, so I tried
sudo gem install rails but then this error occurs.
sudo: gem: command not found What should I do?