-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
36 lines (29 loc) · 953 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
33
34
35
36
cmake_minimum_required(VERSION 3.2)
project(benchmark)
if (POLICY CMP0077)
cmake_policy(SET CMP0077 NEW)
endif()
option(WITH_EXAMPLES "Build examples" ON)
option(WITH_TESTS "Build tests" ON)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
add_library(benchmark STATIC
src/benchmark.cpp
include/benchmark/benchmark.h
include/benchmark/detail/benchmark_setup.h
include/benchmark/detail/config.h
include/benchmark/detail/cpu_info.h
include/benchmark/detail/dont_optimize.h
include/benchmark/detail/program_arguments.h
include/benchmark/detail/state.h
include/benchmark/detail/statistics.h
include/benchmark/detail/variables.h
include/benchmark/detail/colorization.h)
target_include_directories(benchmark PUBLIC include/)
target_compile_options(benchmark PUBLIC -Wno-attributes)
if(WITH_EXAMPLES)
add_subdirectory(examples)
endif()
if(WITH_TESTS)
add_subdirectory(tests)
endif()