Possible Duplicate:
Game programming on Objective-C and linux
I know that developing iPhone apps (painlessly, at least) pretty much requires a Mac. However, is it possible to develop normal desktop applications using Objective-C in Linux? For example, could I make a game using a development library for Objective-C, and release it for Linux, rather than iOS?
There are a lot of normal desktop applications which use GNUstep (free version of Cocoa API) on Linux.
For games you can try sdlobjc — SDL binding for Objective-C.
There is even a Linux distribution called Étoilé which uses GNUstep based user environment and all own GUI applications writen in Objective-C.
If you want to learn how to program in Objective-C using GNUstep on Linux (or cygwin) there are some possible problems:
You must use cygwin in windows to build the application. Which means that it:
a) some applications can be slowed down because of cygwin's translations of POSIX API calls to Win32 API calls. For example fork()
call will be translated in Win32's CreateProcess call and some others and will be less efficient than in UNIX.
b) your application must be distributed with cygwin's dll
c) your application can't be 64bit (at least for now)
d) you application will see all your windows disk drives as a part of unix filesystem hierarchy (c: and d: will be /cygdrive/c and /cygdrive/d) and you will have /bin /tmp /usr /etc avialable under / as well.
There's not up-to-date books about GNUstep or about programming Objective-C not using Mac OS. Thre is Stephen Kochan's book "Programming in Objective-C 2.0 (2nd Edition)" where he unfortunately ommits explaination of how to build even basic examples under Linux or Windows. I hope it is fixed in 3rd edition.
GNUstep has own themes so apps may be themed differently than GTK Linux applications in Linux or usual themed application in Windows.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With