我的项目与cocoapods 1.0.1和Alamofire分支“Swift3”配合得很好。 但是今天,我已经从Master branch将cocoapods更新到1.1.0,并将alamofire更新到4.0.1版本,但在x86-64(模拟器)构建中,我发现了链接器错误:
体系结构x86_64:Alamofire.Request的未定义符号(Alamofire.URLConvertible,方法:Alamofire.HttpMethod,参数:[Swift.String:Any]?,编码:Alamofire.ParameterEncoding,标题:[Swift.String:Swift.String]?) ->; Alamofire.DataRequest“,引用自
Swift.String:Alamofire.urlconvertible in Alamofire“的协议见证表,引用自:
但是对于设备(arm目标)来说,一切都很好。
试图解除对pod的整合,删除所有脚本和文件夹,然后重新安装--但没有帮助。
得到了解决办法:
必须手动删除derivedData并在清理后重新启动xCode。
(面部)
试试看
sudo gem install cocoapods --pre
然后再安装你的吊舱
或者,移除pod并改用Swift Package Manager。