dyld: Library not loaded: @rpath/libswiftCore.dylib Referenced from: XXXX Reason: no suitable image found. Did find: /XXXX/Frameworks/libswiftCore.dylib: mmap() error 1 at address=0x1000F4000, size=0x0018C000 segment=__TEXT in Segment::map() mapping /private/var/mobile/Containers/Bundle/Application/930B04BF-8608-4075-A3B9-7FE2669F02BC/myTry.app/Frameworks/libswiftCore.dylib
解决经过:查找了https://stackoverflow.com/questions/26024100/dyld-library-not-loaded-rpath-libswiftcore-dylib
1.Restarting Xcode, iPhone, computer(无用)
2.Cleaning & rebuilding(无用)
3.Revoking and creating new certificate/provision profile(无用)
4.Runpath Search Paths is$(inherited) @executable_path/Frameworks(自己查看 本来就是这样的)
5.Embedded Content Contains Swift Code is 'Yes'(没找到这个东西)
6.Code Signing Identity is developer(本来就是)
经过以上失败后搜索到http://www.jianshu.com/p/d1b89a94588e这个发现有第三条没试过,就试了一下 真是我勒个擦,竟然成功了。具体是什么原因导致的结果 我也不知道。
真机环境9.3 Xcode环境Version 9.1 (9B55)
解决方法:找到 DerivedData 文件夹 删除 (路径: ~/Library/Developer/Xcode/DerivedData