Review Request 128162: ecm_add_app_icon : accept SVG icons on OS X when KIconThemes is installed (WIP)

René J.V. Bertin rjvbertin at gmail.com
Sun Jun 12 18:09:10 UTC 2016


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

Review request for Extra Cmake Modules and KDE Software on Mac OS X.


Repository: extra-cmake-modules


Description
-------

KIconThemes installs a nice little utility on OS X which generates a very complete `.icns` icon file from SVG and compressed SVG.
I've made a quick modification to `ecm_add_app_icon` so that it will use that utility on OS X, when `ksvg2icns` is found in the path and when the icon extension is `.svg` or `.svgz` (or else it will go about its business as usual). 
If `ksvg2icns` fails an `AUTHOR_WARNING` is posted, otherwise the icon is registered and the function returns to its caller.

I haven't taken any steps to ensure that only a single SVG image is passed in; I presume that the current implementation will lead to ksvg2icns failure when multiple files are specified.

The advantage of using SVG images is that any image will do. This is particularly useful for projects that do not provide their own icon files. In most cases that means that one has to work with icons that are not named appropriately, and that require creating temporary copies or symlinks in the build directory with names that are acceptable to `ecm_add_app_icon`.


Diffs
-----

  modules/ECMAddAppIcon.cmake ca64314 

Diff: https://git.reviewboard.kde.org/r/128162/diff/


Testing
-------

On OS X 10.9 with my MacPorts install (KF5 5.22.0 and Qt 5.6.0 in /opt/local), using kdesvn as a test-app.


File Attachments
----------------

screenshot of the Finder's Get Info window for kdesvn5
  https://git.reviewboard.kde.org/media/uploaded/files/2016/06/12/40eeb46f-814e-463f-ab9b-28fe938a6261__Screen_Shot_2016-06-12_at_20.07.51.png


Thanks,

René J.V. Bertin

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-buildsystem/attachments/20160612/1e0ec0ea/attachment.html>


More information about the Kde-buildsystem mailing list