Installed gems yet "no such file to load"

Some gems load, some don’t, whether using irb or rake migrate. The
example below is using irb. Please take a glance at the following, I’ve
been reading all over the net for two days and nothing seems to jive.
I’ve had zero problems for years on my centos boxes. This project,
however, requires Solaris x86 and MS SQL. Hence some of the paths and
gems you’ll see.

Start the evidence…

Check out the following irb…

irb(main):001:0> require ‘rubygems’
=> true

irb(main):002:0> require ‘dbi’
=> true

irb(main):003:0> require ‘dbd-odbc’
LoadError: no such file to load – dbd-odbc
from
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
gem_original_require' from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:inrequire’
from (irb):3

irb(main):004:0> require ‘rmagick’
LoadError: no such file to load – rmagick
from
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
gem_original_require' from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:inrequire’
from (irb):4

irb(main):005:0> require ‘rake’
=> true

Here’s some supporting config information, proving file locations and
versions. fyi, only one installation of ruby etc., so should be no
confusion there.

bash-3.00# which ruby
/opt/local/bin/ruby

bash-3.00# which gem
/opt/local/bin/gem

bash-3.00# which rails
/opt/local/bin/rails

bash-3.00# gem list -d

*** LOCAL GEMS ***

actionmailer (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
actionpack (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
activerecord (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
activerecord-sqlserver-adapter (2.2.22)
Installed at: /opt/local/lib/ruby/gems/1.8
activeresource (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
activesupport (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
dbd-odbc (0.2.4)
Installed at: /opt/local/lib/ruby/gems/1.8
dbi (0.4.1)
Installed at: /opt/local/lib/ruby/gems/1.8
deprecated (2.0.1)
Installed at: /opt/local/lib/ruby/gems/1.8
rack (1.0.1)
Installed at: /opt/local/lib/ruby/gems/1.8
rails (2.3.4)
Installed at: /opt/local/lib/ruby/gems/1.8
rake (0.8.7)
Installed at: /opt/local/lib/ruby/gems/1.8
rmagick (1.15.17)
Installed at: /opt/local/lib/ruby/gems/1.8

bash-3.00# gem environment
RubyGems Environment:

  • RUBYGEMS VERSION: 1.3.5
  • RUBY VERSION: 1.8.6 (2009-08-04 patchlevel 383) [i386-solaris2.10]
  • INSTALLATION DIRECTORY: /opt/local/lib/ruby/gems/1.8
  • RUBY EXECUTABLE: /opt/local/bin/ruby
  • EXECUTABLE DIRECTORY: /opt/local/bin
  • RUBYGEMS PLATFORMS:
    • ruby
    • x86-solaris-2.10
  • GEM PATHS:
    • /opt/local/lib/ruby/gems/1.8
    • /.gem/ruby/1.8
  • GEM CONFIGURATION:
    • :update_sources => true
    • :verbose => true
    • :benchmark => false
    • :backtrace => false
    • :bulk_threshold => 1000
  • REMOTE SOURCES:

THANKS FOR ANY HELP/INSIGHT!!

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs