-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
38 lines (26 loc) · 1.23 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
cmake_minimum_required(VERSION 3.27)
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/cmake)
set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR}/installed)
project(aspire)
enable_language(CXX)
include(GenerateExportHeader)
include(CMakePackageConfigHelpers)
include(GNUInstallDirs)
include(CTest)
include(GoogleTest)
option(BUILD_SHARED_LIBS "Enable building libraries as shared objects." ON)
option(BUILD_ENABLE_HARDENED "Enable hardened compiler options" OFF)
option(BUILD_TESTING "Enable building ${PROJECT_NAME} test applications." ON)
set(PROJECT_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include)
set(PROJECT_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/module)
include_directories(${PROJECT_INCLUDE_DIR})
# Define build directory includes as system to avoid tools like clang-tidy from scanning them.
include_directories(SYSTEM ${CMAKE_CURRENT_BINARY_DIR})
# Qt fails to find this path for android when it invokes Qt6AndroidMacros.cmake.
set(QT_ANDROID_PATH_CMAKE_DIR_${ANDROID_ABI} ${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/share)
find_package(Qt6 6.7 CONFIG REQUIRED COMPONENTS Quick)
qt_standard_project_setup(REQUIRES 6.7)
set(CMAKE_AUTOMOC ON)
add_subdirectory(module)
add_subdirectory(app)