0

I recently added the Social.framework and Accounts.framework to my ios project. It was placed on top of the navigator area and I dragged those two into the frameworks folder. Then it showed in red color in the Build Phases "Link Binary with Libraries" ....and now the project crashes on startup.

What did I do so wrong? And what is the correct way to fix this?

I get this error:

dyld: Library not loaded: /System/Library/Frameworks/Social.framework/Social
  Referenced from: /Users/owner12/Library/Application Support/iPhone Simulator/5.1/Applications/823A0485-7443-4206-B9F5-A84C03DBFB89/BusinessPlan.app/BusinessPlan
  Reason: image not found
Genadinik
  • 18,153
  • 63
  • 185
  • 284

1 Answers1

1

You didn't do anything wrong. Sometimes Xcode gets confused. I would suggest that you edit the project, scroll down to where it lists the frameworks, and select the Social and Accounts frameworks and click the Minus button.

enter image description here

After that, you might want to quit Xcode and clean out the build folder as described here:

How to Empty Caches and Clean All Targets Xcode 4

If that doesn't solve it, you might have to revert to an earlier commit.

Community
  • 1
  • 1
matt
  • 515,959
  • 87
  • 875
  • 1,141
  • Also there is a very helpful answer here: http://stackoverflow.com/a/9494112/341994 Sometimes the project file is corrupted and you have to open it and get rid of the user settings – matt Apr 25 '13 at 01:55
  • thank you - the first solution didn't quite work so I am going to try now your second suggestion. I also posted my error in my original question – Genadinik Apr 25 '13 at 02:00
  • The error message tells us that the reference is still in there. Did you clean the derived data folder *and* delete the app from all simulators and devices?? – matt Apr 25 '13 at 02:04
  • I tried different variations of your original suggestions and then it worked :) – Genadinik Apr 25 '13 at 02:06
  • I know, sometimes you have to keep hitting Xcode on the side of the head. – matt Apr 25 '13 at 02:07
  • Thank you - you have helped me many times with my iOS adventures. Do you have apps of your own? – Genadinik Apr 25 '13 at 02:07
  • let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/28853/discussion-between-genadinik-and-matt) – Genadinik Apr 25 '13 at 02:08