From: killy971@... Date: 2007-08-15T11:25:05+09:00 Subject: LoadError - Mechanize, Hpricot (gems) Hello, I've been trying to install and use Mechanize ( http://rubyforge.org/projects/mechanize/ ), and cannot solve the errors that occur. Actually, I'm not sure the error is really linked to this gem, because I remember having had the same kind of problems while trying to install other gems. So, I'm working on windows, with cygwin. I installed Mechanize with the following command line : > gem install mechanize and it seems to have installed successfully : Successfully installed mechanize-0.6.10 Installing ri documentation for mechanize-0.6.10... Installing RDoc documentation for mechanize-0.6.10... So, after this, I try to use it, as written on this page : http://mechanize.rubyforge.org/mechanize/files/EXAMPLES_txt.html And here's what happens : irb(main):001:0> require "rubygems" => true irb(main):002:0> require "mechanize" LoadError: Permission denied - /usr/lib/ruby/gems/1.8/gems/hpricot-0.6- mswin32/lib/i686-linux/hpricot_scan.so from /usr/lib/ruby/gems/1.8/gems/hpricot-0.6-mswin32/lib/i686- linux/hpricot_scan.so from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/hpricot-0.6-mswin32/lib/ hpricot.rb:20 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/mechanize-0.6.10/lib/ mechanize/page.rb:2 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/mechanize-0.6.10/lib/ mechanize.rb:40 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from (irb):2 from /usr/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:279 Then, I just go where the hpricot_scan.so file is, "chmod +x" it, and retry. Then : irb(main):003:0> require "mechanize" LoadError: No such file or directory - /usr/lib/ruby/gems/1.8/gems/ hpricot-0.6-mswin32/lib/i686-linux/hpricot_scan.so from /usr/lib/ruby/gems/1.8/gems/hpricot-0.6-mswin32/lib/i686- linux/hpricot_scan.so from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/hpricot-0.6-mswin32/lib/ hpricot.rb:20 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/mechanize-0.6.10/lib/ mechanize/page.rb:2 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from /usr/lib/ruby/gems/1.8/gems/mechanize-0.6.10/lib/ mechanize.rb:40 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `gem_original_require' from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: 32:in `require' from (irb):3 from /usr/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:279 Anyway, the file really does exists. Is there anyone who know how to solve this problem please ?