- oc项目中 报Could not find auto-linke
- oc项目中 报Could not find auto-linke
- Could not find or use auto-linke
- react-native run-ios : Could not
- Could not find 'ffi' (>= 1.3.0)
- Flutter使用Swift库与OC混编报错
- oc工程中使用swift 报Could not find aut
- 安卓开发解决Could not find method vers
- Cannot find protocol declaration
- react-native +dva的工程安装及配置
今日更新pod,完成之后编译报错如下
报错如图
查询确认应该是新的pod文件中有swift库,但是没有找到swift文件,所以编译报错
解决方案:
建立一个swift文件(空的文件也可以)就可以。
Build Options 中Embedded Content Contains Swift Code 改为 YES(Xcode 8.1 and earlier)
Always Embed Swift Standard Libraries 改为 YES(Xcode 8.2+)
允许 target 使用 swift 代码,开启这个配置后 Swift 的标准库将能够在该项目使用(注意:使用 oc和 swift 混编可能导致包体积变大十几兆)
特此记录










网友评论