Another day, another bizzare Xcode error.
While working on my newest app, Gym Calculator, I came across a very strange problem. I had initially set my Deployment Target to iOS 4.3. since I didn’t need any fancy new iOS 6 features. However, I couldn’t build, because my project was using Storyboards, which 4.3 doesn’t support. Xcode helpfully gave me the error message
Storyboards are unavailable on iOS 4.3 and prior
Right, no problem then! I’ll just switch to iOS 5 instead. And… same error. Ok, how about a clean and rebuild? Same error. Restart Xcode? Same error.
After some frustration and head-scratching, I stumbled across a long StackOverflow question discussing the problem. The answer that worked for me – hidden in a sea of less useful answers – was C Fraire’s:
The solution that worked for me was just to delete the ~/Library/Developer/Xcode/DerivedData directory for my project.
So in case anybody else runs into this problem, here’s your solution! (Or at least one potential solution that did the trick for me)
This helped me out so much today! Only thing to say is that the Library folder is a hidden folder. So you first have to unhide folders like so: http://www.mikesel.info/show-hidden-files-mac-os-x-10-7-lion/
Or use copy “open ~/Library/Developer/Xcode/DerivedData” in terminal
Yup, good point! Terminal is handy for things like this.
Or Finder > Go > Go to Folder…
(SHIFT+CMD+G)
…much easier
Yup, good point!
Wonderful! Ran into this issue today with Xcode 4.6.3, and your blog post helped me resolve it.
With Xcode 4.6.3, you can delete the project’s derived data via Window->Organizer->[Select your project in the ‘Projects’ tab], then click on the ‘Delete’ button for the derived data.
Great tip, thanks!