-
Notifications
You must be signed in to change notification settings - Fork 19
Jan Niklas Hasse edited this page Aug 25, 2021
·
2 revisions
In your ios/Info.plist
file add
<key>CFBundleIconFiles</key>
<array>
<string>Icon-40.png</string>
<string>[email protected]</string>
<string>[email protected]</string>
<string>Icon-76.png</string>
<string>[email protected]</string>
<string>Icon-Small.png</string>
<string>[email protected]</string>
<string>Icon.png</string>
<string>[email protected]</string>
</array>
Resize your source icon file:
#!/bin/bash
set -eux
#!/bin/bash
set -eux
mkdir icons
convert logo1024.png -resize 57x57 icons/Icon.png
convert logo1024.png -resize 114x114 icons/[email protected]
convert logo1024.png -resize 29x29 icons/Icon-Small.png
convert logo1024.png -resize 58x58 icons/[email protected]
convert logo1024.png -resize 40x40 icons/Icon-40.png
convert logo1024.png -resize 80x80 icons/[email protected]
convert logo1024.png -resize 120x120 icons/[email protected]
convert logo1024.png -resize 76x76 icons/Icon-76.png
convert logo1024.png -resize 152x152 icons/[email protected]
In your CMakeLists.txt:
file(GLOB ios_icons "ios/icons/*.png")
set_source_files_properties(${ios_icons} PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
target_sources(your-executable PRIVATE ${ios_icons})