-
Notifications
You must be signed in to change notification settings - Fork 18
/
CMakeLists.txt
49 lines (37 loc) · 1.3 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
# 3.16 is the version available in Ubuntu 20.04. By coincidence, this
# is also the minimum version we need on Windows for file(
# GET_RUNTIME_DEPENDENCIES).
cmake_minimum_required(VERSION 3.16)
project(dpScreenOCR)
set(DPSO_UI "qt" CACHE STRING "UI to use: qt or none")
set_property(CACHE DPSO_UI PROPERTY STRINGS qt none)
option(DPSO_GEN_HTML_MANUAL "Generate HTML manual using Pandoc" YES)
option(DPSO_BUILD_EXAMPLE "Build example" NO)
option(DPSO_BUILD_TESTS "Build tests" NO)
set(APP_NAME "dpScreenOCR")
set(APP_FILE_NAME "dpscreenocr")
set(APP_VERSION_MAJOR "1")
set(APP_VERSION_MINOR "4")
set(APP_VERSION_PATCH "1")
set(APP_VERSION
"${APP_VERSION_MAJOR}.${APP_VERSION_MINOR}.${APP_VERSION_PATCH}")
set(APP_DESCRIPTION "Program to recognize text on screen")
set(APP_AUTHOR "Daniel Plakhotich")
set(APP_COPYRIGHT_YEAR "2019-2024")
set(APP_URL "https://danpla.github.io/dpscreenocr/")
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
include(fixup_gnu_install_dirs)
if(DPSO_BUILD_EXAMPLE)
add_subdirectory(src/dpso_example)
endif()
if(DPSO_UI STREQUAL "qt")
add_subdirectory(src/ui/qt)
elseif(NOT DPSO_UI STREQUAL "none")
message(FATAL_ERROR "Unknown UI \"${DPSO_UI}\"")
endif()
if(DPSO_BUILD_TESTS)
add_subdirectory(tests)
endif()
include(install)
include(uninstall)
include(dist)