Skip to content

Commit

Permalink
Use Eigen CMake target
Browse files Browse the repository at this point in the history
  • Loading branch information
christophfroehlich committed Feb 23, 2024
1 parent 759d954 commit 338a2f8
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,8 @@ set(CONTROL_FILTERS_INCLUDE_DEPENDS
generate_parameter_library
pluginlib
geometry_msgs
Eigen3
)

find_package(Eigen3 REQUIRED NO_MODULE)
foreach(Dependency IN ITEMS ${CONTROL_FILTERS_INCLUDE_DEPENDS})
find_package(${Dependency} REQUIRED)
endforeach()
Expand All @@ -72,7 +71,10 @@ target_include_directories(low_pass_filter PUBLIC
$<BUILD_INTERFACE:${EIGEN3_INCLUDE_DIR}>
$<INSTALL_INTERFACE:include/control_toolbox>
)
target_link_libraries(low_pass_filter PUBLIC low_pass_filter_parameters)
target_link_libraries(low_pass_filter PUBLIC
low_pass_filter_parameters
Eigen3::Eigen
)
ament_target_dependencies(low_pass_filter PUBLIC ${CONTROL_FILTERS_INCLUDE_DEPENDS})

# Install pluginlib xml
Expand Down

0 comments on commit 338a2f8

Please sign in to comment.