Skip to content
Snippets Groups Projects
Commit 6020fff0 authored by Joan Vallvé Navarro's avatar Joan Vallvé Navarro
Browse files

find eigen 3.3

parent 2c3d47b9
No related branches found
No related tags found
No related merge requests found
Pipeline #20563 passed
...@@ -48,6 +48,13 @@ if(BUILD_TESTS) ...@@ -48,6 +48,13 @@ if(BUILD_TESTS)
set(_GNSS_UTILS_ROOT_DIR ${CMAKE_SOURCE_DIR}) set(_GNSS_UTILS_ROOT_DIR ${CMAKE_SOURCE_DIR})
endif() endif()
# ============ DEPENDENCIES ============
FIND_PACKAGE(Eigen3 3.3 REQUIRED CONFIG)
if(${EIGEN3_VERSION_STRING} VERSION_LESS 3.3)
message(FATAL_ERROR "GnssUtils requires Eigen >= 3.3. Found Eigen ${EIGEN3_VERSION_STRING}")
endif()
# ============ config.h ============
# Define the directory where will be the configured config.h # Define the directory where will be the configured config.h
SET(GNSS_UTILS_CONFIG_DIR ${PROJECT_BINARY_DIR}/conf/${PROJECT_NAME}/internal) SET(GNSS_UTILS_CONFIG_DIR ${PROJECT_BINARY_DIR}/conf/${PROJECT_NAME}/internal)
...@@ -111,8 +118,6 @@ SET(RTKLIB_SRC ...@@ -111,8 +118,6 @@ SET(RTKLIB_SRC
${RTKLIB_SRC_DIR}/rcv/ublox.c) ${RTKLIB_SRC_DIR}/rcv/ublox.c)
FIND_PACKAGE(Eigen3 3.3 REQUIRED CONFIG)
# Adding include directories # Adding include directories
INCLUDE_DIRECTORIES(BEFORE include ${RTKLIB_SRC_DIR}) INCLUDE_DIRECTORIES(BEFORE include ${RTKLIB_SRC_DIR})
...@@ -120,7 +125,7 @@ INCLUDE_DIRECTORIES(BEFORE include ${RTKLIB_SRC_DIR}) ...@@ -120,7 +125,7 @@ INCLUDE_DIRECTORIES(BEFORE include ${RTKLIB_SRC_DIR})
ADD_LIBRARY(${PROJECT_NAME} SHARED ${SOURCES} ${RTKLIB_SRC}) ADD_LIBRARY(${PROJECT_NAME} SHARED ${SOURCES} ${RTKLIB_SRC})
# Link this library wrt. its dependencies # Link this library wrt. its dependencies
TARGET_LINK_LIBRARIES(${PROJECT_NAME} Eigen3::Eigen) TARGET_LINK_LIBRARIES(${PROJECT_NAME} PUBLIC Eigen3::Eigen)
# Examples # Examples
ADD_SUBDIRECTORY(src/examples) ADD_SUBDIRECTORY(src/examples)
......
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