由于手机升级了iOS 16.4,想要真机调试,Xcode 也要升级到 14.3, 于是就升级了一下。
升级Xcode 14.3之前,Debug 和 Archive 都没问题;升级 Xcode 14.3之后,Debug 没问题,Archive 就报错。错误信息如下:
<!--more-->
building file list ... rsync: link_stat "/Users/xxx/.../AFNetworking.framework" failed: No such file or directory (2)
done
sent 29 bytes received 20 bytes 98.00 bytes/sec
total size is 0 speedup is 0.00
rsync error: some files could not be transferred (code 23) at /AppleInternal/Library/BuildRoots/9e200cfa-7d96-11ed-886f-a23c4f261b56/Library/Caches/com.apple.xbs/Sources/rsync/rsync/main.c(996) [sender=2.6.9]
Command PhaseScriptExecution failed with a nonzero exit code
搜索Xcode 14.3 Archive failure when running Cocoapods build script phase
,可以看到CocoaPods已有issue在Xcode 14.3 beta时就有人发现了,结果Xcode 14.3正式版还是有问题。。。解决方案如下:
Command Line Tools
中改为Xcode 14.2编译,如下图: 找到...-frameworks.sh 文件,替换
source="$(readlink "${source}")"
为
source="$(readlink -f "${source}")"
很简单对吧,问题是,这个...-framework.sh在哪?我也不知道。
做法是:全局搜要替换的这段`source="$(readlink "${source}")"`,然后再把它替换为正确的`source="$(readlink -f "${source}")"`,再次编译即可成功。
原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。
如有侵权,请联系 cloudcommunity@tencent.com 删除。
原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。
如有侵权,请联系 cloudcommunity@tencent.com 删除。
扫码关注腾讯云开发者
领取腾讯云代金券
Copyright © 2013 - 2025 Tencent Cloud. All Rights Reserved. 腾讯云 版权所有
深圳市腾讯计算机系统有限公司 ICP备案/许可证号:粤B2-20090059 深公网安备号 44030502008569
腾讯云计算(北京)有限责任公司 京ICP证150476号 | 京ICP备11018762号 | 京公网安备号11010802020287
Copyright © 2013 - 2025 Tencent Cloud.
All Rights Reserved. 腾讯云 版权所有