diff options
| author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2023-07-13 19:30:05 +0200 |
|---|---|---|
| committer | Simon Tatham <anakin@pobox.com> | 2023-07-14 08:31:44 +0100 |
| commit | c99fbed8c9d957de5b2094b54c7ec7e38979d770 (patch) | |
| tree | eedc4b1606d5cf9ecd20e9d4219a4d200ee2abba /cmake/platforms | |
| parent | 02cdafaa15eb5c2ccde76bbe1f1dcb0e893f4cec (diff) | |
| download | puzzles-c99fbed8c9d957de5b2094b54c7ec7e38979d770.zip puzzles-c99fbed8c9d957de5b2094b54c7ec7e38979d770.tar.gz puzzles-c99fbed8c9d957de5b2094b54c7ec7e38979d770.tar.bz2 puzzles-c99fbed8c9d957de5b2094b54c7ec7e38979d770.tar.xz | |
Install the icons to the right location on Linux
That way, any application displaying the .desktop with its icon will
pick the icon size it deems the best one for the current rendering.
See the Icon Theme Specification:
https://specifications.freedesktop.org/icon-theme-spec/latest/ar01s07.html
Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
Diffstat (limited to 'cmake/platforms')
| -rw-r--r-- | cmake/platforms/unix.cmake | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/cmake/platforms/unix.cmake b/cmake/platforms/unix.cmake index e848c9e..c6916aa 100644 --- a/cmake/platforms/unix.cmake +++ b/cmake/platforms/unix.cmake @@ -110,8 +110,20 @@ function(set_platform_puzzle_target_properties NAME TARGET) install(TARGETS ${TARGET}) endif() configure_file(${CMAKE_SOURCE_DIR}/puzzle.desktop.in ${binary_name}.desktop) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-16d24.png + DESTINATION share/icons/hicolor/16x16/apps OPTIONAL RENAME ${binary_name}.png) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-24d24.png + DESTINATION share/icons/hicolor/24x24/apps OPTIONAL RENAME ${binary_name}.png) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-32d24.png + DESTINATION share/icons/hicolor/32x32/apps OPTIONAL RENAME ${binary_name}.png) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-48d24.png - DESTINATION share/pixmaps OPTIONAL RENAME ${binary_name}-48d24.png) + DESTINATION share/icons/hicolor/48x48/apps OPTIONAL RENAME ${binary_name}.png) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-64d24.png + DESTINATION share/icons/hicolor/64x64/apps OPTIONAL RENAME ${binary_name}.png) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-96d24.png + DESTINATION share/icons/hicolor/96x96/apps OPTIONAL RENAME ${binary_name}.png) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/icons/${NAME}-128d24.png + DESTINATION share/icons/hicolor/128x128/apps OPTIONAL RENAME ${binary_name}.png) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${binary_name}.desktop DESTINATION share/applications) endif() |