-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
52 lines (44 loc) · 1.2 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
cmake_minimum_required(VERSION 3.20)
if(DEFINED PROJECT_NAME)
set(IS_SUBPROJECT true)
endif()
project(treble
VERSION 1.0.0
DESCRIPTION "Header-only library for creating self-tuning functions"
LANGUAGES CXX)
include(FetchContent)
FetchContent_Declare(
AddLib
GIT_REPOSITORY https://github.com/Chemiseblanc/AddLib.git
GIT_TAG v2.1.2
)
FetchContent_MakeAvailable(AddLib)
include(AddLib)
add_lib(treble
HEADER_ONLY
SOURCES
include/treble/treble.hpp
include/treble/self_tuning_function.hpp
include/treble/param.hpp
include/treble/detail.hpp
include/treble/probes/probes.hpp
include/treble/probes/scoped_timer.hpp
include/treble/optimizers/optimizers.hpp
include/treble/optimizers/incremental_sub_gradient.hpp
INCLUDE_DIRS
${CMAKE_CURRENT_SOURCE_DIR}/include
COMPILE_FEATURES
cxx_std_17
)
install_project()
package_project(
CONTACT "Matthew Gibson <[email protected]>"
LICENSE_FILE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE.txt"
)
if(NOT IS_SUBPROJECT)
option(BUILD_EXAMPLES ON)
if(BUILD_EXAMPLES)
add_subdirectory(examples)
add_subdirectory(benchmarks)
endif()
endif()