From ccd9a1b54b7ca6114ca94325c8d38845d6749a90 Mon Sep 17 00:00:00 2001 From: Vicki Pfau Date: Tue, 4 Jul 2017 00:05:19 -0700 Subject: [PATCH] Qt: Hopefully fix datadir this time --- src/platform/qt/CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/platform/qt/CMakeLists.txt b/src/platform/qt/CMakeLists.txt index f33c292ee..800883ed0 100644 --- a/src/platform/qt/CMakeLists.txt +++ b/src/platform/qt/CMakeLists.txt @@ -209,13 +209,13 @@ if(NOT DEFINED DATADIR) if(APPLE) set(DATADIR Applications/${PROJECT_NAME}.app/Contents/Resources) else() - set(DATADIR ${CMAKE_INSTALL_FULL_DATADIR}/${BINARY_NAME}) + set(DATADIR ${CMAKE_INSTALL_DATADIR}/${BINARY_NAME}) endif() endif() install(DIRECTORY ${CMAKE_SOURCE_DIR}/res/shaders DESTINATION ${DATADIR} COMPONENT ${BINARY_NAME}-qt) install(FILES ${CMAKE_SOURCE_DIR}/res/nointro.dat DESTINATION ${DATADIR} COMPONENT ${BINARY_NAME}-qt) if(NOT WIN32 AND NOT APPLE) - list(APPEND QT_DEFINES DATADIR="${DATADIR}") + list(APPEND QT_DEFINES DATADIR="${CMAKE_INSTALL_PREFIX}/${DATADIR}") endif() find_package(Qt5LinguistTools) @@ -253,7 +253,7 @@ install(TARGETS ${BINARY_NAME}-qt if(UNIX AND NOT APPLE) find_program(DESKTOP_FILE_INSTALL desktop-file-install) if(DESKTOP_FILE_INSTALL) - install(CODE "execute_process(COMMAND ${DESKTOP_FILE_INSTALL} \"${CMAKE_SOURCE_DIR}/res/mgba-qt.desktop\" --dir \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/applications/\")") + install(CODE "execute_process(COMMAND ${DESKTOP_FILE_INSTALL} \"${CMAKE_SOURCE_DIR}/res/mgba-qt.desktop\" --dir \"\$ENV{DESTDIR}\${CMAKE_INSTALL_FULL_DATADIR}/applications/\")") endif() endif() if(UNIX)