【问题标题】:Cannot compile app with Carthage dependencies after Xcode updateXcode 更新后无法编译具有 Carthage 依赖项的应用程序
【发布时间】:2022-01-27 21:34:19
【问题描述】:

Xcode 自动更新到版本 13.2.1 后,我无法使用 Carthage 依赖项管理器构建项目。 从这里得到一个框架:https://gitlab.com/trustpayments-public/mobile-sdk/ios 我收到以下错误: Module compiled with Swift 5.5 cannot be imported by the Swift 5.5.2 compiler

我尝试重建框架并将项目设置中的Build libraries for distribution标志设置为No,但它返回了不允许桥接头的错误。

有什么想法吗?

附:我设法使用 CocoaPods 构建了应用程序,但环境要求迫使我在我的 iOS 项目中继续使用 Carthage。

【问题讨论】:

  • 你用来构建外部框架的carthage 命令是什么?
  • Carthage update --platform ios --use-xcframeworks

标签: ios swift xcode carthage trustkit


【解决方案1】:

好的,我设法编译了我的项目。 步骤:

  1. 删除../Carthage/Build folder
  2. 运行 xcodebuild -version 并检查它是否是最新的。
  3. 运行carthage build --platform ios --use-xcframeworks --no-use-binaries

【讨论】:

    猜你喜欢
    • 2020-12-01
    • 2022-07-08
    • 1970-01-01
    • 2019-06-09
    • 2015-12-16
    • 1970-01-01
    • 2017-05-13
    • 1970-01-01
    • 2019-07-21
    相关资源
    最近更新 更多