我试图在我的 iPhone 上运行我的 iOS 应用程序。项目编译得很好。但是当应用程序启动时,XCode 控制台显示:
dyld: Library not loaded: @rpath/Runes.framework/Runes
Referenced from: /private/var/mobile/Containers/Bundle/Application/CC8759F5-A501-400C-93A8-DCEE3BFE4770/XXX.app/XXX
Reason: Incompatible library version: XXX requires version 2.0.0 or later, but Runes provides version 1.0.0
我使用 Cocoapods,我的 Podfile 看起来像:
platform :ios, '8.0'
use_frameworks!
pod 'SnapKit', '~> 0.12.0'
pod 'Alamofire', '~> 1.2'
pod 'SwiftTask', '~> 3.3'
pod 'Argo'
pod 'Async', :git => 'https://github.com/duemunk/Async.git', :commit => '9e64046b767fe11010891f5b7fe2aed613a6ee55'
pod 'TapLabel', '0.0.3'
pod 'RealmSwift'
pod 'Kingfisher', '~> 1.4'
我该怎么办?在模拟器上一切正常。
最佳答案
是否有可能您使用的 CocoaPods 版本早于 0.38.2?
如果是这样,请使用 sudo gem install cocoapods
更新到 0.38.2 并在您的项目上运行 pod install
。
有 a recent bugfix处理链接器build设置中的非法版本号。
作为解决方法,您可以在 Build Settings -> Linker -> Compatibility Version
下的 pod 目标中手动将“Runes”pod 的版本设置为 2
关于ios - 不兼容的库版本 : XXX requires version 2. 0.0 或更高版本,但 Runes 提供版本 1.0.0,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31634407/