我正在使用cocoapods version 1.9.1
和Xcode 11.3.1
我正在学习此教程https://docs.snapchat.com/docs/tutorials/login-kit/ios/
在IOS模拟器上运行我的应用程序时,我一直收到这个错误消息,说class
在两个版本中都实现了,问题出在CoreSimulator/Devices
Class SCSDKCertificateTrust is implemented in both
/Users/Developer/CoreSimulator/Devices/EB370499-8654-42DD-9FC0-
F7ACB17C0532/data/Containers/Bundle/Application/695ED9C1-3329-457C-BCED-
3670C52E4E19/Test.app/Frameworks/SCSDKLoginKit.framework/SCSDKLoginKit (0x1033dba50) and
/Users/Developer/CoreSimulator/Devices/EB370499-8654-42DD-9FC0-
F7ACB17C0532/data/Containers/Bundle/Application/695ED9C1-3329-457C-BCED-
3670C52E4E19/Test.app/Frameworks/SCSDKCoreKit.framework/SCSDKCoreKit (0x10339b098). One of
the two will be used. Which one is undefined.
我的播客文件
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
target 'Test' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for Test
pod 'SnapSDK'
end
我不知道如何解决这个问题,我已经在网上搜索,并找到了多种解决方案,特别是对SO
- Class is implemented in both. One of the two will be used
- Class is implemented in both, One of the two will be used. Which one is undefined
不幸的是,大多数的解决方案是关于修复它的.xcconfig
文件,并在OTHER_LDFLAGS.
中删除
我试过这两种方法都不行,难道是因为椰子的原因?
因为我在我的Xcode 10版本上尝试了这个方法,仍然产生了同样的问题
1条答案
按热度按时间laawzig21#
对于我来说:在Xcode中的文件导航器的顶部进入你的项目,然后点击包依赖项。删除任何你可能使用“添加包”而不是cocoapods安装的依赖项,或者可能导致错误的依赖项。