-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Also include buildtool-depends in find_package(catkin ...) #31
base: master
Are you sure you want to change the base?
Also include buildtool-depends in find_package(catkin ...) #31
Conversation
I think that linking the exported targets to executables and libraries could be potentially dangerous. Since a buildtool depend could be providing the host libraries rather than the target system's libraries. This might have been why we didn't include it from the start. By message generation you mean they are included as dependencies in message generation? In ROS 1, this should be fine since messages only result in python code or headers, but if for example messages suddenly needed to export libraries as well (so that your message's libraries needed to link against the other package's message libraries) that might be dangerous. I think dynamic reconfigure should be safe. I don't imagine anyway that architecture would affect those activities. How hard would it be to exclude these activities for just buildtool depends? Thanks for the pr. |
What I said was actually not quite right. Let me try again. With build-depends catkin_simple does the following:
I can change the PR to do all, some, or none of these things for buildtool-depends, no problem. Maybe we actually just want to do 1. for buildtool-depends? What is actually supposed to happen with dependencies that are both build and buildtool depends? Is a double-specification needed in package.xml, or does build-depend imply buildtool-depend? I'm fishing in the dark here a little bit since I have never used neither catkin nor plain cmake in a cross-compilation situation. |
I suppose having a key be both a build_depend and a buildtool_depend might indicate that it needs both the host version of the dependency as well as the target version. For example, you could imagine that a package needs the host version of Python as well as the target version. The host version so it can invoke python scripts during the build and the target version so it can link against libpython and embed the target python executable's path in the |
But Out of the 8 things catkin_simple currently does with build-depends, do you agree that we only want 1. for buildtool-depends (i.e. only find-package them, no more)? |
Changes include: - Packages found with `find_package` that are no cmake packages are now used in `include_directories` and automatically linked to, using the standard `..._INCLUDE_DIRS` and `..._LIBRARIES` variables. Moreover, they are exported by being passed as `DEPENDS` in `catkin_package`. - Buildtool-depends are now also find-packaged. - `cs_export` now also has an option flag-argument `ALL_DEPS_REQUIRED`. - `cs_export` uses build(tool)-export depends, not run-depends to determine what is exported in the `catkin_package` call. - There is now an informative message about build(tool)-(export) depends that are listed in package.xml, but not found with `find_package`. This makes is easier to track down typos in catkin package names.
I updated this PR to only find-package buildtool-depends, and also export buildtool-export-depends, as well as some other changes. I will update the PR description. It includes the changes discussed in #7 (at least my current understanding) and depends on ros/catkin#790. |
This PR fixes #30 and #7.
It depends on ros/catkin#790.
Changes include:
find_package
that are no cmake packages are now used ininclude_directories
and automatically linked to, using the standard..._INCLUDE_DIRS
and..._LIBRARIES
variables. Moreover, they are exportedby being passed as
DEPENDS
incatkin_package
.cs_export
now also has an option flag-argumentALL_DEPS_REQUIRED
.cs_export
uses build(tool)-export depends, not run-depends to determine whatis exported in the
catkin_package
call.are listed in package.xml, but not found with
find_package
. This makes iseasier to track down typos in catkin package names.
package.xml
is now format 2It is not ready to be merged, since it needs some tests at the very least.