From a4cb7a9e96ce4adc127ce10329c4b8fb469270ba Mon Sep 17 00:00:00 2001 From: Mahmood - Zer0xFF <5013823+Zer0xFF@users.noreply.github.com> Date: Sat, 18 May 2019 14:12:21 +0100 Subject: [PATCH] Add 'make install' for unix platforms --- Source/ui_qt/CMakeLists.txt | 7 +++++++ installer_unix/Play.desktop | 10 ++++++++++ 2 files changed, 17 insertions(+) create mode 100644 installer_unix/Play.desktop diff --git a/Source/ui_qt/CMakeLists.txt b/Source/ui_qt/CMakeLists.txt index 34ee9222..f9ec22bd 100644 --- a/Source/ui_qt/CMakeLists.txt +++ b/Source/ui_qt/CMakeLists.txt @@ -221,6 +221,13 @@ elseif(TARGET_PLATFORM_WIN32) win32/InputProviderDirectInput.h ) add_executable(Play WIN32 ${QT_SOURCES} ${QT_MOC_SRCS} ${QT_RES_SOURCES} ${QT_UI_HEADERS}) +elseif(TARGET_PLATFORM_UNIX) + add_executable(Play ${QT_SOURCES} ${QT_MOC_SRCS} ${QT_RES_SOURCES} ${QT_UI_HEADERS}) + + install(TARGETS Play DESTINATION bin RENAME Play PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ GROUP_EXECUTE GROUP_READ WORLD_EXECUTE WORLD_READ) + + install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../../installer_unix/Play.desktop DESTINATION share/applications) + install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../../icons/icon_base.png DESTINATION share/icons RENAME Play.png) else() add_executable(Play ${QT_SOURCES} ${QT_MOC_SRCS} ${QT_RES_SOURCES} ${QT_UI_HEADERS}) endif() diff --git a/installer_unix/Play.desktop b/installer_unix/Play.desktop new file mode 100644 index 00000000..baaa11fa --- /dev/null +++ b/installer_unix/Play.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Name=Play! +TryExec=/usr/bin/Play +Exec=/usr/bin/Play +Icon=Play +Version=1.0 +Terminal=false +Type=Application +Categories=Game;Emulator; +