tags:

views:

52

answers:

2

Hi to all, i have:

ruby1.9.1-full rubygems1.9.1

installed, these are the only versions i have installed.

I am not able to require any gems with the following syntax:

require 'rubygems'
require 'gem_name'

I get this error:

LoadError: no such file to load -- active_record
 from (irb):2:in `require'
 from (irb):2
 from /usr/bin/irb:12:in `<main>'

I have to add this line to the syntax in order for it to work:

require 'rubygems'
gem 'gem_name' <---
require 'gem_name'

But with gems like active_record and sqlite3 i get this error:

Gem::LoadError: Could not find RubyGem sqlite3 (>= 0)

 from /usr/local/lib/site_ruby/1.9.1/rubygems.rb:779:in `report_activate_error'
 from /usr/local/lib/site_ruby/1.9.1/rubygems.rb:214:in `activate'
 from /usr/local/lib/site_ruby/1.9.1/rubygems.rb:1082:in `gem'
 from (irb):3
 from /usr/bin/irb:12:in `<main>'

I have been searching and posting but i am still unable to find a solution for this, in a previous installation i had of ubuntu same version as now, i was able to require the gems normally, i'm not quite sure what could have changed.

I hope some one can help me on this one as this has me stuck.

Thanks in advanced.

Jaime.

A: 

could try it without gem prelude: http://wiki.github.com/rdp/ruby_tutorials_core/ruby-talk-faq#gem_loading_fails_191

rogerdpack
A: 

The proper gem name is sqlite3-ruby, not sqlite. Perhaps try gem'ing this instead?

Ryan Bigg