ios - Xcode v12.5 - 打开 SQlite DB 时生成错误
问题描述
在将 Xcode 从 v12.4 升级到 12.5 后,在 React-Native 项目上工作,出现构建错误。曾经在 Xcode v12.4 中完美运行
我已经缩小到导致此构建错误的行:
var db: OpaquePointer?
let _path = path ?? "widgetdb.sqlite3";
sqlite3_open(_path, &db) <-- This is the culprit!
错误日志:
Undefined symbols for architecture x86_64:
"Swift._ArrayBuffer._copyContents(initializing: Swift.UnsafeMutableBufferPointer<A>) -> (Swift.IndexingIterator<Swift._ArrayBuffer<A>>, Swift.Int)", referenced from:
generic specialization <serialized, Swift._ArrayBuffer<Swift.Int8>> of Swift._copyCollectionToContiguousArray<A where A: Swift.Collection>(A) -> Swift.ContiguousArray<A.Element> in SQLiteDatabase.o
任何帮助将不胜感激!谢谢!!
解决方案
今天遇到类似的问题,但错误是 Alamofire
就我而言,我通过删除解决了它
"\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)\""
来自项目搜索路径中的 LIBRARY_SEARCH_PATHS
推荐阅读
- css - 如何隐藏没有 id 或类的元素数据绑定
- python-3.x - Kepp 在运行 model.fit() 时收到 ValueError 错误类型
- c# - 如何将两个 SerializeObject 转换为一个 SerializeObject
- excel - 查找和替换 VBA
- python - 在函数中计算返回的钱并返回一个字典,其中货币值作为键,金额作为值
- r - 在日期间隔或 NA 内过滤观察结果
- r - 固定效果 logit:R 中调整后的 r square-bife 包
- python - 寻找零和的三元组
- qt - QML 使用类型 int 或 real
- swift - 聊天火力基地结构