使用应用程序加载器提交应用程序时“缺少所需的图标”

问题描述 投票:0回答:6

使用 Application Loader 工具提交我的申请时,出现以下错误:

ERROR ITMS-90236: "Missing required icons. 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."

我的图标(由 Info.plist 文件引用)包含这两个文件,因为它是使用以下命令创建的:

iconutil -c icns icon.iconset

其中 icon.iconset 文件夹包含以下项目:

-rw-r--r--   1 martin  staff    11K 18 mai 11:24 icon_128x128.png
-rw-r--r--   1 martin  staff    23K 18 mai 11:24 [email protected]
-rw-r--r--   1 martin  staff   3,3K 18 mai 11:24 icon_16x16.png
-rw-r--r--   1 martin  staff   4,2K 18 mai 11:24 [email protected]
-rw-r--r--   1 martin  staff    23K 18 mai 11:24 icon_256x256.png
-rw-r--r--   1 martin  staff    48K 18 mai 11:24 [email protected]
-rw-r--r--   1 martin  staff   4,2K 18 mai 11:24 icon_32x32.png
-rw-r--r--   1 martin  staff   6,6K 18 mai 11:24 [email protected]
-rw-r--r--   1 martin  staff    48K 18 mai 11:24 icon_512x512.png
-rw-r--r--   1 martin  staff    92K 18 mai 11:24 [email protected]

我的图标可能有什么问题?

编辑

我的Info.plist文件:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>CFBundleExecutable</key>
    <string>Joker</string>
    <key>CFBundleGetInfoString</key>
    <string>Created by Qt/QMake</string>
    <key>CFBundleIconFile</key>
    <string>Joker.icns</string>
    <key>CFBundleIdentifier</key>
    <string>com.phonations.joker</string>
    <key>CFBundlePackageType</key>
    <string>APPL</string>
    <key>CFBundleShortVersionString</key>
    <string>15.05.25</string>
    <key>CFBundleSignature</key>
    <string>???</string>
    <key>CFBundleVersion</key>
    <string>15.05.25</string>
    <key>LSApplicationCategoryType</key>
    <string>public.app-category.video</string>
    <key>NOTE</key>
    <string>This file was generated by Qt/QMake.</string>
    <key>NSHighResolutionCapable</key>
    <string>True</string>
    <key>NSPrincipalClass</key>
    <string>NSApplication</string>
</dict>
</plist>
macos icons application-loader icns
6个回答
3
投票

我遇到了同样的问题,并通过将我的 icns 文件转换为 inconset 文件夹,然后使用

icontool
返回到 icns 格式来解决它。然后应用程序加载器不再抱怨。

只需尝试更新您的系统(命令行工具)并使用以下命令将

icon.icns
重新生成为
icon_new.icns
:

ICON_OLD=icon.icns
ICON_NEW=icon_new.icns
icontool -c iconset -o "${ICON_OLD%.icns}.iconset" "$ICON_OLD"
icontool -c icns -o "$ICON_NEW" "${ICON_OLD%.icns}.iconset"

最初我使用在线转换器https://iconverticons.com/online/从png图像创建了icns文件,这对我来说一直很有效。当我将 icns 转换为 iconset 时,图标文件看起来不错,但将其转换回 icns 后,icns 文件大小比在线工具生成的 icns 文件大 2 倍。奇怪的是,当我再次将较大的 icns 转换回 iconset 时,两个 iconset 目录都包含相同的文件列表。

这可能是由于 icontool 和应用商店要求的一些更新引起的,这些更新尚未应用于在线转换器的系统。


2
投票

即使您的主应用程序图标正确,您也可能会收到此错误。就我而言,有文档图标(也从 Info.plist 引用)没有所需的 512x512@2x 分辨率。

有趣的是,如果文档图标被简单地删除/丢失,验证过程不会抱怨。

此错误消息是正确的:“应用程序包确实包含 ICNS 格式的图标,不包含 512x512 和 512x512@2x 图像。”


1
投票

解决图标问题的步骤:-

1.首先创建一个文件夹并将其重命名为“icon.iconset”。

2.将尺寸为1024x1024的图像复制到该文件夹中 3.右键单击该图像将png转换为icns格式。如果没有该选项,只需下载 Automator 应用程序。 4.您将获得icon.icns。将此 icns 图像放入 resources 文件夹中(替换它) 5. 在package.json中添加路径 注意:图片必须是正方形且背景透明(1024x1024)


1
投票

当我尝试向应用程序商店提交一个非常旧的应用程序时,就发生了这种情况。当我在

General
中选择应用程序目标
Project-Settings
设置时,
App Icons
部分显示了一个“转换为资产”按钮。一旦我这样做了,图标就会从资产目录中使用,它比旧的 icns 文件效果更好。


0
投票

如果配置了所有图标但没有任何帮助。

可能 XCode 版本 15.4 (15F31d) 有错误。

如果您重命名或重新定位

Assets.xcassets
- 将无法发布带有此错误的应用程序。

我认为有两种方法可以解决:

  1. 尝试将“Preview Content/Preview Assets.xcassets”放回您的项目中并更改回构建设置。 (不确定有没有帮助)

  2. 重新创建工作区/项目。将所有代码移至此项目。在发布到应用商店之前,请勿触摸设置和默认文件结构。当它发布时,请逐步更改项目结构的所有所需更改。并发布到

    appStoreConnect
    。直到您看到错误为止。在此之后丢弃发生变化。 (绝对有帮助)


-1
投票

在您的 xcode 中,从工作区左上角选择 Runner > Runner > Assets。

跑步者 > 跑步者 > 资产

您可能会注意到列表中有一个空的“图标列表项”。 双击空图标并浏览到图标文件的位置并单击选择。

© www.soinside.com 2019 - 2024. All rights reserved.