Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xamarin warning: The app icon set "AppIcons" has 2 unassigned children

I'm getting the following warning when compiling:

Warnings:

/Users/some-user/Projects/SomeApp/SomeApp/SomeApp.csproj (Build) -> /Library/Frameworks/Mono.framework/External/xbuild/Xamarin/iOS/Xamarin.iOS.Common.targets (_CoreCompileImageAssets target) ->

Resources/Images.xcassets: actool warning : The app icon set "AppIcons" has 2 unassigned children.

1 Warning(s)

I have provided each image for the app icons (except watch/car). There is no "unassigned" value in the Contents.json file. I also tried to unset every image and set it again. I'm still getting the warning.

Currently I'm using Xamarin Studio 5.9.7 (build 22), Xamarin.iOS 9.0.1.29 with Mono 4.0.4., Xcode 7.0.1 (8228) Build 7A1001. All this runs on Mac OS X 10.10.5.

How do I get the warning removed?

like image 884
testing Avatar asked Nov 04 '15 14:11

testing


2 Answers

If you have icons in .\AppIcons.appiconset folder that is not used/referenced in Contents.json file then you will the warning "The app icon set "AppIcons" has * unassigned children.". Look at all the icons in the folder and go through all the icons referenced in Contents.json then remove extra icons from the folder. Icons that is not referenced even though not included in the project will result in the compiler warning.

like image 157
HankCh Avatar answered Nov 15 '22 20:11

HankCh


iOS 9.2.1, Xcode 7.2.1, ARC enabled

If the JSON file looks good, then the asset catalog might just be corrupt; this sometimes happens when you drag and drop files in and maybe accidentally removing a file from the folder at path, or changing the path in Xamarin for the asset.

Either way, see if Xamarin has some sort of way of deleting the asset catalog and adding it in again, then specifying what iOS target and device your app is going to run on to configure the asset catalog correctly.

You will have to add each asset again to the asset catalog once the catalog is set up.

Hope this helps. Cheers!

like image 26
serge-k Avatar answered Nov 15 '22 19:11

serge-k