在将Swift类添加到旧的Xcode项目后,我得到这个错误。
dyld:库未加载:@rpath/libswift_stdlib_core.dylib
我怎样才能使项目再次运行?
在将Swift类添加到旧的Xcode项目后,我得到这个错误。
dyld:库未加载:@rpath/libswift_stdlib_core.dylib
我怎样才能使项目再次运行?
当前回答
我的环境:Cocos2d 2.0, Box2d, Objective C
除了做上面的其他答案,我最后去了General选项卡,并使WatchKit可选。
其他回答
我也遇到过同样的问题,设置正确的代码签名标识解决了这个问题(构建设置->代码签名标识)。
根据苹果的技术问题,“iOS 8发布后创建的所有企业和标准iOS开发者证书在适当的位置都有新的团队ID字段,以允许Swift语言应用程序运行”
方案五:
在我的案例中,accws的答案中提到的所有解决方案都非常有用,但没有一个是有效的。我通过在项目目标的“General”部分的“Embedded Binaries”部分中添加我的swift库来解决我的问题。也许这是因为我在我的工作区中包含了我的swift框架?不管它现在编译什么!准备好,斯威夫特,我来了!
尝试按住Alt键,然后进入产品->清洁构建文件夹…
希望它能帮助到一些人。
参考https://forums.developer.apple.com/thread/21292
这个解决方案对我很有效:
It occurred on my side when building an app in the command line via xcodebuild and xcrun PackageApplication, signing the app with an enterprise profile. On our CI build servers, the certificate was set to "Always Trust" in the keychain (select certificate -> Get Info -> Trust -> "Use System Default" can be changed to "Always Trust"). I had to set it back to "Use System Default" in order to make this work. Initially we set this to "Always Trust" to work-around the keychain dialogs that appear after software updates and certificate updates.
我也有同样的问题。我的解决方案是将每个pod声明移动到目标子句中。
来自:
pod 'SomePod1'
pod 'SomePod2'
pod 'SomePod3'
target 'MyAwesomeApp', :exclusive => true do
end
To:
target 'MyAwesomeApp', :exclusive => true do
pod 'SomePod1'
pod 'SomePod2'
pod 'SomePod3'
end
我的猜测是,如果pod声明放在目标声明之外,CocoaPods(0.39.0)可能会使用错误的xcconfig。
Pods.debug.xcconfig (X
Pods-MyAwesomeApp.debug.xcconfig (O