forked from Bosma/Scheduler
-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
28 lines (20 loc) · 911 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
cmake_minimum_required(VERSION 3.7)
project(BosmaScheduler VERSION 1.0.0 LANGUAGES CXX)
# Include
include(GNUInstallDirs)
include(ExternalProject)
# Threads
set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(Threads REQUIRED)
add_library(${PROJECT_NAME} INTERFACE)
target_compile_features(${PROJECT_NAME} INTERFACE cxx_std_17)
target_include_directories(${PROJECT_NAME} INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:include>)
install(TARGETS ${PROJECT_NAME} EXPORT BosmaSchedulerConfig
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
install(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME})
install(EXPORT BosmaSchedulerConfig DESTINATION share/BosmaScheduler/cmake)
export(TARGETS ${PROJECT_NAME} FILE BosmaSchedulerConfig.cmake)