Allow tesseract_collision plugins to be found by ROS2 packages #130
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is part of a workaround for an issue in ROS2 pluginlib (ros/pluginlib#161). Briefly, the ROS2 implementation of ClassLoader uses
ament_index_cpp::get_package_prefix()
when loading plugins, which makes it difficult to load plugins from non-ROS libraries since they aren't added to theAMENT_PREFIX_PATH
environment variable and don't have some ROS2-specific config files in their packageshare
directory.This change solves the second of these problems by writing an empty file to
ros2_ws/install/tesseract_collision/share/ament_index/resource_index/packages/tesseract_collision
when the package is built.I think that the first problem will need to be handled separately. So far I've been adding the path to the installed location of
tesseract_collision
toAMENT_PREFIX_PATH
in my launch files.