Apple M1芯片 自动打包问题解决方案 Xcode 12 iOS 打包失败

iOS Apple 设备更换为M1芯片后,iOS 项目自动化打包报错

关键词 "Provisioning profile "iOS Team Provisioning Profile" doesn't include the currently selected device "xxx's MacBook Pro"

以下为报错的常见内容,一般是配置文件内不包含打包的 Mac 本机

"Provisioning profile "iOS Team Provisioning Profile" doesn't include the currently selected device "xxx's MacBook Pro" 
"Provisioning profile "iOS Team Provisioning Profile" doesn't include the currently selected device "Mac Mini" 

解决方案

修改 jenkins 脚本 或者 本地打包脚本,在对应的 xcodebuild 命令后添加对应参数

'generic/platform=iOS'

如下所示

xcodebuild archive -workspace $project_name.xcworkspace -scheme $scheme_name -configuration $build_configuration -archivePath $export_archive_path -destination 'generic/platform=iOS'

使用 jenkins 配置参数打包,如下图修改

image.png

完美解决 ~

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容