Code::Blocks Forums

User forums => Help => Topic started by: Pommespapst on September 12, 2010, 12:31:59 pm

Title: Compiling on Windows for Mac
Post by: Pommespapst on September 12, 2010, 12:31:59 pm
Hi everyone!

I am using Code Blocks with MingGW.
I made a program using wxWidgets. It works fine on Windows, and now, since wxWidgets is cross platform just as Code Blocks i want to compile the program so that it would run on a Mac.
How do I setup Code Blocks to do that?


Thanks in advance!
Title: Re: Compiling on Windows for Mac
Post by: oBFusCATed on September 12, 2010, 12:52:39 pm
To compile on windows you need a cross compiler for mac, and also all the tool required to build the installer.
Title: Re: Compiling on Windows for Mac
Post by: Pommespapst on September 12, 2010, 09:13:07 pm
Can't I use MinGW for this?
Title: Re: Compiling on Windows for Mac
Post by: oBFusCATed on September 12, 2010, 10:07:55 pm
Yes, I think...
Title: Re: Compiling on Windows for Mac
Post by: Pommespapst on September 14, 2010, 03:12:51 pm
But how do I set up MinGW and CodeBlocks to do it?
Title: Re: Compiling on Windows for Mac
Post by: MortenMacFly on September 14, 2010, 03:20:32 pm
Can't I use MinGW for this?
Yes, I think...
As "MinGW" stands for Minimalist GNU for Windows I don't believe this is possible, sorry.
Title: Re: Compiling on Windows for Mac
Post by: Pommespapst on September 23, 2010, 03:34:51 pm
ah i didnt know that ^^" thanks...
can you by any chance recommend a compiler that does the job?
Title: Re: Compiling on Windows for Mac
Post by: MortenMacFly on September 23, 2010, 05:41:50 pm
can you by any chance recommend a compiler that does the job?
I am not aware of any possibility to do this. The only possible cross-compilation is under Linux... but that's probably not very mature. I don't think Apple supports cross-compiling from another platform very well... why should they?

Any experiences from other users / devs?!
Title: Re: Compiling on Windows for Mac
Post by: reckless on September 23, 2010, 06:34:46 pm
hmm havent dabbled into it myself but since mac is based on linux it should be doable with a posix compiler like cygwin (might need a development sdk from apple) other options i can think of is rtems (contains quite few compilers targetting other environments).

the might be doable here means possibly but probably very hard to do ;) ill see if i can dig up something on it, newer the less try googling a bit for cross apple compilation.
Title: Re: Compiling on Windows for Mac
Post by: stahta01 on September 23, 2010, 07:02:46 pm
since mac is based on linux

NOTE: Mac is based partly on BSD; not Linux.

http://en.wikipedia.org/wiki/OSX#History (http://en.wikipedia.org/wiki/OSX#History)
Quote
Mac OS X is based upon the Mach kernel.[11] Certain parts from FreeBSD's and NetBSD's implementation of Unix were incorporated in NeXTSTEP, the core of Mac OS X. NeXTSTEP was the object-oriented operating system developed by Steve Jobs' company NeXT after he left Apple in 1985.[12] While Jobs was away from Apple, Apple tried to create a "next-generation" OS through the Taligent, Copland and Gershwin projects, with little success.

Tim S.
Title: Re: Compiling on Windows for Mac
Post by: reckless on September 23, 2010, 08:48:01 pm
ah my bad i tend to get those mixed up at times.

question would then be if the BSD libraries are enough for compiling for mac ?.
Title: Re: Compiling on Windows for Mac
Post by: MortenMacFly on September 23, 2010, 09:39:24 pm
question would then be if the BSD libraries are enough for compiling for mac ?.
Your questions are out of the scope of this forum meanwhile (as they are not related to Code::Blocks). You better ask in a Mac developer forum. This sounds more reasonable to me and most likely you'll get more precise answers.
Title: Re: Compiling on Windows for Mac
Post by: reckless on September 24, 2010, 07:15:02 pm
not the original poster the question was rethorical please disregard.
Title: Re: Compiling on Windows for Mac
Post by: Pommespapst on September 28, 2010, 10:23:51 pm
So it seems the only solution would be to install Code::Blocks as well as wxWidgets on the Mac and compile directly on it...right?
Title: Re: Compiling on Windows for Mac
Post by: MortenMacFly on September 29, 2010, 06:30:07 am
So it seems the only solution would be to install Code::Blocks as well as wxWidgets on the Mac and compile directly on it...right?
Certainly. This should be the case for 99% of Apple development projects. ;-)
Title: Re: Compiling on Windows for Mac
Post by: Pommespapst on September 30, 2010, 05:05:40 pm
Kk then I'll try that.

Thanks for the help everybody!