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

<build_type> does not default to catkin if a false condition is present #1170

Open
Timple opened this issue Mar 22, 2022 · 4 comments
Open
Labels

Comments

@Timple
Copy link

Timple commented Mar 22, 2022

To reproduce: add the line <build_type condition="$ROS_VERSION == 2">ament_cmake</build_type> to a ROS1 package like stereo_msgs.

catkin_make_isolated will fail now.

Expected behavior: The complete line should be ignored because of the condition and the default of catkin should be used.


Interesting detail: This works:

<build_type condition="$ROS_VERSION == 1">catkin</build_type>
<build_type condition="$ROS_VERSION == 2">ament_cmake</build_type>

And this doesn't:

<build_type condition="$ROS_VERSION == 2">ament_cmake</build_type>
<build_type condition="$ROS_VERSION == 1">catkin</build_type>
@Gonzalo-Mier
Copy link

For the record, the error that happens is:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~  traversing 1 packages in topological order:
~~  - package_name (unknown)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: Packages with unknown build types exist
Can not build workspace with packages of unknown build_type

@tfoote tfoote added the bug label Apr 12, 2022
@MatthijsBurgh
Copy link
Contributor

@ivanpauno
Copy link
Collaborator

IIUC, this code block here should be updated to use get_build_type().

Contributions are welcomed, feel free to tag me as a reviewer.

@ros-discourse
Copy link

This issue has been mentioned on ROS Discourse. There might be relevant details there:

https://discourse.ros.org/t/automatic-deployment-of-ros2-based-system-to-remote-devices-dual-copy-or-containers/33884/42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants