Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error with Humble #15

Open
sarubito opened this issue Jun 9, 2023 · 1 comment
Open

Build error with Humble #15

sarubito opened this issue Jun 9, 2023 · 1 comment

Comments

@sarubito
Copy link

sarubito commented Jun 9, 2023

Hi.
I have tried following the README guidelines to build the code, but after executing

$ colcon build --symlink-install --packages-select octomap_msgs octomap_server2

I get the following error:

fatal error: tf2_geometry_msgs/tf2_geometry_msgs.h: No such file or directory
   50 | #include <tf2_geometry_msgs/tf2_geometry_msgs.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

fatal error: rclcpp_components/register_node_macro.hpp: No such file or directory
    9 | #include <rclcpp_components/register_node_macro.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

I solved by adding below to CMakeLists.txt.

find_package(tf2_geometry_msgs REQUIRED)

and

ament_target_dependencies(octomap_server2
  rclcpp
  PCL
  pcl_conversions
  sensor_msgs
  std_msgs
  nav_msgs
  visualization_msgs
  geometry_msgs
  std_srvs
  octomap
  octomap_msgs
  message_filters
  tf2_ros
  tf2_msgs
  tf2
  tf2_geometry_msgs
  rclcpp_components
  )
@macnack
Copy link
Contributor

macnack commented Oct 30, 2023

Issue fixed #17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants