1
0
mirror of https://github.com/blupi-games/planetblupi synced 2024-12-30 10:15:36 +01:00

WIP: add desktop file for standard build

This commit is contained in:
Mathieu Schroeter 2017-10-21 09:39:18 +02:00
parent d3986d5d4a
commit a50e648d63

View File

@ -34,6 +34,14 @@ if (APPIMAGE_APPRUN_PROGRAM AND APPIMAGE_ASSISTANT_PROGRAM)
set (USE_APPIMAGE ON)
endif ()
if (NOT USE_APPIMAGE)
configure_file (
"${PROJECT_SOURCE_DIR}/resources/linux/application.desktop.in"
"${CMAKE_CURRENT_BINARY_DIR}/${PB_PACKAGE_NAME}.desktop"
@ONLY
)
endif ()
if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -std=c++11 -L${CMAKE_INSTALL_PREFIX}/lib")
endif ()
@ -261,6 +269,13 @@ if (UNIX AND NOT APPLE)
install (DIRECTORY resources/icon/hicolor DESTINATION share/icons)
endif ()
if (NOT USE_APPIMAGE)
install (
FILES ${CMAKE_CURRENT_BINARY_DIR}/${PB_PACKAGE_NAME}.desktop
DESTINATION ${CMAKE_INSTALL_PREFIX}/share/applications/
)
endif ()
# Copy libwinpthread-1.dll which seems not be linkable statically
if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows" AND MINGW)
execute_process (COMMAND cygpath.exe --windows /mingw64 OUTPUT_VARIABLE MINGW64_PATH)