Temple of The Roguelike Forums
Development => Programming => Topic started by: Pueo on March 22, 2012, 03:20:50 PM
-
If I make an executable on OS X, will all those other Unix-likes be able to run the .exe? I know OSX is based on Darwin, so it's in the Unix family, but I'm not sure how compatible it is with the other guys. I know I can run Unix .exes, but I don't know if other Unix systems can run OS X .exes.
-
Short answer: No.
(Also, .exe is a Windows executable file, nothing to do with unixes).
-
A bit longer answer:
Not on linux for sure, because, for some reason, the endianess of the binaries on those two platform are different.
I'm not sure on *BSD...
BTW, on *NIX a file extension is not necessary :) It uses other tricks to know which files it can run (the permissions).
You could add the suffix .exe, if you so desire, but the file doesn't magically turn itself into a windows executable...
edit: you could try and cross-compile, but perhaps releasing the source and let anyone who is interested in to compile it on his/her own is perhaps the better solution, PROVIDED that you are using multiplatform libraries, better yet if free :)
A *NIX user is supposed to be savvy enough to know how to compile something, anyway :p
-
I've seen people write programs that can compile certain languages into windows exes from os x, but I personally don't know how that works.
It's pretty easy (and especially free) to run a virtual machine on your computer and put linux (or anything else) on it. My computer is pretty old but I was still able to pull that off. I only did it with linux though. If you virtualize an os that isn't as compact as linux it might require more space/a good computer.
-
Short answer: No.
(Also, .exe is a Windows executable file, nothing to do with unixes).
Thanks.
Also, I was just using .exe as a name for any general executable file. I guess that might have caused some confusion.
perhaps releasing the source and let anyone who is interested in to compile it on his/her own is perhaps the better solution, PROVIDED that you are using multiplatform libraries, better yet if free :)
A *NIX user is supposed to be savvy enough to know how to compile something, anyway :p
I had though about releasing the source, but I figured it would be easier for me to be able to compile it all and make sure everything works beforehand.
I'm using ncurses, which I'm pretty sure is not supported on Windows, but I've looked at things like mingw, cygwin, and PDCurses. Would any of those be helpful?
-
I'm using ncurses, which I'm pretty sure is not supported on Windows, but I've looked at things like mingw, cygwin, and PDCurses. Would any of those be helpful?
It depends. If you don't use exotic / ncurses-only features, PDCurses should allow you to compile your game for Windows without changes. I did my 2010 7DRL with ncurses, and trivially ported it to Windows using PDCurses.
In fact, I cross-compiled the Windows exe from Linux. Simple programs are very easy to cross-compile to Windows, as long as you don't use any Linux/OSX system APIs. You just need a cross-compiler, which in most Linux distributions is installable from repositories with one command/click. However, I don't know about OSX.
-
It depends. If you don't use exotic / ncurses-only features, PDCurses should allow you to compile your game for Windows without changes. I did my 2010 7DRL with ncurses, and trivially ported it to Windows using PDCurses.
In fact, I cross-compiled the Windows exe from Linux. Simple programs are very easy to cross-compile to Windows, as long as you don't use any Linux/OSX system APIs. You just need a cross-compiler, which in most Linux distributions is installable from repositories with one command/click. However, I don't know about OSX.
Thanks, I'll look at a cross-compiler as well.