Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fails with transparent image for iOS icon #4930

Open
Gys opened this issue Jun 11, 2024 · 3 comments
Open

Build fails with transparent image for iOS icon #4930

Gys opened this issue Jun 11, 2024 · 3 comments

Comments

@Gys
Copy link

Gys commented Jun 11, 2024

Describe the bug:

I tried to cross compile an app to ios.
I received this error:

/* com.apple.actool.errors */
[REDACTED PATH]/Images.xcassets: error: The stickers icon set or app icon set named "AppIcon" did not have any applicable content.
/* com.apple.actool.compilation-results */
/dev/null

: exit status 1

Searching for this error shows xcode expects the file Images.xcassets to exist and hold assets like icons. I understand Fyne creates these icons 'on the fly' so maybe my icon image was a problem. I changed it for another one and the error was resolved. The 'badlogo.png' is no problem if compiled to 'darwin' (on MacOS).

So the attached 'badlogo.png' is not usable for some reason. This was just a test logo for me, so I simple replaced it with another logo.

Maybe the docker image logs would have shown some more clear information or errors. Now it took some time before I realized the image file could be a problem. I have no idea though how to retrieve the logs or a more verbose output?

To Reproduce:

Steps to reproduce the behavior:
Download the 'badlogo.png' image file.
Create a simple app and compile with:
fyne-cross ios -icon badlogo.png -app-id my.test.app

(Using fyne package results in the same error)

Device and debug info (please complete the following information):

Device info
  • OS: MacOS
  • Version: Sonoma 14.5
  • Go version: go1.21.5 darwin/amd64
  • fyne-cross version: 1.5
  • Fyne version: 2.4.5

badlogo.png.zip

@Gys Gys changed the title Not all images are accepted as icons Not all images are accepted as icons (iOS) Jun 11, 2024
@andydotxyz
Copy link
Member

Perhaps you used transparency? That is not allowed by Apple's rules sadly - but will work on any other OS.

@Gys
Copy link
Author

Gys commented Jun 12, 2024

Aha, did not know that! Yes, the logo has transparency. It took me a while to realize the logo was the problem, especially because it indeed is no problem for Darwin and Windows. Maybe some code can be added to check for transparency? For example: https://stackoverflow.com/questions/68747745/check-if-png-image-is-all-transparent-in-golang

@Gys Gys closed this as completed Jun 12, 2024
@andydotxyz
Copy link
Member

Good plan, updating and re-opening to track

@andydotxyz andydotxyz reopened this Jun 12, 2024
@andydotxyz andydotxyz changed the title Not all images are accepted as icons (iOS) Build fails with transparent image for iOS icon Jun 12, 2024
@andydotxyz andydotxyz transferred this issue from fyne-io/fyne-cross Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants