1、打包上传到App Store Connect的时候
- 非Xcode16可以正常上传成功,但邮件会给出以下提示:
【意思就是April 24, 2025之前升级到最新的Xcode再进行上传】
ITMS-90725: SDK version issue - This app was built with the iOS 17.4 SDK.
Starting April 24, 2025, all iOS and iPadOS apps must be built with the iOS 18 SDK or later,
included in Xcode 16 or later, in order to be uploaded to App Store Connect or submitted for distribution.
- Xcode16在上传时,直接会报以下错误:
ERROR: Validation failed - Unsupported SDK or Xcode version. Your app was built with an SDK or version of Xcode that isn’t supported. Although you can use beta versions of SDKs and Xcode to build and upload apps to App Store Connect, you need to use the latest Release Candidates (RC) for SDKs and Xcode to submit the app. For details on currently supported SDKs and versions of Xcode, visit: https://developer.apple.com/news/releases. - STATE_ERROR.VALIDATION_ERROR
正常情况下只要升级到最新的Xcode16,比如16.2版本以上问题就会自动解决。
2、升级到Xcode16.2打包遇见问题:contains incomplete bitcode
Validation failed (409)
Invalid Bundle Executable. The executable file 'SaasApp-Release.app/Frameworks/ZegoSampleBufferConverter.framework/ZegoSampleBufferConverter' contains incomplete bitcode.
To compile binaries with complete bitcode, open Xcode and choose Archive in the Product menu. (ID: 51d83e7c-b1c8-4b59-8c07-974299324225)
解决方案:
1、找到出现问题的Frameworks路径,放到下面数组中 framework_paths
2、在Podfile中 post_install do |installer|添加以下脚本代码:
bitcode_strip_path = `xcrun --find bitcode_strip`.chop!
def strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
framework_path = File.join(Dir.pwd, framework_relative_path)
command = "#{bitcode_strip_path} #{framework_path} -r -o #{framework_path}"
puts "Stripping bitcode: #{command}"
system(command)
end
framework_paths = [
"Pods/WCRLiveCore/Frameworks/ZegoSampleBufferConverter.framework/ZegoSampleBufferConverter",
"Pods/AgoraRtm_Special_iOS/AgoraRtmKit.framework/AgoraRtmKit",
"Pods/NIMSDK_XES/NIMSDK/NIMSDK.framework/NIMSDK",
"Pods/TXIMSDK_iOS/ImSDK.framework/ImSDK",
"Pods/WCRLiveCore/Frameworks/NERtcSDK.framework/NERtcSDK"
]
framework_paths.each do |framework_relative_path|
strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
end
3、重新执行pod install后,重新Archive上传即可。
注意:如果不生效,建议删除Pods中有问题的framework,再执行pod install。
4、手动操作参考:
xcrun bitcode_strip -r ${framework_path} -o ${framework_path}