Am trying to install Ruby and RubyGems on a RedHat 5.5 machine. I'd got them by running the following two commands:
sudo yum install ruby
sudo yum install rubygems
Got both installed. However when i try to run gem
, i got the following error:
/usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
require': undefined method
end_with?' for "no such file to load -- Win32API":String (NoMethodError) from /usr/lib/ruby/site_ruby/1.8/rubygems/config_file.rb:55 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:ingem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in
require' from /usr/lib/ruby/site_ruby/1.8/rubygems/gem_runner.rb:8 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:ingem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in
require' from /usr/bin/gem:9
Doesn't matter what kind of command i run, it throws that. (I tried gem -v
, gem update
)
The version of Ruby seems to be 1.8 but i have problem determining the RubyGems version. I'd vi
into rubygems.rb
and at the top it stats the version as 1.5.
Try to fix by running the downgrade command as proposed here, but it throws the same error as well.
Any help on fixing this issue? Just want to get this running so that i can run a RoR apps..