Reputation: 3008
I have an existing iOS app which uses a framework which uses some CocoaPods. I added a WatchKit App target then added the framework to "Embedded Binaries". At this point, everything still compiles and runs. As soon as I import anything from the framework into the WatchKit extension though, I get an error that says
Could not build module 'FrameworkName'.
When I build, another error comes up inside one of the framework files:
'AFNetworking/AFNetworking.h' file not found.
Upvotes: 3
Views: 457
Reputation: 20177
Versions of AFNetworking prior to v2.6 would not support WatchOS without modification—see the AFNetworking requirements. As v2.6 was released after this question was posted, this seems certain to be the cause of the issues you were experiencing.
Upvotes: 1
Reputation: 5536
pod init
again so that CocoaPods generates new targets for your Podfile
.
Add your dependencies to both your main app and to your extension in the Podfile
.
Upvotes: 0