Commit 40407834 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use new KDE_ macro

parent 5a8bef06
...@@ -3,7 +3,7 @@ PROJECT(ksquares) ...@@ -3,7 +3,7 @@ PROJECT(ksquares)
cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR) cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR)
set (QT_MIN_VERSION "5.3.0") set (QT_MIN_VERSION "5.3.0")
find_package(ECM 1.3.0 REQUIRED CONFIG) find_package(ECM 1.7.0 REQUIRED CONFIG)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR}) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR})
find_package(Qt5 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS Widgets Test) find_package(Qt5 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS Widgets Test)
...@@ -25,6 +25,7 @@ find_package(KF5 REQUIRED COMPONENTS ...@@ -25,6 +25,7 @@ find_package(KF5 REQUIRED COMPONENTS
find_package(KF5KDEGames 4.9.0 REQUIRED) find_package(KF5KDEGames 4.9.0 REQUIRED)
include(FeatureSummary) include(FeatureSummary)
include(ECMAddAppIcon)
include(ECMInstallIcons) include(ECMInstallIcons)
include(KDEInstallDirs) include(KDEInstallDirs)
include(KDECompilerSettings) include(KDECompilerSettings)
......
kdoctools_create_handbook(index.docbook INSTALL_DESTINATION ${HTML_INSTALL_DIR}/en SUBDIR ksquares) kdoctools_create_handbook(index.docbook INSTALL_DESTINATION ${KDE_INSTALL_DOCBUNDLEDIR}/en SUBDIR ksquares)
...@@ -19,17 +19,18 @@ ki18n_wrap_ui(ksquares_SRCS newgamewidget.ui scoreswidget.ui prefs_ai.ui prefs_d ...@@ -19,17 +19,18 @@ ki18n_wrap_ui(ksquares_SRCS newgamewidget.ui scoreswidget.ui prefs_ai.ui prefs_d
kconfig_add_kcfg_files(ksquares_SRCS GENERATE_MOC settings.kcfgc) #GENERATE_MOC is not needed but it doesn't work without it for some reason :S kconfig_add_kcfg_files(ksquares_SRCS GENERATE_MOC settings.kcfgc) #GENERATE_MOC is not needed but it doesn't work without it for some reason :S
#kde4_add_app_icon(ksquares_SRCS "${CMAKE_CURRENT_SOURCE_DIR}/hi*-apps-ksquares.png") file(GLOB ICONS_SRCS "${CMAKE_CURRENT_SOURCE_DIR}/hi*-apps-ksquares.png")
ecm_add_app_icon(ksquares_SRCS ICONS ${ICONS_SRCS})
add_executable(ksquares ${ksquares_SRCS}) add_executable(ksquares ${ksquares_SRCS})
target_link_libraries(ksquares KF5KDEGames KF5::I18n KF5::XmlGui KF5::Completion KF5::DBusAddons) target_link_libraries(ksquares KF5KDEGames KF5::I18n KF5::XmlGui KF5::Completion KF5::DBusAddons)
install(TARGETS ksquares ${INSTALL_TARGETS_DEFAULT_ARGS}) install(TARGETS ksquares ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
########### install files ############### ########### install files ###############
install( PROGRAMS org.kde.ksquares.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) install( PROGRAMS org.kde.ksquares.desktop DESTINATION ${KDE_INSTALL_APPDIR} )
install( FILES ksquares.kcfg DESTINATION ${KCFG_INSTALL_DIR} ) install( FILES ksquares.kcfg DESTINATION ${KDE_INSTALL_KCFGDIR} )
install( FILES ksquaresui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/ksquares ) install( FILES ksquaresui.rc DESTINATION ${KDE_INSTALL_KXMLGUI5DIR}/ksquares )
ecm_install_icons(ICONS hi128-apps-ksquares.png hi16-apps-ksquares.png hi22-apps-ksquares.png hi32-apps-ksquares.png hi48-apps-ksquares.png hi64-apps-ksquares.png DESTINATION ${ICON_INSTALL_DIR}) ecm_install_icons(ICONS hi128-apps-ksquares.png hi16-apps-ksquares.png hi22-apps-ksquares.png hi32-apps-ksquares.png hi48-apps-ksquares.png hi64-apps-ksquares.png DESTINATION ${KDE_INSTALL_ICONDIR})
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment