[KDE/Mac] Review Request 125649: [OS X] install icon resources in app bundles where this doesn't happen automatically

Friedrich W. H. Kossebau kossebau at kde.org
Fri Oct 16 00:00:43 UTC 2015



> On Oct. 15, 2015, 10:30 p.m., Friedrich W. H. Kossebau wrote:
> > `Q_WS_MAC` is not a cmake var, or? Seems someone accidentally used the c++ macro/define here, and noone ever noticed? :)
> > 
> > In Qt5/KF5/ECM worlds ecm_add_app_icon does the respective installation, right? So only the `Q_WS_MAC` fix will need porting to the master branch?
> 
> René J.V. Bertin wrote:
>     No, Q_WS_MAC is not something that cmake provides by default, so I guess you're right. 
>     
>     Do calligragemini and calligraauthor get icons on Linux? For the former it seems that that should only be the case if the icon .png file(s) is/are already installed, but if that's the intended behaviour shouldn't my patch be Mac-specific? Calligraauthor's `kde4_add_app_icon` call is commented out, was that intended or should that patch *not* be Mac-specific?
>     
>     I have no idea at the moment what has changed in KF5/ECM. If ECM provides a function `ecm_add_app_icon` then it would make sense that it does all the required work.
>     Note however that the sole use of `kde4_add_app_icon` isn't enough. It generates the icon file, and it adds the corresponding entry in the application's `Info.plist`, but that's not always enough. I haven't yet figured out why certain applications always got an icon, and why others require explicit installation of the icon resource.

Yes, calligragemini has icons on linux, they are installed by the CMakeLists.txt in gemini/pics. And Author has icons as well.
For both it was "just" those kde4_add_app_icon that were broken or not active (they do nothing on linux IIRC, that's why not noone noticed so far. And Windows builds are only done for CalligraGemini, Krita & Kexi).

For `ecm_add_app_icon` see here for the sources, ll. 223-224:
https://quickgit.kde.org/?p=extra-cmake-modules.git&a=blob&f=modules%2FECMAddAppIcon.cmake
```
            # Install the icon into the Resources dir in the bundle
            set_source_files_properties(${_outfilename}.icns PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
```
No idea what effect that has and if that is better than what is there in `kde4_add_app_icon`, but you might :)


- Friedrich W. H.


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/125649/#review86899
-----------------------------------------------------------


On Oct. 15, 2015, 8:55 p.m., René J.V. Bertin wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/125649/
> -----------------------------------------------------------
> 
> (Updated Oct. 15, 2015, 8:55 p.m.)
> 
> 
> Review request for Calligra and KDE Software on Mac OS X.
> 
> 
> Repository: calligra
> 
> 
> Description
> -------
> 
> Builds on OS X currently generate icons for most Calligra applications, but those are installed only for a happy few (Krita, Braindump and Kexi). The other applications require an explicit install command of the generated `.icns` file into the app bundle's Resources directory.
> 
> The attached patch takes care of that.
> 
> In addition, it corrects the picture source directories for calligragemini and calligraauthor so those applications can have icons on other platforms too, and replaces the `Q_WS_MACOS` token with the (IMHO) more appropriate `APPLE` token.
> 
> 
> Diffs
> -----
> 
>   flow/part/CMakeLists.txt 58882f1 
>   gemini/CMakeLists.txt 85123fa 
>   karbon/CMakeLists.txt b574779 
>   plan/CMakeLists.txt ad39f57 
>   sheets/CMakeLists.txt b0cc134 
>   stage/app/CMakeLists.txt 079bece 
>   words/app/CMakeLists.txt 1e73971 
>   words/part/CMakeLists.txt 9143176 
> 
> Diff: https://git.reviewboard.kde.org/r/125649/diff/
> 
> 
> Testing
> -------
> 
> On OS X 10.9 with KDELibs 4.14.12 and MacPorts 2.3.4 .
> 
> 
> Thanks,
> 
> René J.V. Bertin
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-mac/attachments/20151016/ad1fdf87/attachment.html>


More information about the kde-mac mailing list