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

[humble] rosbag2_storage links to deprecated target #1830

Open
PizzocaroSolomon opened this issue Oct 11, 2024 · 4 comments
Open

[humble] rosbag2_storage links to deprecated target #1830

PizzocaroSolomon opened this issue Oct 11, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@PizzocaroSolomon
Copy link

Hello everyone,

We have a project containing targets linking to rosbag2_storage and the standard yaml-cpp library.
During compilation, we get the following CMake warning:

image

We're certain that all our targets are linking to yaml-cpp using the target yaml-cpp::yaml-cpp.

Inside "/opt/ros/humble/share/rosbag2_storage/cmake/export_rosbag2_storageExport.cmake" we noticed the following lines:

set_target_properties(rosbag2_storage::rosbag2_storage PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include/rosbag2_storage" INTERFACE_LINK_LIBRARIES "pluginlib::pluginlib;rcpputils::rcpputils;rcutils::rcutils;yaml-cpp" )

and substituting "yaml-cpp" with "yaml-cpp::yaml-cpp", the warning disappears.

We are convinced that this is a dirty solution to our problem.
Do you have any suggestions on what we can do to remove the warning cleanly?
Is it possible to add this "fix" to one of the next releases of ROS2 humble?

thank you very much!

@PizzocaroSolomon PizzocaroSolomon added the bug Something isn't working label Oct 11, 2024
@clalancette
Copy link
Contributor

and substituting "yaml-cpp" with "yaml-cpp::yaml-cpp", the warning disappears.

The problem, as far as I remember, is that on Humble we have to use the yaml-cpp target; the yaml-cpp::yaml-cpp target did not exist there.

Are you using a custom compiled version of yaml-cpp?

@PizzocaroSolomon
Copy link
Author

That is correct, we do have a compiled version (latest) of yaml-cpp in our system.
Is ROS2 providing its own version (I see a yaml_cpp_vendor)? Will that version be updated?

thank you very much

@clalancette
Copy link
Contributor

Is ROS2 providing its own version (I see a yaml_cpp_vendor)?

Sort of. yaml_cpp_vendor is used to provide yaml-cpp on those platforms that don't have it (like Windows). On Ubuntu, we actually use the system version of the package.

Will that version be updated?

Only if Ubuntu updates it in Ubuntu 22.04 (which is highly unlikely).

@PizzocaroSolomon
Copy link
Author

PizzocaroSolomon commented Oct 11, 2024

Ok understood. Is there a way we can "force" rosbag2_storage to keep pointing to the system version of yaml-cpp and not the one we are installing? I guess one solution would be to install our custom version in a different way...

Note: I saw that also in the system version the target yaml-cpp::yaml-cpp exists check here.
What did not exist was the warning message.
This means that rosbag2_storage would still compile if the target is updated to yaml-cpp::yaml-cpp.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants