include of non-modular header inside framework module

我在pod spec lint 一个新.podspec时报如下错误

- ERROR | xcodebuild: /Users/chengzi/Library/Developer/Xcode/DerivedData/App-gfxwqislxemhhpfwgugzhglmaocg/Build/Products/Release-iphonesimulator/Network/Network.framework/Headers/NetworkManager.h:10:9: error: include of non-modular header inside framework module Network.NetworkManager': '/Users/chengzi/Library/Developer/Xcode/DerivedData/App-gfxwqislxemhhpfwgugzhglmaocg/Build/Products/Release-iphonesimulator/AFNetworking/AFNetworking.framework/Headers/AFHTTPSessionManager.h' [-Werror,-Wnon-modular-include-in-framework-module]

原因就是 include of non-modular header inside framework module 你的文件中引入了 没有类库模块的头文件
因为我在NetworkManager 类中import AFHTTPSessionManager.h时,
直接用的#import "AFHTTPSessionManager.h",
改成#import "AFNetworking/AFHTTPSessionManager.h" 再次lint就可以了.

你可能感兴趣的:(include of non-modular header inside framework module)