JyT*_*Tee 61 xcode dyld ios xcode10.2
自更新以来,我一直在使用Xcode 10.2,当我尝试在iOS版本低于10的任何模拟器上运行我的应用程序时,模拟器将无法启动并崩溃,然后显示以下错误:
dyld:未加载库:/usr/lib/libauto.dylib引用自:/System/Library/Frameworks/Foundation.framework/Versions/C/Foundation原因:找不到合适的映像。确实找到了:/usr/lib/libauto.dylib:mach-o,但不是为iOS模拟器构建的
我尝试不碰任何东西重新创建另一个新项目,将部署目标设置为iOS 9,然后再次在iOS 9模拟器上运行,但显示了相同的错误。
更新
似乎仅当您的代码库包含swift时才会出现此问题。用目标C代码库创建一个新项目不会使模拟器崩溃。为了迅速。
摘要
有人有什么主意吗?
最后更新
苹果公司刚刚发布了Xcode 10.2.1,它是模拟器已知问题的一部分,有关变通办法/修复,请参考以下链接:
https://developer.apple.com/documentation/xcode_release_notes/xcode_10_2_1_release_notes
感谢@russbishop的回复,已接受回答
rus*_*hop 93
这是一个影响iOS 8.x和9.x的已知错误。您可以通过/usr/lib/swift
在相关的模拟器运行时根目录中创建目录来解决此问题。
下载的模拟器运行时位于中/Library/Developer/CoreSimulator/Profiles/Runtimes
。
例如,要修复iOS 9.3模拟器,请执行以下操作:
sudo mkdir '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.3.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift'
Run Code Online (Sandbox Code Playgroud)
iOS*_*iOS 10
在iOS 9.0模拟器中运行时,我也遇到了同样的问题。
From https://developer.apple.com/documentation/xcode_release_notes/xcode_10_2_1_release_notes
Simulators for iOS 9.3 and earlier might fail to launch Swift apps with the message: “dyld: Library not loaded: /usr/lib/libauto.dylib”. (49326587) Workaround: Run the following command in Terminal for the relevant version of iOS:
sudo mkdir '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.3.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift'
Run Code Online (Sandbox Code Playgroud)
For this apple given above solution in that link.
Simply
--> open Terminal
--> Type this line with your required version (In my case i changed into iOS 9.3 to iOS 9.0)
Ex: sudo mkdir '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.0.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift'
--> Enter password
--> Now clean Xcode and run again
This above solution worked for me.
归档时间: |
|
查看次数: |
8381 次 |
最近记录: |