Skip to content
Snippets Groups Projects
Commit 8f71404d authored by Pep Martí Saumell's avatar Pep Martí Saumell
Browse files

CMAKE: modified to find the gnss_utils library

parent ea245bba
No related branches found
No related tags found
3 merge requests!28release after RAL,!27After 2nd RAL submission,!10Resolve "GAUSS Project"
......@@ -99,6 +99,7 @@ ENDIF(BUILD_EXAMPLES OR BUILD_TESTS)
#find dependencies.
# ============EXAMPLE==================
FIND_PACKAGE(wolf REQUIRED)
FIND_PACKAGE(gnss_utils REQUIRED)
#FIND_PATH(
# Suitesparse_INCLUDE_DIRS
......@@ -247,7 +248,7 @@ ADD_LIBRARY(${PLUGIN_NAME}
#Link the created libraries
#===============EXAMPLE=========================
TARGET_LINK_LIBRARIES(${PLUGIN_NAME} ${wolf_LIBRARIES})
TARGET_LINK_LIBRARIES(${PLUGIN_NAME} ${laser_scan_utils_LIBRARY})
TARGET_LINK_LIBRARIES(${PLUGIN_NAME} ${gnss_utils_LIBRARY})
#Build tests
......
FIND_PATH(
gnss_utils_INCLUDE_DIRS
NAMES gnss_utils.h
PATHS /usr/local/include/gnss_utils)
IF(gnss_utils_INCLUDE_DIRS)
MESSAGE("Found gnss_utils include dirs: ${gnss_utils_INCLUDE_DIRS}")
ELSE(gnss_utils_INCLUDE_DIRS)
MESSAGE("Couldn't find gnss_utils include dirs")
ENDIF(gnss_utils_INCLUDE_DIRS)
FIND_LIBRARY(
gnss_utils_LIBRARIES
NAMES libgnss_utils.so libgnss_utils.dylib
PATHS /usr/local/lib/gnss_utils)
IF(gnss_utils_LIBRARIES)
MESSAGE("Found gnss_utils lib: ${gnss_utils_LIBRARIES}")
ELSE(gnss_utils_LIBRARIES)
MESSAGE("Couldn't find gnss_utils lib")
ENDIF(gnss_utils_LIBRARIES)
IF (gnss_utils_INCLUDE_DIRS AND gnss_utils_LIBRARIES)
SET(gnss_utils_FOUND TRUE)
ELSE(gnss_utils_INCLUDE_DIRS AND gnss_utils_LIBRARIES)
set(gnss_utils_FOUND FALSE)
ENDIF (gnss_utils_INCLUDE_DIRS AND gnss_utils_LIBRARIES)
IF (gnss_utils_FOUND)
IF (NOT gnss_utils_FIND_QUIETLY)
MESSAGE(STATUS "Found gnss_utils: ${gnss_utils_LIBRARIES}")
ENDIF (NOT gnss_utils_FIND_QUIETLY)
ELSE (gnss_utils_FOUND)
IF (gnss_utils_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find gnss_utils")
ENDIF (gnss_utils_FIND_REQUIRED)
ENDIF (gnss_utils_FOUND)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment