I have a similar issue with the app icons for an Apple Watch app. I have two targets:
App target (iOS and macOS)
Watch Target
and two separate Asset catalogs for the targets.
In App target I have the AppIcon as all sizes (macOS, iOS and watchOS).
In Watch target I have AppIcon as single size (1024x1024, watchOS only)
(That's what I believe https://developer.apple.com/tutorials/swiftui/creating-a-watchos-app have on step 7.)
When building the app for a real iOS device using Run in Xcode the Watch target build fails with "Command CompileAssetCatalog failed with a nonzero exit code" with this approach.
Removing the watchOS single size 1024x1024 image from it's Asset catalog in AppIcon without removing the AppIcon set and still have the watchOS single size (but without image, just empty) fixes the issue and the build succeeds.
I'm using Xcode Cloud, and building with the image in the watchOS Asset catalog doesn't fail, and you can sue the build for TestFlight, but trying with archive fails with the same error as running the project in Xcode.
Xcode 15.4 macOS 14.3.1
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags: