q***@yw11.com
q***@yw11.com
  • 发布:2025-12-17 09:39
  • 更新:2025-12-17 09:40
  • 阅读:19

打ios正式包出现 Apple Pay 或 In-App Payments与描述文件不匹配 导致打包失败,有人遇到过?求解决

分类:uni-app

打ios正式包出现 Apple Pay 或 In-App Payments与描述文件不匹配 导致打包失败,但是我Apple Developer 后台 已经配置了Apple Pay Payment Processing,Payments描述文件也正确指向了,就是打包不成功。

Command line invocation:
/Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild archive -sdk iphoneos18.1 -project [PackagePath]/HBuilder.xcodeproj -archivePath [PackagePath]/XArchive/HBuilder.xcarchive -scheme HBuilder -configuration Release

User defaults from command line:
IDEArchivePathOverride = [PackagePath]/XArchive/HBuilder.xcarchive
IDEPackageSupportUseBuiltinSCM = YES

Build settings from command line:
SDKROOT = iphoneos18.1

Prepare packages

ComputeTargetDependencyGraph
note: Building targets in dependency order
note: Target dependency graph (1 target)
Target 'HBuilder' in project 'HBuilder' (no dependencies)

GatherProvisioningInputs

CreateBuildDescription

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -v -E -dM -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS18.1.sdk -x objective-c -c /dev/null

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/usr/bin/ibtool --version --output-format xml1

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -v -E -dM -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS18.1.sdk -x c -c /dev/null

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/usr/bin/actool --print-asset-tag-combinations --output-format xml1 [PackagePath]/HBuilder/Assets.xcassets

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/usr/bin/actool --version --output-format xml1

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc --version

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld -version_details

ExecuteExternalTool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -v -E -dM -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS18.1.sdk -x c -c /dev/null

Build description signature: 135e9b09facc544442727915ea5c3d87
Build description path: /Users/[Name]/Library/Developer/Xcode/DerivedData/HBuilder-elkcgryvqranreavmuimxkmfdgtg/Build/Intermediates.noindex/ArchiveIntermediates/HBuilder/IntermediateBuildFilesPath/XCBuildData/135e9b09facc544442727915ea5c3d87.xcbuilddata
[PackagePath]/HBuilder.xcodeproj: error: Provisioning profile \"qmw\" doesn't match the entitlements file's value for the com.apple.developer.in-app-payments entitlement. Profile qualification is using entitlement definitions that may be out of date. Connect to network to update. (in target 'HBuilder' from project 'HBuilder')
note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'HBuilder' from project 'HBuilder')
warning: Run script build phase 'Run Script' will be run during every build because it does not specify any outputs. To address this issue, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'HBuilder' from project 'HBuilder')--- xcodebuild: WARNING: Using the first of multiple matching destinations:
{ platform:iOS, id:dvtdevice-DVTiPhonePlaceholder-iphoneos:placeholder, name:Any iOS Device }
{ platform:macOS, arch:arm64, variant:Designed for [iPad,iPhone], id:00008112-001214A41AFB401E, name:My Mac }
{ platform:iOS Simulator, id:dvtdevice-DVTiOSDeviceSimulatorPlaceholder-iphonesimulator:placeholder, name:Any iOS Simulator Device }
{ platform:iOS Simulator, id:9792BF79-55A3-464B-BCC4-8FC5553530ED, OS:18.1, name:iPhone 16 }
{ platform:iOS Simulator, id:9792BF79-55A3-464B-BCC4-8FC5553530ED, OS:18.1, name:iPhone 16 }
{ platform:iOS Simulator, id:FAC75CB8-1EC1-4FB5-8324-EE9A612ECB9B, OS:18.1, name:iPhone 16 Plus }
{ platform:iOS Simulator, id:FAC75CB8-1EC1-4FB5-8324-EE9A612ECB9B, OS:18.1, name:iPhone 16 Plus }
{ platform:iOS Simulator, id:AB6D4465-81D1-4AF2-985E-F2A1C9B6C2F8, OS:18.1, name:iPhone 16 Pro }
{ platform:iOS Simulator, id:AB6D4465-81D1-4AF2-985E-F2A1C9B6C2F8, OS:18.1, name:iPhone 16 Pro }
{ platform:iOS Simulator, id:511D2F9C-27B8-4D6D-9286-680201248FA4, OS:18.1, name:iPhone 16 Pro Max }
{ platform:iOS Simulator, id:511D2F9C-27B8-4D6D-9286-680201248FA4, OS:18.1, name:iPhone 16 Pro Max }
{ platform:iOS Simulator, id:0AC78C3F-3568-4E22-BF08-AA07F1DDA01F, OS:18.1, name:iPhone SE (3rd generation) }
{ platform:iOS Simulator, id:0AC78C3F-3568-4E22-BF08-AA07F1DDA01F, OS:18.1, name:iPhone SE (3rd generation) }
ARCHIVE FAILED The following build commands failed:
Archiving project HBuilder with scheme HBuilder
(1 failure)

2025-12-17 09:39 负责人:无 分享
已邀请:
Ask小助手

Ask小助手 - Ask社区AI助手

您的问题是由于Provisioning Profile与Entitlements文件中的Apple Pay配置不一致导致的。解决方案如下:

  1. 登录Apple Developer后台,确认已正确添加Apple Pay Merchant ID(在"Certificates, Identifiers & Profiles" > "Identifiers" > 您的App ID中启用Apple Pay并关联Merchant ID)

  2. 必须重新生成Provisioning Profile:修改配置后需要重新生成并下载Provisioning Profile(选择包含In-App Payments权限的Distribution类型),旧Profile不会自动更新

  3. 在HBuilderX中检查manifest.json的ios配置:

    "ios": {  
    "entitlements": "platforms/ios/YourApp.entitlements"  
    }

    确保entitlements文件包含正确的Apple Pay配置:

    <key>com.apple.developer.in-app-payments</key>  
    <array>  
    <string>merchant.com.yourcompany.app</string>  
    </array>
  4. 清理项目后重新打包:删除platforms/ios目录,执行"清理缓存并重新编译"

注意:uni-app项目需在platforms/ios目录下维护自定义的entitlements文件,云端打包时需确保上传了正确的Provisioning Profile。如果使用HBuilderX 4.85+版本,可尝试在"manifest.json可视化界面"的iOS配置中重新指定Provisioning Profile。

参考iOS打包文档:iOS离线打包教程

内容为 AI 生成,仅供参考

要回复问题请先登录注册