我正在尝试从命令行构建一个包含app扩展的iOS应用程序.但是当我使用以下xcodebuild命令构建时:
xcodebuild -sdk iphoneos -configuration "Debug" -workspace "/Users/user/build/app_extension_demo/app_extension_demo.xcworkspace" -scheme "AppExtensionDemo" -CODE_SIGN_IDENTITY="iPhone Developer: ios developer" PROVISIONING_PROFILE=34070551-ebe8-412a-b57c-9fbdf9a42ed4 derivedDataPath "/Users/user/build/app_extension_demo/Build/Products/Debug-iphoneos" OBJROOT="/Users/user/build/app_extension_demo/Build/" SYMROOT="/Users/user/build/app_extension_demo/Build/Products" CONFIGURATION_BUILD_DIR=/Users/user/build/app_extension_demo/Build/Products/Debug-iphoneos
我收到以下错误:
ERROR: Code Sign error: Provisioning profile does not match bundle identifier: The provisioning profile specified in your build settings ("XC Ad Hoc: com.mycompany.AppExtensionDemo") has an AppID of "com.mycompany.AppExtensionDemo" which does not match your bundle identifier "com.mycompany.AppExtensionDemo.NumberWidget".
我正在使用appID为com.mycompany.AppExtensionDemo的配置文件(XC Ad Hoc:com.mycompany.AppExtensionDemo),但app扩展程序需要不同的AppID(com.mycompany.AppExtensionDemo.NumberWidget).通过Xcode应用程序完成所有功能.我注意到Xcode为app扩展目标自动创建了"com.mycompany.AppExtensionDemo.NumberWidget"的配置文件.但是,在通过命令行构建时,我不确定如何将应用程序扩展配置文件与应用程序扩展目标相关联.任何帮助,将不胜感激!