2

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?!

CSawy
  • 904
  • 2
  • 14
  • 25
  • Why does the build fail? Post the errors the prevent the app from running. – Sebyddd Aug 20 '14 at 20:53
  • I updated the question. It says "Could not build module 'CoreData'". Thanks. – CSawy Aug 20 '14 at 21:17
  • Try this, create a master-detail project template. Change the target to iOS 7 and see if everything doesn't work at that point. Make sure that works. Next remove the stuff you don't want from the storyboard. If you want to work without a storyboard then just dump it but be prepared to rebuild your initialization classes. – Tommie C. Aug 20 '14 at 21:32
  • Tommie, Thanks for answering but the project was already empty. The approved answer below solved it. Thanks you though :) – CSawy Aug 21 '14 at 18:49

1 Answers1

2

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.

Community
  • 1
  • 1
Sebyddd
  • 4,305
  • 2
  • 39
  • 43
  • 1
    Sebyddd, you saved my life! THANKS! I found that the architecture option was set to standard so I didn't change that. But deleting the derived data made it! Thanks, man :) – CSawy Aug 20 '14 at 22:14