Changeset View
Changeset View
Standalone View
Standalone View
discover/CMakeLists.txt
Show All 32 Lines | |||||
33 | install(TARGETS plasma-discover ${INSTALL_TARGETS_DEFAULT_ARGS} ) | 33 | install(TARGETS plasma-discover ${INSTALL_TARGETS_DEFAULT_ARGS} ) | ||
34 | 34 | | |||
35 | # if (BUILD_DummyBackend) | 35 | # if (BUILD_DummyBackend) | ||
36 | # target_compile_definitions(plasma-discover PRIVATE $<$<CONFIG:Debug>:QT_QML_DEBUG=1>) | 36 | # target_compile_definitions(plasma-discover PRIVATE $<$<CONFIG:Debug>:QT_QML_DEBUG=1>) | ||
37 | # endif() | 37 | # endif() | ||
38 | 38 | | |||
39 | # Standard desktop file accepts local files as input. | 39 | # Standard desktop file accepts local files as input. | ||
40 | set(DesktopNoDisplay "false") | 40 | set(DesktopNoDisplay "false") | ||
41 | set(DesktopMimeType "application/vnd.debian.binary-package;application/x-rpm;") | 41 | find_program(DPKG dpkg) | ||
42 | find_program(RPM rpm) | ||||
43 | set(DesktopMimeType "") | ||||
44 | if(DPKG) | ||||
45 | set(DesktopMimeType "${DesktopMimeType}application/vnd.debian.binary-package;") | ||||
46 | endif() | ||||
47 | if(RPM) | ||||
48 | set(DesktopMimeType "${DesktopMimeType}application/x-rpm;") | ||||
49 | endif() | ||||
42 | set(DesktopExec "plasma-discover %F") | 50 | set(DesktopExec "plasma-discover %F") | ||
43 | configure_file(org.kde.discover.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/org.kde.discover.desktop) | 51 | configure_file(org.kde.discover.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/org.kde.discover.desktop) | ||
44 | install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/org.kde.discover.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) | 52 | install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/org.kde.discover.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) | ||
45 | 53 | | |||
46 | # Support appstream:// URI | 54 | # Support appstream:// URI | ||
47 | set(DesktopNoDisplay "true") | 55 | set(DesktopNoDisplay "true") | ||
48 | set(DesktopMimeType "x-scheme-handler/appstream;") | 56 | set(DesktopMimeType "x-scheme-handler/appstream;") | ||
49 | set(DesktopExec "plasma-discover %U") | 57 | set(DesktopExec "plasma-discover %U") | ||
Show All 20 Lines |