Skip to content

Conversation

@DLu
Copy link
Contributor

@DLu DLu commented May 8, 2025

As of the ROS 2 Kilted release ament_target_dependencies is deprecated.

This PR updates the syntax. Caution should be used to ensure that the target branch is not used for other ROS 2 distros.

Note: This PR was generated by a bot script, but using the simple pattern matching of the ros_glint library. No LLMs were used.

@mintar
Copy link
Collaborator

mintar commented May 8, 2025

This isn't working; the check fails with:

 In file included from /__w/imu_tools/imu_tools/src/imu_tools/imu_complementary_filter/src/complementary_filter_ros.cpp:34:
/__w/imu_tools/imu_tools/src/imu_tools/imu_complementary_filter/include/imu_complementary_filter/complementary_filter_ros.h:37:10: fatal error: sensor_msgs/msg/magnetic_field.hpp: No such file or directory
   37 | #include <sensor_msgs/msg/magnetic_field.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

According to ament/ament_cmake#572, there is a bit more work to do than just replacing ament_target_dependencies -> target_link_libraries. You also have to replace

  • geometry_msgs -> ${geometry_msgs_TARGETS}
  • message_filters -> message_filters::message_filters
  • ...

But which one's which? According to the ament PR, there should be a very helpful deprecation notice that you can just copy&paste, but somehow I cannot get it in the GitHub actions environment. I'm not sure if the deprecation notice is even already there in the current rolling Docker images. Since Kilted isn't released yet, there are also no Docker images for Kilted yet, which makes it even harder to test.

@mintar
Copy link
Collaborator

mintar commented May 9, 2025

Thanks, it's working now!

@mintar mintar merged commit ab49aa4 into CCNYRoboticsLab:rolling May 9, 2025
2 of 4 checks passed
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

Successfully merging this pull request may close these issues.

2 participants