Friday, June 4, 2010

Base SDK Missing

Lately, I've been jumping around between iPhone/iPad SDKs, what with the (currently) four iPhone OS 4 beta releases. I've run into a few problems when I try to open older projects in a newer version of XCode. Common to all of them, the text "Base SDK Missing" shows up in the top-leftmost drop-down menu for choosing the device/simulator to which you're building and installing. On top of this, I have seen other symptoms here and there-- linking errors, error messages that my device doesn't have the correct OS, and so on.

What's causing this? Almost always, this means the "Target Info" for your project is messed up. To solve most any of these issues: expand the "Targets" section in the left sidebar of your project window. Right-click on your main target (sometimes there are more than one if you're also building for, say, iPad). Choose "Get Info" and select the "Build" tab. Change the "Base SDK" value to the most recent SDK that your XCode uses. Also, choose whether you want it to default to building for a device or simulator. Under "C/C++ Compiler Version", make sure you're using the latest GCC.

You're good to go.