问题描述

原来iOS持续集成环境使用的是Intel芯片,现由于性能及OS升级原因,重新购买了一个Apple M2芯片的集成环境,导致原来在执行xcode archive的时候,总是提示:

error:Provisioning Profile XXX doesn’t include current selected device “xxx”(identifier xxxxx).(in target xxxx from project xxxxx)

问题解决

一番折腾后,发现需要在构建命令中增加如下选项才可以:

 “-destination 'generic/platform=iOS'

完整的命令如下:

xcodebuild -workspace xxx.xcworkspace -scheme xxx -configuration Release archive 'CODE_SIGN_IDENTITY=xxxxxxx' PROVISIONING_PROFILE_SPECIFIER=xxxProfile DEVELOPMENT_TEAM=xxxx -archivePath ../Outputs/xxxx.xcarchive -derivedDataPath DerivedData -destination generic/platform=iOS

记之。

Logo

DAMO开发者矩阵,由阿里巴巴达摩院和中国互联网协会联合发起,致力于探讨最前沿的技术趋势与应用成果,搭建高质量的交流与分享平台,推动技术创新与产业应用链接,围绕“人工智能与新型计算”构建开放共享的开发者生态。

更多推荐