summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2015-03-03 13:37:55 +0100
committerMontel Laurent <[email protected]>2015-03-03 13:37:55 +0100
commit509fc9ef8b8cf851ec2aab24958573f03fc08a3a (patch)
treeaf64a6347d036ed6aa3d83ef6bdd9344b5677cb0
parent744fea17eba5fb8975420d204776133abb1ef926 (diff)
Use new macro for use icon on Win/MacOsX. Use new KDE_ macro.
-rw-r--r--CMakeLists.txt14
-rw-r--r--doc/CMakeLists.txt2
-rw-r--r--pics/CMakeLists.txt2
3 files changed, 10 insertions, 8 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4f147a0..2b9b8a7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -3,7 +3,7 @@ project(kblackbox)
cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR)
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})
find_package(Qt5 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS Widgets Svg)
@@ -23,6 +23,7 @@ include(ECMInstallIcons)
include(KDEInstallDirs)
include(KDECompilerSettings)
include(KDECMakeSettings)
+include(ECMAddAppIcon)
add_definitions("-DQT_NO_CAST_FROM_ASCII -DQT_NO_CAST_TO_ASCII")
add_definitions(-DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS)
@@ -60,16 +61,17 @@ set(kblackbox_SRCS
kconfig_add_kcfg_files(kblackbox_SRCS kbbprefs.kcfgc)
-kde4_add_app_icon(kblackbox_SRCS "${CMAKE_CURRENT_SOURCE_DIR}/hi*-apps-kblackbox.png")
+file(GLOB ICONS_SRCS "${CMAKE_CURRENT_SOURCE_DIR}/hi*-apps-kblackbox.png")
+ecm_add_app_icon(kblackbox_SRCS ICONS ${ICONS_SRCS})
add_executable(kblackbox ${kblackbox_SRCS})
target_link_libraries(kblackbox Qt5::Xml KF5KDEGames KF5::XmlGui Qt5::Svg KF5::I18n KF5::Archive KF5::TextWidgets KF5::DBusAddons)
-install(TARGETS kblackbox ${INSTALL_TARGETS_DEFAULT_ARGS})
-install(PROGRAMS org.kde.kblackbox.desktop DESTINATION ${XDG_APPS_INSTALL_DIR})
+install(TARGETS kblackbox ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
+install(PROGRAMS org.kde.kblackbox.desktop DESTINATION ${KDE_INSTALL_APPDIR})
install(FILES kblackbox.appdata.xml DESTINATION share/appdata)
-install(FILES kblackboxui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/kblackbox)
+install(FILES kblackboxui.rc DESTINATION ${KDE_INSTALL_KXMLGUI5DIR}/kblackbox)
-ecm_install_icons(ICONS hi128-apps-kblackbox.png hi16-apps-kblackbox.png hi22-apps-kblackbox.png hi32-apps-kblackbox.png hi48-apps-kblackbox.png hi64-apps-kblackbox.png DESTINATION ${ICON_INSTALL_DIR})
+ecm_install_icons(ICONS hi128-apps-kblackbox.png hi16-apps-kblackbox.png hi22-apps-kblackbox.png hi32-apps-kblackbox.png hi48-apps-kblackbox.png hi64-apps-kblackbox.png DESTINATION ${KDE_INSTALL_ICONDIR})
feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES)
diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt
index 1fe346a..8a10157 100644
--- a/doc/CMakeLists.txt
+++ b/doc/CMakeLists.txt
@@ -1,4 +1,4 @@
########### install files ###############
#
#
-kdoctools_create_handbook(index.docbook INSTALL_DESTINATION ${HTML_INSTALL_DIR}/en SUBDIR kblackbox)
+kdoctools_create_handbook(index.docbook INSTALL_DESTINATION ${KDE_INSTALL_DOCBUNDLEDIR}/en SUBDIR kblackbox)
diff --git a/pics/CMakeLists.txt b/pics/CMakeLists.txt
index e6bea17..8e8258f 100644
--- a/pics/CMakeLists.txt
+++ b/pics/CMakeLists.txt
@@ -2,4 +2,4 @@
install( FILES
kblackbox.svgz
- DESTINATION ${DATA_INSTALL_DIR}/kblackbox/pics )
+ DESTINATION ${KDE_INSTALL_DATADIR}/kblackbox/pics )