[client] linux: Install .desktop file and icon

SVGs have had a great support for Linux for about a decade, so only
install that for simplicity.
This commit is contained in:
Mark Stosberg 2024-11-05 06:27:52 -05:00
parent e25492a3a3
commit 17d5bba1a4
No known key found for this signature in database
2 changed files with 19 additions and 0 deletions

View File

@ -147,6 +147,7 @@ add_subdirectory("${PROJECT_TOP}/repos/cimgui" "${CMAKE_BINARY_DIR}/cimgui" E
add_subdirectory(displayservers) add_subdirectory(displayservers)
add_subdirectory(renderers) add_subdirectory(renderers)
configure_file("${PROJECT_TOP}/resources/looking-glass-client.desktop.in" "${CMAKE_BINARY_DIR}/resources/looking-glass-client.desktop" @ONLY)
add_executable(looking-glass-client ${SOURCES}) add_executable(looking-glass-client ${SOURCES})
target_compile_definitions(looking-glass-client PRIVATE CIMGUI_DEFINE_ENUMS_AND_STRUCTS=1) target_compile_definitions(looking-glass-client PRIVATE CIMGUI_DEFINE_ENUMS_AND_STRUCTS=1)
@ -177,4 +178,10 @@ install(TARGETS looking-glass-client
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
COMPONENT binary) COMPONENT binary)
install(FILES "${CMAKE_BINARY_DIR}/resources/looking-glass-client.desktop"
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/applications")
install(FILES "${PROJECT_TOP}/resources/lg-logo.svg"
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/icons/hicolor/scalable/apps"
RENAME "looking-glass.svg")
feature_summary(WHAT ENABLED_FEATURES DISABLED_FEATURES) feature_summary(WHAT ENABLED_FEATURES DISABLED_FEATURES)

View File

@ -0,0 +1,12 @@
[Desktop Entry]
Type=Application
Version=1.0
Name=Looking Glass Client
Comment=Clent for Looking Glass KVMFR
Icon=looking-glass
Exec=@CMAKE_INSTALL_PREFIX@/bin/looking-glass-client
Terminal=false
Keywords=KVM
Categories=System;
StartupWMClass=looking-glass-client
SingleMainWindow=true