-
Notifications
You must be signed in to change notification settings - Fork 4
/
CMakeLists.txt
38 lines (24 loc) · 1.1 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
cmake_minimum_required(VERSION 3.5)
project(pdfquirk LANGUAGES CXX)
option(USE_QT6 "Enable this if you want to use Qt6, instead of Qt5" no)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
find_package(ECM REQUIRED NO_MODULE)
list(APPEND CMAKE_MODULE_PATH "${ECM_MODULE_PATH}")
include(ECMInstallIcons)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}")
if(USE_QT6)
find_package(Qt6 COMPONENTS Widgets LinguistTools REQUIRED)
set(Qt6_Found "Qt6 found flag" CACHE INTERNAL yes)
else(USE_QT6)
find_package(Qt5 COMPONENTS Widgets LinguistTools REQUIRED)
endif(USE_QT6)
add_subdirectory(src)
set (XDG_APPS_INSTALL_DIR "share/applications" CACHE STRING "The XDG apps dir")
install(FILES pdfquirk.appdata.xml DESTINATION share/metainfo RENAME de.volle-kraft-voraus.pdfquirk.appdata.xml)
install(FILES pdfquirk.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} RENAME de.volle-kraft-voraus.pdfquirk.desktop)
ecm_install_icons( ICONS resources/64-apps-pdfquirk.png DESTINATION share/icons)