forked from KDE/kalgebra
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
76 lines (56 loc) · 2.74 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
cmake_minimum_required(VERSION 3.5)
# KDE Application Version, managed by release script
set(RELEASE_SERVICE_VERSION_MAJOR "20")
set(RELEASE_SERVICE_VERSION_MINOR "07")
set(RELEASE_SERVICE_VERSION_MICRO "70")
set(RELEASE_SERVICE_VERSION "${RELEASE_SERVICE_VERSION_MAJOR}.${RELEASE_SERVICE_VERSION_MINOR}.${RELEASE_SERVICE_VERSION_MICRO}")
project(kalgebra VERSION ${RELEASE_SERVICE_VERSION})
find_package(ECM 1.7.0 REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" ${ECM_MODULE_PATH})
find_package(Qt5 5.2 REQUIRED NO_MODULE COMPONENTS Qml Quick Xml Svg PrintSupport Test)
include(KDEInstallDirs)
include(KDECompilerSettings NO_POLICY_SCOPE)
include(KDECMakeSettings)
include(ECMInstallIcons)
include(ECMSetupVersion)
include(FeatureSummary)
include(ECMAddAppIcon)
find_package(Analitza5 REQUIRED)
set(MOBILE_BACKEND "kde" CACHE STRING "Backend to install, currently. Check /mobile/plugins/widgets/*")
include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR})
set(CURSES_NEED_NCURSES TRUE)
find_package(Curses)
find_package(Readline)
ecm_setup_version(${RELEASE_SERVICE_VERSION} VARIABLE_PREFIX KALGEBRA VERSION_HEADER kalgebra_version.h)
set_package_properties(Readline PROPERTIES TYPE OPTIONAL
PURPOSE "Allows KAlgebra to provide a console interface."
URL "https://tiswww.case.edu/php/chet/readline/rltop.html")
set_package_properties(Curses PROPERTIES TYPE OPTIONAL
PURPOSE "Allows KAlgebra to provide a console interface."
URL "https://www.gnu.org/software/ncurses/")
add_definitions(-DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS)
add_definitions(-DQT_NO_URL_CAST_FROM_STRING)
add_definitions(-DQT_NO_CAST_TO_ASCII)
find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS I18n CoreAddons)
find_package(KF5 ${KF5_MIN_VERSION} OPTIONAL_COMPONENTS ConfigWidgets WidgetsAddons KIO DocTools)
find_package(Qt5WebEngineWidgets)
if(KF5DocTools_FOUND AND Qt5WebEngineWidgets_FOUND AND KF5ConfigWidgets_FOUND AND KF5WidgetsAddons_FOUND AND KF5KIO_FOUND AND NOT CMAKE_SYSTEM MATCHES Android*)
add_subdirectory(src)
add_subdirectory(plasmoids)
endif()
add_subdirectory(icons)
add_subdirectory(mobile)
if(READLINE_FOUND AND CURSES_FOUND)
add_subdirectory(calgebra)
endif()
if(KF5DocTools_FOUND)
add_subdirectory(utils)
add_custom_target(commandsdoc
${CMAKE_CURRENT_BINARY_DIR}/utils/docbook_analitzacommands commands.docbook
DEPENDS docbook_analitzacommands
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/doc/
COMMENT "Generating commands docbook information"
)
add_subdirectory(doc)
endif()
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)