library not found for -lPods
Are you opening the workspace (that was generated by CocoaPods) instead of the xcodeproj?
I separated the app and the test targets in the Podfile by using
target :App do …endtarget :AppTests do …end
This resulted in two new products libPods-App.a and libPods-AppTests.a, respectively and they made the previous product libPods.a obsolete. I had to remove this product from the Link Binary With Libraries Section of the Build Phases configuration of both targets.
I ran into a similar problem today.
- I setup a new project
- I installed cocoa pods
- I created a new configuration
Preview
along with the existingDebug
andRelease
Now when compiling on this new
Preview
configuration, the compiler would not be able to link with Pods and giving me this message:ld: library not found for -lPods
The solution:
What I had to do was to run
pod install
again and thus configuring cocoapods for the new Preview
configuration. It updated my project, the workspace and the Pod's project file and the problem disappeared