-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathCMakeLists.txt
41 lines (34 loc) · 1.06 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
cmake_minimum_required(VERSION 3.20)
cmake_policy(SET CMP0048 NEW)
cmake_policy(SET CMP0079 NEW)
cmake_policy(SET CMP0094 NEW)
if(SKBUILD)
set(digital_rf_VERSION ${SKBUILD_PROJECT_VERSION})
else()
set(digital_rf_VERSION 2.6.10)
endif(SKBUILD)
project(digital_rf LANGUAGES C VERSION ${digital_rf_VERSION})
include(GNUInstallDirs)
enable_testing()
# create targets that sub-projects will add dependencies to
add_custom_target(build)
# include sub-projects
add_subdirectory(c)
add_subdirectory(docs)
add_subdirectory(matlab EXCLUDE_FROM_ALL)
add_subdirectory(python)
# shortcut target for digital_rf_toolbox
if(${ENABLE_MATLAB})
add_custom_target(matlab)
add_dependencies(matlab digital_rf_toolbox)
endif(${ENABLE_MATLAB})
# uninstall target
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
IMMEDIATE @ONLY
)
add_custom_target(uninstall
COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake
)
add_dependencies(uninstall libdigital_rf_uninstall)