问题
My app has been working fine until Xcode 7.1. In fact, it still runs on both the simulator and iPhone, but when I archive it, I get the error "No such module Google." I have cocoa pods updated to 0.39 and have tried for hours with tweaking the options, from reinstalling cocoa pods to removing the Google Analytics cocoa pod and adding it manually, etc. However, nothing has worked, and whenever I archive the app, I receive an error, yet it still runs fine.
Any thoughts?
Thanks!
回答1:
Turns out the issue was with Google Analytics for cocoa pods. I completely removed the cocoapod and switched to Flurry.
回答2:
For me it turned out, that I had forgotten to put
use_frameworks!
into the Podfile
. After adding this line and updating the pods it worked. Just make sure to import
all modules in all depending classes.
Edit: Official blog resource from cocoapods
来源:https://stackoverflow.com/questions/33401842/xcode-will-build-run-but-archive-fails-with-no-such-module-google-swift-ios