首页 > 解决方案 > Xcode 11.5 中的 Firebase 链接器警告

问题描述

Firebase (6.25.0) FirebaseAnalytics (6.5.1) FirebaseCore (6.7.1) macOS Catalina (10.15.4) Xcode 11.5

我在我的 Xcode 工作区中通过 CocoaPods 更新了 Firebase SDK,并开始收到几个 Xcode 链接器 (ld) 警告,这些警告都归结为这两个的变体:

  1. ld:警告:来自归档文件名/对象文件名的类别中的实例方法方法名与来自另一个类别的相同方法冲突

例子:

ld: warning: instance method 'registeredInstallationWithJSONData:date:error:' in category from /Users/andy/Library/Developer/Xcode/DerivedData/myapp-frvtlafpkeliluaxjjycfjdpboxi/Build/Intermediates.noindex/ArchiveIntermediates/myapp/BuildProductsPath/Release-iphoneos/FirebaseInstallations/libFirebaseInstallations.a(FIRInstallationsItem+RegisterInstallationAPI 2.o) conflicts with same method from another category
  1. ld:警告:归档文件名/对象文件名类别中的元方法方法名与另一个类别中的相同方法冲突

例子:

ld: warning: meta method 'validStringOrNilForKey:fromDict:' in category from /Users/andy/Library/Developer/Xcode/DerivedData/myapp-frvtlafpkeliluaxjjycfjdpboxi/Build/Intermediates.noindex/ArchiveIntermediates/myapp/BuildProductsPath/Release-iphoneos/FirebaseInstallations/libFirebaseInstallations.a(FIRInstallationsItem+RegisterInstallationAPI 2.o) conflicts with same method from another category

我已经尝试过干净的构建和清理/重新安装 pod 缓存,但继续收到这些警告。这些似乎不会损害应用程序的执行,但我想清除它们。我最近将 Xcode 更新到 11.5,所以这可能是一个因素(Xcode 11.5 也开始显示Ads SDK 的其他类型的链接器警告)。

标签: iosobjective-cxcodefirebaselinker-warning

解决方案


推荐阅读