forked from MRPT/mrpt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmrpt-config.cmake
36 lines (33 loc) · 1.1 KB
/
mrpt-config.cmake
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
# =========================================================================
# The Mobile Robot Programming Toolkit (MRPT) CMake configuration file
#
# ** File generated automatically, do not modify **
#
# Please, read:
# https://docs.mrpt.org/reference/devel/mrpt_from_cmake.html
# In your CMakeLists.txt, add these lines:
#
# find_package(MRPT REQUIRED
# COMPONENTS slam nav
# OPTIONAL_COMPONENTS vision)
# target_link_libraries(MY_TARGET_NAME ${MRPT_LIBRARIES})
#
# or do it individually:
# find_package(mrpt-slam)
# find_package(mrpt-nav)
# target_link_libraries(MY_TARGET_NAME mrpt::slam mrpt::nav)
# =========================================================================
include(CMakeFindDependencyMacro)
set(MRPT_LIBRARIES "")
foreach(_comp ${MRPT_FIND_COMPONENTS})
if (MRPT_FIND_REQUIRED_${_comp})
find_dependency(mrpt-${_comp})
else()
find_package(mrpt-${_comp} CONFIG QUIET)
endif()
if (mrpt-${_comp}_FOUND)
list(APPEND MRPT_LIBRARIES mrpt::${_comp})
endif()
endforeach()
# backwards-compatibility var name:
set(MRPT_LIBS ${MRPT_LIBRARIES})