Partial success!
For a good chunk of yesterday, I was trying to ""port"" my exceedlingly simple Ruby application to Windows. The hitch? It uses Gosu (game engine), Chipmunk (physics engine), ImageMagick (popular graphics tool), and RMagick (wrapper for ImageMagick in Ruby). With the help of RubyScript2Exe it almost, almost worked. Gosu and Chipmunk had no problem, as they had no-strings-attached .so files and apparently were programmed well. ImageMagick, despite trying to be a pain in the ass by making me include an extra dozen DLLs in my project folder, actually did end up working. But RMagick...when moving the generated app to a new computer that didn't have ImageMagick installed freaked out with a weird "address not accessible" error or something. After some fiddling I gave it up as a lost cause and dropped support for ImageMagick+RMagick. The only reason they were there in the first place is because I wanted to load SVG files whenever possible, and possibly have some dynamic graphic generation, but...the former isn't that great anyway, and the latter will have to be done other ways, if at all.
So, yes, Ruby+Gosu+Chipmunk play just fine with RubyScript2Exe on both Windows and Linux.
March 19th, 2009 - 01:21
Hello,
I’m pounding my head on the wall with the same situation, I’m using rmagick to process images in my wxRuby application, after used tar2rubyscript and rubyscript2exe it worked well on my machine, but when move to another machine, it throw out some exception like ‘stack over flow’ with rmagick.
Any suggestion on that case since your last post? please help. I’m desperating on finding solution for that stuff.
Thanks,
Du Huynh
March 19th, 2009 - 08:36
Unfortunately, I never did revisit this in an attempt to get this to work. I wouldn’t give up hope, though, as there are RMagick and ImageMagick gems/libraries built specifically for Windows. If you could code your script so that it loads a different gem based on your platform, you may end up with a working solution. Just a thought. Sorry I can’t be of more help, but I am curious if that works out for you.
http://rubyforge.org/projects/rmagick/ has the win32 gem
http://www.imagemagick.org/script/binary-releases.php#windows has the windows imagemagick binary
Good luck!
March 19th, 2009 - 08:52
oh, thanks for your quick response.
i will give it a try to my stuff.
March 20th, 2009 - 12:28
Solved.
Change to another solution :install image_science with FreeImage required. Its functions look fit to my requirement. Now i can port to another machine.
Thanks
Du
March 20th, 2009 - 12:31
Not familiar with that tool, but I’ll have to check it out. Thanks for following up!