Install rmagick in win32,but no work


#1

i use instantRails 1.0 on winxp.download
‘RMagick-1.9.2-IM-6.2.4-6-win32.zip’ from www
after install,i write code in irb:
require ‘RMagick’

it shows follow errors:
no such file to load – RMagick.

why?


#2

Did you run the postinstall.rb script?

See http://rmagick.rubyforge.org/install-faq.html


#3

removed_email_address@domain.invalid wrote:

Did you run the postinstall.rb script?

See http://rmagick.rubyforge.org/install-faq.html

yes,
i do:
gem install RMagick-win32-1.x.x-mswin32.gem

Then run

postinstall.rb

it success.


#4

Did you set up the RubyGems environment?

See http://docs.rubygems.org/read/chapter/3#page70


#5

removed_email_address@domain.invalid wrote:

Did you set up the RubyGems environment?

See http://docs.rubygems.org/read/chapter/3#page70

C:\Documents and Settings\yang>irb
irb(main):001:0> require ‘rubygems’
=> true
irb(main):002:0> require ‘RMagick’
=> false
irb(main):003:0> exit


#6

On Mar 15, 2006, at 1:59 AM, yang jdong wrote:

irb(main):003:0> exit
Try using it – just because require returns false does not mean it
failed. The library’s gemspec probably used autorequire.[1]

[1] and removed it. http://rubyforge.org/cgi-bin/viewcvs.cgi/RMagick/
rmagick.gemspec?root=rmagick&view=log


#7

yang jdong wrote:

irb(main):002:0> require ‘RMagick’
=> false
irb(main):003:0> exit

The ‘false’ return value from require is meaningless when you’re using
RubyGems. Try this:

require ‘rubygems’
require ‘RMagick’

puts Magick::Long_version


#8

yang jdong wrote:

removed_email_address@domain.invalid wrote:

Did you set up the RubyGems environment?

See http://docs.rubygems.org/read/chapter/3#page70

C:\Documents and Settings\yang>irb
irb(main):001:0> require ‘rubygems’
=> true
irb(main):002:0> require ‘RMagick’
=> false

Require returning ‘false’ does not mean that it has failed. It just
means that the library has been already loaded. If the RMagick gem does
an autorequire on the RMagick file, then that file will be loaded during
the activation of the RMagick gem, meaning that by the time your require
finishes, the file is indeed loaded.


– Jim W.


#9

require ‘rubygems’
require ‘RMagick’

puts Magick::Long_version

it is ok.Thanks.