步骤如下
1. 执行以下,生成 Xcode 项目文件
qmake -spec macx-xcode
2. 使用 Xcode 打开项目
执行 Product->Archive
过程中会提示生成各种证书
Validate 通过后就可以提交了
碰到的问题
版本问题
错误信息
App Store Connect Operation Error
The Info.plist in the package must contain the CFBundleVersion key.
App Store Connect Operation Error
The Info.plist in the package must contain the CFBundleShortVersionString key.
解决方法
在文件 Info.plist 手动增加以下字段
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
沙箱
错误信息
App Store Connect Operation Error
App sandbox not enabled. The following executables must include the "com.apple.security.app-sandbox" entitlement with a Boolean value of true in the entitlements property list: [( "com.alithon.miniterminal.pkg/Payload/MiniTerminal.app/Contents/MacOS/MiniTerminal" )] Refer to App Sandbox page at https://developer.apple.com/devcenter/mac/app-sandbox/ for more information on sandboxing your app.
解决方法
添加 Sandbox
图标
错误信息
App Store Connect Operation Error
Missing required icon. The application bundle does not contain an icon in ICNS format, containing both a 512x512 and a 512x512@2x image. For further assistance, see the Apple Human Interface Guidelines at https://developer.apple.com/macos/human-interface-guidelines/icons-and-images/app-icon
解决方法
找到一个 1024x1024的图片,执行以下生成对应大小的图片
sips-z1616pic.png--outicons.iconset/icon_16x16.pngsips-z3232pic.png--outicons.iconset/icon_16x16@2x.pngsips-z3232pic.png--outicons.iconset/icon_32x32.pngsips-z6464pic.png--outicons.iconset/icon_32x32@2x.pngsips-z6464pic.png--outicons.iconset/icon_64x64.pngsips-z128128pic.png--outicons.iconset/icon_64x64@2x.pngsips-z128128pic.png--outicons.iconset/icon_128x128.pngsips-z256256pic.png--outicons.iconset/icon_128x128@2x.pngsips-z256256pic.png--outicons.iconset/icon_256x256.pngsips-z512512pic.png--outicons.iconset/icon_256x256@2x.pngsips-z512512pic.png--outicons.iconset/icon_512x512.pngsips-z10241024pic.png--outicons.iconset/icon_512x512@2x.png
然后逐个拖到AppIcon里即可