-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
31 lines (25 loc) · 921 Bytes
/
CMakeLists.txt
File metadata and controls
31 lines (25 loc) · 921 Bytes
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
cmake_minimum_required(VERSION 3.8)
# Enable debug symbols by default, must be done before project() statement.
if (NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Choose the type of build (Debug or Release)" FORCE)
endif()
# (you can also set it on the command line: -D CMAKE_BUILD_TYPE=Release)
project(algorithm_analysis)
# Set compiler options.
if (MSVC)
add_compile_options(/W4)
else ()
add_compile_options(-Wall -Wextra -pedantic)
endif()
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
# Set additional properties for x64 platform.
if (CMAKE_SIZEOF_VOID_P EQUAL 8)
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS TRUE)
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB32_PATHS FALSE)
else ()
message(FATAL_ERROR "Unsupported architecture.")
endif()
# Include sub-projects.
add_subdirectory("Source/algorithms")