aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authoraqua <aqua@iserlohn-fortress.net>2024-04-28 10:50:04 +0300
committeraqua <aqua@iserlohn-fortress.net>2024-04-28 10:50:04 +0300
commit0eb0cf57720943ad71857a4a4fc0a9f365581d2a (patch)
treee1f8234c4351ffbf37d26416b88ae5749a8ee881 /CMakeLists.txt
parentReadded command line options (diff)
downloadsmolbote-0eb0cf57720943ad71857a4a4fc0a9f365581d2a.tar.xz
Added compiler warnings for poi
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt22
1 files changed, 20 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8740168..30cc928 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,6 +2,12 @@ cmake_minimum_required(VERSION 3.16)
project(smolbote VERSION 0.1.0 LANGUAGES CXX)
+list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake")
+
+include(CppCheck)
+include(CompilerOptions)
+include(FeatureSummary)
+
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
# set C++ standard for all targets
@@ -9,13 +15,23 @@ set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
+# set PIE for all targets
+set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+
# dependencies
find_package(GTest)
enable_testing()
-find_package(spdlog)
+find_package(spdlog REQUIRED)
-find_package(Qt6 6.0.0 COMPONENTS Network Widgets SvgWidgets WebEngineCore WebEngineWidgets Concurrent REQUIRED)
+find_package(Qt6 6.0.0 REQUIRED COMPONENTS
+ Network
+ Widgets
+ SvgWidgets
+ WebEngineCore
+ WebEngineWidgets
+ Concurrent
+)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
@@ -36,3 +52,5 @@ add_subdirectory(src)
include(GNUInstallDirs)
install(TARGETS poi DESTINATION ${CMAKE_INSTALL_BINDIR})
+
+feature_summary(WHAT ALL)