XCode iPhone + Simulator

Previous topic - Next topic

bigsofty

Hi,

Just an idea but would it be possible to miss out the GCC compilation phase on Windows and just pump straight 'C' source code into an XCode project?

Pluses/Minuses...

+ Able to use the simulator.
+ Inline Objective-C(?)
+ Allowing access to the full Apple SDK

- GCC compilation error messages would only show up on the Mac
-?

Anything to add?
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

trucidare

- No License check for kungphoo.

MacBook Pro 2,2 GHz Core 2 Duo, 4 GB RAM, 160 GB HDD, 8600M GT
Core i3 - 3,07 GHz, 8 GB Ram, 2.5 TB HDD, Geforce GTX 260+ OC

bigsofty

#2
Yes, that's a problem I never thought of...  ;/
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

trucidare

You have full ObjC access yet and use all of apples apis.
just copy headers and libs and frameworks from your mac to glbasic compiler folder.

but simulator, sorry no support for that.
MacBook Pro 2,2 GHz Core 2 Duo, 4 GB RAM, 160 GB HDD, 8600M GT
Core i3 - 3,07 GHz, 8 GB Ram, 2.5 TB HDD, Geforce GTX 260+ OC

bigsofty

#4
Interesting, I (wrongly?) assumed that the GCC that shipped with GLB was not ObjC compatible, only C/C++.  And I'll, take your advice with the frameworks too Truci. ;)

Very handy tips, thank you!


Ian
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

trucidare

it is fully objc compatible. You only have to get the libs headers and frameworks, because shipping of it are not legal, so doit yourselfe.

created some cocoa touch thingies directly on glbasic with objc.
MacBook Pro 2,2 GHz Core 2 Duo, 4 GB RAM, 160 GB HDD, 8600M GT
Core i3 - 3,07 GHz, 8 GB Ram, 2.5 TB HDD, Geforce GTX 260+ OC

mykyl66

Not sure what this kungphoo thing is but in my dreams I see a huge advantage in seeing and doing final edits of my code directly in xcode without have windows grabbing ram and the back and forth of bits and pieces between os x and windows.

Maybe one day. Of course if the mac ide ends up being usable by the rest of us that would at least allow me to dump windows finally and fully.

Mike

aonyn

@ trucidare,

I have looked at the developer folder on my mac, where xcode is installed, and also the compiler folder for glbasic, but I am not entirely clear what I need to put where.
I have some guesses, but I am not entirely clear, and was wondering if I could please request a bit of help getting started using the iphone api.

Thank in advance!

regards,
Dave
For by grace are ye saved through faith, and that not of yourselves: it is the gift of God: Not of works, lest any man should boast. -Ephesians 2:8-9

Chris

Quote from: aonyn on 2010-Sep-09
@ trucidare,

I have looked at the developer folder on my mac, where xcode is installed, and also the compiler folder for glbasic, but I am not entirely clear what I need to put where.
I have some guesses, but I am not entirely clear, and was wondering if I could please request a bit of help getting started using the iphone api.


Did you get an answer for where to take the headers and libs and frameworks from and where to put them to?

I may need to do something similar.

trucidare

Writing a PN is more efficient to get an answer from me.

For including objc things to your game you only open your xcode project created with glbais add new .mm files to it and start coding like without glbasic. to call the functions in glbasic you need to wrapp it like extern "C" void mow() {} and in glbasic you must only do IMPORT "C" void mow()

then you can simply use mow in glbasic code like a normal glbasic function. beware you need to provide the .mm file everytime.
MacBook Pro 2,2 GHz Core 2 Duo, 4 GB RAM, 160 GB HDD, 8600M GT
Core i3 - 3,07 GHz, 8 GB Ram, 2.5 TB HDD, Geforce GTX 260+ OC

Gary

Just out of interest what is the reasons for the simulator not working? Seems strange that the code will run on the actual device but not the simulator. Would be very handy if it could as I dont have my iPad yet but want to start developing and want to go the step futher than just running on a pc as a windows app

aonyn

Thanks trucidare,

I will experiment with it as I have time, and I hope you don't mind, I may take you up on the offer for PM questions if I get stuck (I promise to try not to be annoying about it)  :)

regards,
Dave
For by grace are ye saved through faith, and that not of yourselves: it is the gift of God: Not of works, lest any man should boast. -Ephesians 2:8-9

trucidare

The reason is the lib could be only compiled for arm platform - i386 wont work, so we couldnt provide libs for simulator. sorry for that :/
MacBook Pro 2,2 GHz Core 2 Duo, 4 GB RAM, 160 GB HDD, 8600M GT
Core i3 - 3,07 GHz, 8 GB Ram, 2.5 TB HDD, Geforce GTX 260+ OC