updated FindRealSense.cmake

This commit is contained in:
matlabbe
2017-05-05 16:10:09 -04:00
parent c3ec7fbbe4
commit 4d025568dc
2 changed files with 37 additions and 17 deletions
+9 -2
View File
@@ -149,6 +149,7 @@ option(WITH_CVSBA "Include cvsba support" ON)
option(WITH_FLYCAPTURE2 "Include FlyCapture2/Triclops support" ON)
option(WITH_ZED "Include ZED sdk support" ON)
option(WITH_REALSENSE "Include RealSense support" ON)
option(WITH_REALSENSE_SLAM "Include RealSenseSlam support" ON)
option(WITH_OCTOMAP "Include Octomap support" ON)
option(PCL_OMP "With PCL OMP implementations" ON)
@@ -315,7 +316,11 @@ IF(WITH_ZED)
ENDIF(WITH_ZED)
IF(WITH_REALSENSE)
FIND_PACKAGE(RealSense QUIET)
IF(WITH_REALSENSE_SLAM)
FIND_PACKAGE(RealSense QUIET COMPONENTS slam)
ELSE()
FIND_PACKAGE(RealSense QUIET)
ENDIF()
IF(RealSense_FOUND)
MESSAGE(STATUS "Found RealSense: ${RealSense_INCLUDE_DIRS}")
ENDIF(RealSense_FOUND)
@@ -744,8 +749,10 @@ IF(RealSense_FOUND)
MESSAGE(STATUS " With RealSense = YES (License: Apache-2)")
IF(RealSenseSlam_FOUND)
MESSAGE(STATUS " With RealSenseSlam = YES")
ELSE()
ELSEIF(NOT WITH_REALSENSE)
MESSAGE(STATUS " With RealSenseSlam = NO (librealsense_slam not found)")
ELSE()
MESSAGE(STATUS " With RealSenseSlam = NO (WITH_REALSENSE_SLAM=OFF)")
ENDIF()
ELSEIF(NOT WITH_REALSENSE)
MESSAGE(STATUS " With RealSense = NO (WITH_REALSENSE=OFF)")