Search code examples
iosiphonexcodebuilding

Xcode project does not build/run with core data when target is my iPhone 5c


Xcode 5.1.1. - iOS7

When I create an empty project with Core Data option checked (literally empty project - nothing at all), it never builds! It takes 7-10 minutes for "indexing" and then says "build failed" with one error: "Could not build module 'CoreData'".

It works fine if I switch the target to the (3.5-inch Retina iOS simulator) or (4-inch Retina iOS simulator). It does NOT work with (4-inch Retina 64-bit Simulator) or my iPhone 5c.

Any project with no Core Data option works fine on my iPhone 5c and the (4-inch Retina 64-bit Simulator). So, my profile and provisioning settings are all fine!

Any help?!


Solution

  • Go to Build Settings -> Architecture -> Architectures and change the option to standard architecture ( armv7 , armv7s ).

    Clean the project (CMD+Shift+K) and if it still not working, clean the derived data (see how: Can I safely delete contents of Xcode Derived data folder?)

    If it still doesn't work, try to remove the CoreData framework and add it again.