-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi there,
A friend of mine tried using RedCloth on Windows as part of a project
I introduced hin to, but RedCloth failed to require. This is what he
got:
======================================================================
c:\Ruby192\msysgit\msysgit\OpenRubyRMK\karfunkel>bundle exec rake
- –trace rdoc
rake aborted!
no such file to load – 1.9/redcloth_scan
Couldn’t load 1.9/redcloth_scan
The $LOAD_PATH was:
C:/Ruby192/lib/ruby/gems/1.9.1/gems/r18n-desktop-0.4.9/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/r18n-core-0.4.9/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/nokogiri-1.4.4-x86-mingw32/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/minitar-0.5.3/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/hanna-nouveau-0.2.2/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rdoc-3.5.3/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/haml-3.0.25/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/eventmachine-1.0.0.beta.3-x86-mingw32/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/chunky_png-1.1.0/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/chingu-0.8.1/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rest-client-1.6.1/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/mime-types-1.16/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/gosu-0.7.29-x86-mingw32/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/crack-0.1.8/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.8/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.8/lib/case_sensitive_require
C:/Ruby192/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.8/ext
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib
C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.18/lib
C:/Ruby192/lib/ruby/site_ruby/1.9.1
C:/Ruby192/lib/ruby/site_ruby/1.9.1/i386-msvcrt
C:/Ruby192/lib/ruby/site_ruby
C:/Ruby192/lib/ruby/vendor_ruby/1.9.1
C:/Ruby192/lib/ruby/vendor_ruby/1.9.1/i386-msvcrt
C:/Ruby192/lib/ruby/vendor_ruby
C:/Ruby192/lib/ruby/1.9.1
C:/Ruby192/lib/ruby/1.9.1/i386-mingw32
C:/Ruby192/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.8/lib/redcloth.rb:12:in
requir e' C:/Ruby192/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.8/lib/redcloth.rb:12:in
<top (
required)>’
c:/Ruby192/msysgit/msysgit/OpenRubyRMK/karfunkel/Rakefile:28:in
require' c:/Ruby192/msysgit/msysgit/OpenRubyRMK/karfunkel/Rakefile:28:in
<top
(required)
’
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/rake_module.rb:25:in
lo ad' C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/rake_module.rb:25:in
lo
ad_rakefile’
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:495:in
r aw_load_rakefile' C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:78:in
bl
ock in load_rakefile’
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:129:in
s tandard_exception_handling' C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:77:in
lo
ad_rakefile’
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:61:in
bl ock in run' C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:129:in
s
tandard_exception_handling’
C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/lib/rake/application.rb:59:in
ru n' C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2/bin/rake:32:in
<top
(required)>’
C:/Ruby192/lib/ruby/gems/1.9.1/bin/rake:19:in load' C:/Ruby192/lib/ruby/gems/1.9.1/bin/rake:19:in
’
We found out that there isn’t any file called
ext/redcloth_scan/1.9/redcloth_scan.so. It’s just
ext/redcloth_scan/redcloth-scan.so (without the “1.9” part). This code
in redcloth.rb isn’t necessary:
======================================================================
prefix = Config::CONFIG[‘arch’] =~ /mswin|mingw/ ?
“#{Config::CONFIG[‘MAJOR’]}.#{Config::CONFIG[‘MINOR’]}/” : ‘’
lib = “#{prefix}redcloth_scan”
require lib
It should be simply ‘require “redcloth_scan”’, which works fine for
him after he changed the file accordingly.
My friend is running Windows 7 with RubyInstaller’s 1.9.2-p290, but
doesn’t use the devkit as he has a local MinGW/MSYS environment
(MSYS-Git, to be exact) already set up. Note I don’t use Windows (Arch
Linux user) and I just forward what he told me and I diagnosed from
that.
Valete,
Marvin
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQEcBAEBAgAGBQJOancaAAoJELh1XLHFkqha5QMIAIGX1GNOk4WrCVcm67nXBAzF
sIiCZtGZtA+QfQIFRTza7unwUie+htW3TQ15sTT7wLFKg+bhaXKAbCYawZbN/Ua2
x/URZl/K2ZT16/Q1s4/x2o3uxJRe2t3Sw3GtJowN6nPUGVyu4Rrs/HoEHTqRonL0
PWPx6OC/QnL+Ncw7n5ABBYhfTfmU6aJfTbB9XhYFvIAc4bD6BhFrLxhy4M7mQL8M
Ie5+QJV+Ai5uQJb5FTU0BCL7198eCT3JQfSzaIuz+XIjMGetaJOj/d+co1Y1A8bC
39U7XQ+g3q4d6KV9kwQSkdvBTyvI4HhtB5LM+o9OMkhec5Qyzq2uTldAhAwaFYU=
=lWr3
-----END PGP SIGNATURE-----