Not logged inGosu Forums
Forum Gosu Homepage Help Search Register Login
Up Topic Gosu / Gosu Exchange / Windows executable
- - By Jwosty Date 2011-08-09 14:26
Question: Is it possible to create a Windows executable from a gosu game on a Mac? I don't have access to a Windows computer that I can install things on. (I am using one right now, but it's my cousins)
Parent - - By erisdiscord Date 2011-08-09 15:18
I don't know if there are any easy answers here. If you're using Ruby Gosu, probably not; if you're using C++ Gosu, there's the option of compiling a mingw32 cross-compiler, but that's pretty time consuming and, as it turns out, a tremendous pain.

There are numerous options (Boot Camp, VMware, Parallels, Virtual Box) for running Windows on your Mac, although you'd still need to get your hands on a copy of Windows. This is probably the easiest way.
Parent - - By Jwosty Date 2011-08-09 18:11
I'm using Ruby Gosu. I don't have a Windows copy, and I don't think I'll buy one just for this. Thanks anyway!
Parent - - By Dahrkael Date 2011-08-09 18:17
ask someone from this board to do the exe for you.
Parent - By jlnr (dev) Date 2011-08-09 20:29
…and offer to help with the port of their game to OS X. Should work :)
Parent - - By erisdiscord Date 2011-08-09 18:25
I suppose you could create a Windows executable with an embedded Ruby interpreter, if you were willing to go down the cross-mingw32 route. Ruby's easy enough to work with from C, although it still involves working with C and you'd still have to distribute your Ruby source code too—so maybe not such a great idea.

You could always ask someone else to do it for you, I guess!
Parent - By Jwosty Date 2011-08-10 23:52
Eh, I don't mind giving my source out. In fact, I always do anyway :)
Also, if I do this, do I have to have knowledge of C? Because I don't... :P
Parent - - By RunnerPack Date 2011-08-09 20:06
You could try ReactOS (http://www.reactos.org/en/index.html). It's still in alpha, but RubyInstaller and its companion mingw32 shell probably don't do too many crazy things, OS-wise. I just tried it the other day under VirtualBox (just ReactOS, not Ruby) and it seemed to run quite nicely.
Parent - - By erisdiscord Date 2011-08-09 20:21
Oh my, that's probably the most fascinatingly esoteric solution yet. I would imagine ReactOS is about as compatible as Wine—they share some code IIRC?
Parent - - By RunnerPack Date 2011-08-10 01:35
I'm not sure I agree with "esoteric" but I'll take that as a compliment ;-)

However, I'm not really sure it's even a solution... I just tried the latest ReactOS in the latest VirtualBox. There was no working browser with which to download RubyInstaller, and the network subsystem doesn't seem up to the task of getting the file off of my Samba share. I suppose there's a way to do it with the live or installer CDs, but it seems like more work than it's worth, especially if you can get temporary access to a real Windows PC and do something like jlnr suggested (assuming that works).
Parent - By erisdiscord Date 2011-08-10 01:39
Well~ Maybe not esoteric to the likes of you or me, but certainly to many people it would be so. :D
Parent - By Jwosty Date 2011-08-10 23:56
Downloading ReactOS and VirtualBox right now, I'll try it when it's finished. Thanks!
Parent - By Jwosty Date 2011-08-11 00:18
Hmm, haven't had too much luck with ReactOS... I don't really like it :/
Parent - - By jlnr (dev) Date 2011-08-09 23:14
If you had access to a Windows computer at least a single time, you could use rubyscript2exe to compile allinoneruby.rb into allinoneruby.exe; then this EXE is like a complete Ruby installation. THEN, you can just put the Gosu gem contents and your game next to it and tell people to drag yourgame.rb onto allinoneruby.exe.

Not really a great solution, but at least you can release much faster than if you rely on a Windows computer or help.

Here's the link, haven't tried it myself, but I remember seeing it used with Gosu:

http://www.erikveen.dds.nl/rubyscript2exe/
Parent - By Jwosty Date 2011-08-11 00:00
I would but the only problem is that I don't have access to one that I could download things to... Thanks for the help though! (I probably would have tried Ocra if I could use a Windows computer)
Parent - - By philomory Date 2011-12-14 01:38
I know this is an old thread, but I felt I should point out that you definitely can distribute a game for windows using rubyallinone even if you don't have a access to a Windows computer. I did exactly that for my (rather terrible) LD-17 entry, and I think a few other projects as well.

The game itself was very bad, but it provided a big lesson in persevering through difficult packaging tasks: I was able, without access to a windows computer, to upload a functioning windows version of my game which used not only Ruby and Gosu, but also Chipmunk through FFI.

As far as I'm aware, there is no reason at all that the copy of rubyallinone.exe that I used (and still have on a thumb drive for ruby development using someone else's computer) shouldn't work for anyone who needs it, so I'll attach it here.

Okay, well, there is one reason: sadly, it's only Ruby 1.8.6, which isn't exactly the new hotness. But it's good when you just need an uninvasive ruby interpreter.

Edit: Incidentally, you'll need to include things like Gosu.dll and fmod.dll in the folder with your files... if you want to see how it looks, you can take a look at my LD17 entry. Just, for the love of god, don't run the game itself, it's very, very bad :-p
Attachment: allinoneruby.exe (0B)
Parent - - By jlnr (dev) Date 2011-12-14 10:27
Do you mean gosu.for_1_8.so or is this with a custom Gosu that you built? I remember you using SDL_mixer in lots of projects. :)

Also, is it a coincidence that you rediscover this just three days before the Ludum Dare starts? Go go go, theme voting!
Parent - By philomory Date 2011-12-19 21:56
It wasn't actually coincidence, of course; I didn't actually participate in Ludum Dare this time, but knowing that it was coming had me thinking about Gosu again. I just didn't have time this past weekend.

As for the library file, it's been a while so I don't recall, but I'm pretty sure that I used the vanilla gosu gem for that project, not my custom SDL one.
Parent - By Jwosty Date 2011-12-15 23:19
Ah, thanks a bunch! This really helps. :D
Up Topic Gosu / Gosu Exchange / Windows executable

Powered by mwForum 2.29.1 © 1999-2013 Markus Wichitill