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

Support yaml-cpp >= 0.8.0 #46

Merged
merged 1 commit into from
Feb 13, 2024
Merged

Support yaml-cpp >= 0.8.0 #46

merged 1 commit into from
Feb 13, 2024

Conversation

traversaro
Copy link
Contributor

Since yaml-cpp 0.8.0, the imported target of yaml-cpp is called yaml-cpp::yaml-cpp, not yaml-cpp.

To handle this, in this PR I modified the logic that sets yaml_cpp_vendor_TARGETS to set it to yaml-cpp::yaml-cpp if it exists. Furthermore, I also use the presence of yaml-cpp::yaml-cpp as a proxy to detect if yaml-cpp >= 0.8.0 is used, and avoid the manual setting of YAML_CPP_DLL as it is not needed anymore.

If yaml-cpp::yaml-cpp is not present (i.e. yaml-cpp <= 0.7.0), the logic remains exactly the one before this PR.

Related downstream comment: RoboStack/ros-humble#136 (comment) .

Signed-off-by: Silvio Traversaro <silvio@traversaro.it>
Copy link
Contributor

@clalancette clalancette left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix! This looks good to me, I'll run CI on it next.

@clalancette
Copy link
Contributor

CI:

  • Linux Build Status
  • Linux-aarch64 Build Status
  • Windows Build Status

@clalancette clalancette merged commit 7693ad2 into ros2:rolling Feb 13, 2024
3 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.

None yet

2 participants