Not logged inGosu Forums
Forum back to libgosu.org Help Search Register Login
Up Topic Gosu / Gosu Exchange / Gosu with MacRuby
- By ? Date 2009-08-10 05:07
Hello, hello, has anybody had luck compiling Gosu against MacRuby? I made a quick attempt but it seems I don't have quite everything in its place. I don't want help building it myself; I'm just curious if any of you have done.

Sir Raschke, do you have plans to support MacRuby in the future?
- By erisdiscord Date 2009-08-10 05:14
And I've just registered a user name. Responding to my own post so I'll get reply notifications I suppose. Hope nobody's bothered!
- By jlnr (dev) Date 2009-08-10 08:12
Plans, definitely yes. Especially as MacRuby is getting closer to a fully supported ahead of time compiler (AOT). So after my current C++ iPhone project (= maybe 2009 ;)), I will definitely look into it so I can churn out mobile Ruby games. Other Mac users will also rejoice that their precious Ruby code is finally delivered to players in something else than plaintext form.

As far as I can tell, there are currently two roads to MacRuby; either supporting the FFI interface or being an Objective C library. Since FFI sounds like something that will never work on the iPhone, the Objective C interface would make more sense (and be pretty easy to write), but I have no idea how one would statically link it against MacRuby. If you want to get your hands dirty, you can write an Objective C wrapper and see how far you get :)
- By erisdiscord Date 2009-08-10 13:51
I've thought about it, but I use Ruby because I don't like the C bit of Objective-C (and I'm not very good at it, for that matter). I'm content to wait. :)

I've built MacRuby from source a couple of times and the Rakefile has the option to build a static library as well. I think it requires the Objective-C garbage collector to function, though, and I'm fairly sure the iPhone doesn't support that.
- By jlnr (dev) Date 2009-08-10 14:45
Ah yeah, you would need to replace the Garbage Collector with NSAutoreleasePools in MacRuby and I don't know how easy that is :(
Up Topic Gosu / Gosu Exchange / Gosu with MacRuby

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill