-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
33 lines (25 loc) · 1023 Bytes
/
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
cmake_minimum_required(VERSION 3.22)
project(sesable
VERSION 0.1.0
DESCRIPTION "Sesable - Web app for dead simple, encrypted, arbitary table storage."
LANGUAGES CXX
)
option(SESABLE_LINT "Build sesable with software linting enabled?" ON)
option(SESABLE_SANITIZE_BACKEND "Build backend with address and undefined behavior sanitizers?" OFF)
option(SESABLE_TESTS "Build sesable backend unit tests?" OFF)
set(CMAKE_CXX_STANDARD 23)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.24")
cmake_policy(SET CMP0135 NEW)
endif()
if (SESABLE_LINT)
find_program(CLANG_TIDY_EXE clang-tidy HINTS /usr/bin /usr/local/bin)
if(NOT CLANG_TIDY_EXE OR NOT EXISTS ${PROJECT_SOURCE_DIR}/.clang-tidy)
message(WARNING "Building without clang-tidy. Several quality control checks and guarantees are disabled!")
endif()
endif()
include(GNUInstallDirs)
add_subdirectory(frontend)
add_subdirectory(backend)