Xcode 4 SDL/OpenGL MacOS -> iOS Recompilation
Hi. I have an SDL OpenGL test app that I've built with Xcode4 on my Mac. What do I need to do to get it running on the iPhone simulator? When I try to build it I get the following error:
The selected run destination is not valid for this action.
I thought it may have been because my provisional profile had expired (or perhaps not been added since I upgraded from Xcode3 to Xcode4) but I'm still getting the same error.
Any ideas? I guess I'm also going to have to drop the OpenGL framework for the OpenGLES framework.. maybe.. perhaps??? Would this be whats stopping it from building?
Cheers
Sparky
The selected run destination is not valid for this action.
I thought it may have been because my provisional profile had expired (or perhaps not been added since I upgraded from Xcode3 to Xcode4) but I'm still getting the same error.
Any ideas? I guess I'm also going to have to drop the OpenGL framework for the OpenGLES framework.. maybe.. perhaps??? Would this be whats stopping it from building?
Cheers
Sparky
I recently fixed this for an OS X app by selecting the correct Base SDK in build setting. For some reason the project I had was compiling for MacOS10.5 which I didn't have an SDK for. Trying setting it to Latest iOS and see if that fixes it.
(Apr 4, 2011 05:12 AM)dazza Wrote: I recently fixed this for an OS X app by selecting the correct Base SDK in build setting. For some reason the project I had was compiling for MacOS10.5 which I didn't have an SDK for. Trying setting it to Latest iOS and see if that fixes it.
Hi. Yeah I've already got Base SDK set to iOS 4.3 so that can't be the problem sorry.
The question is - can you really build an Mac SDL/OpenGL app and run it on iOS (without all the Model-View objective C stuff you normal have in a small iPhone app?) I'm just wondering if I'm trying to cut too many corners.
My program was written in Windows and it ported reasonably well to Mac OS. I'd like to keep most of it cross-compilable if possible so I can work on it on my (Windows) laptop or Mac depending where I am.
I have not used SDL in an iPhone game, but I think there are two things you would have to do to get an SDL/OpenGL game to run on the iPhone. First, use the OpenGL ES framework instead of OpenGL because the iPhone uses OpenGL ES.
Second, use an iPhone version of SDL. The Mac SDL framework won't work on the iPhone. Your best bet would be to download the SDL source code from their code repository and build an iPhone library from the source code.
Second, use an iPhone version of SDL. The Mac SDL framework won't work on the iPhone. Your best bet would be to download the SDL source code from their code repository and build an iPhone library from the source code.
(Apr 4, 2011 12:03 PM)szymczyk Wrote: Second, use an iPhone version of SDL. The Mac SDL framework won't work on the iPhone. Your best bet would be to download the SDL source code from their code repository and build an iPhone library from the source code.
Thanks for that. Yeah I knew I'd have to use OpenGLES instead. I just had a quick look inside the SDL1.3 (beta?) archive - there are some Xcode example projects in there so I reckon that will be the best place to start.. if they'll build on Xcode 4 ;-)
Possibly Related Threads...
| Thread: | Author | Replies: | Views: | Last Post | |
| JEDI-SDL, MacOS X and XCode Tutorial | savage | 5 | 10,076 |
Jun 7, 2007 04:01 AM Last Post: savage |
|
| GLUT, C++, and Opengl with Xcode | WhatMeWorry | 4 | 5,890 |
Jul 2, 2006 07:42 AM Last Post: codemattic |
|
| Xcode, C++, OpenGL, and Graphics Engines OH MY! | box_king | 4 | 3,934 |
May 24, 2006 09:59 AM Last Post: MacFiend |
|
| OpenSource game need a MacOs porter... | m3xican | 16 | 9,321 |
Dec 18, 2005 11:43 AM Last Post: m3xican |
|

