Gazebo | Ignition | Community
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How to Build ros2_gz Humble from Source on Linux jammy

ROS2 Humble and Gazebo Garden are installed in Linux 22.04 aarch64/arm64 (VM on MAC M1)

Following https://github.com/gazebosim/ros_gz/tree/humble , Build from Source. rosdep and colcon build fail.

ubuntu@macvm-ub22h-r2:~/ws$ rosdep install -r --from-paths src -i -y --rosdistro humble ERROR: the following packages/stacks could not have their rosdep keys resolved to system dependencies: ros_gz_sim: No definition of [ignition-gazebo5] for OS version [jammy] ros_gz_bridge: No definition of [ignition-transport10] for OS version [jammy] ros_gz_image: No definition of [ignition-transport10] for OS version [jammy] ros_gz_sim_demos: No definition of [ignition-gazebo5] for OS version [jammy] Continuing to install resolvable dependencies...

All required rosdeps installed successfully

ubuntu@macvm-ub22h-r2:~/ws$ source /opt/ros/humble/setup.bash ubuntu@macvm-ub22h-r2:~/ws$ colcon build [0.326s] WARNING:colcon.colcon_core.package_selection:Some selected packages are already built in one or more underlay workspaces: 'ros_ign_gazebo' is in: /opt/ros/humble 'ros_ign_image' is in: /opt/ros/humble 'ros_ign_gazebo_demos' is in: /opt/ros/humble 'ros_ign_interfaces' is in: /opt/ros/humble 'ros_ign_bridge' is in: /opt/ros/humble If a package in a merged underlay workspace is overridden and it installs headers, then all packages in the overlay must sort their include directories by workspace order. Failure to do so may result in build failures or undefined behavior at run time. If the overridden package is used by another package in any underlay, then the overriding package in the overlay must be API and ABI compatible or undefined behavior at run time may occur.

If you understand the risks and want to override a package anyways, add the following to the command line: --allow-overriding ros_ign_bridge ros_ign_gazebo ros_ign_gazebo_demos ros_ign_image ros_ign_interfaces

This may be promoted to an error in a future release of colcon-override-check. Starting >>> ros_gz_interfaces Starting >>> ros_gz_sim --- stderr: ros_gz_sim
CMake Error at CMakeLists.txt:28 (find_package): By not providing "Findignition-transport10.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "ignition-transport10", but CMake did not find one.

Could not find a package configuration file provided by "ignition-transport10" with any of the following names:

ignition-transport10Config.cmake
ignition-transport10-config.cmake

Add the installation prefix of "ignition-transport10" to CMAKE_PREFIX_PATH or set "ignition-transport10_DIR" to a directory containing one of the above files. If "ignition-transport10" provides a separate development

package or SDK, be sure it has been installed.

Failed <<< ros_gz_sim [1.38s, exited with code 1] Aborted <<< ros_gz_interfaces [1.81s]

Summary: 0 packages finished [1.98s] 1 package failed: ros_gz_sim 1 package aborted: ros_gz_interfaces 1 package had stderr output: ros_gz_sim 10 packages not processed ubuntu@macvm-ub22h-r2:~/ws$

I located this in answers.gazebo.org, installed the cmake-gui.exe but unable to determine the necessary paths. Where is path to ignition-transport10_DIR?

Found Solution now, I suggest you use cmake-gui.exe ,you will find at C:\Program Files\CMake\bin if you install on that directory

run cmake-gui.exe select path source code and select path to build run configure 1 time you will found error same edit path ignition-cmake0_DIR to gz-ws/ign-cmake/build/install/Release/lib/cmake/ignition-cmake0 Run again Done !!

Appreciate any assistance

How to Build ros2_gz Humble from Source on Linux jammy

ROS2 Humble and Gazebo Garden are installed in Linux 22.04 aarch64/arm64 (VM on MAC M1)

Following I edited my original Jan 18, 2023 as with further investigation, I discovered that ros_gz can be installed directly from posted binaries, once ¨gazebo sim Garden¨ was installed on my MAC M1 Ubuntu 22.04 arm64 Parallels Virtual Machine from Binary Installation on Ubuntu, (https://gazebosim.org/docs/garden/install_ubuntu ). With the local repositories updated, the two installation commands for gz-garden and ros_gz are $ sudo apt install gz-garden and $ sudo apt install ros-humble-ros-gz. So the https://github.com/gazebosim/ros_gz/tree/humble , Build instructions for this case of Binaries procedure can be significantly simplified and no compiling from Source. rosdep and colcon build fail.

ubuntu@macvm-ub22h-r2:~/ws$ rosdep install -r --from-paths src -i -y --rosdistro humble ERROR: the following packages/stacks could not have their rosdep keys resolved to system dependencies: ros_gz_sim: No definition of [ignition-gazebo5] for OS version [jammy] ros_gz_bridge: No definition of [ignition-transport10] for OS version [jammy] ros_gz_image: No definition of [ignition-transport10] for OS version [jammy] ros_gz_sim_demos: No definition of [ignition-gazebo5] for OS version [jammy] Continuing to install resolvable dependencies...

All required rosdeps installed successfully

ubuntu@macvm-ub22h-r2:~/ws$ source /opt/ros/humble/setup.bash ubuntu@macvm-ub22h-r2:~/ws$ colcon build [0.326s] WARNING:colcon.colcon_core.package_selection:Some selected packages are already built in one or more underlay workspaces: 'ros_ign_gazebo' is in: /opt/ros/humble 'ros_ign_image' is in: /opt/ros/humble 'ros_ign_gazebo_demos' is in: /opt/ros/humble 'ros_ign_interfaces' is in: /opt/ros/humble 'ros_ign_bridge' is in: /opt/ros/humble If a package in a merged underlay workspace is overridden and it installs headers, then all packages in the overlay must sort their include directories by workspace order. Failure to do so may result in build failures or undefined behavior at run time. If the overridden package is used by another package in any underlay, then the overriding package in the overlay must be API and ABI compatible or undefined behavior at run time may occur.

If you understand the risks and want to override a package anyways, add the following to the command line: --allow-overriding ros_ign_bridge ros_ign_gazebo ros_ign_gazebo_demos ros_ign_image ros_ign_interfaces

This may be promoted to an error in a future release of colcon-override-check. Starting >>> ros_gz_interfaces Starting >>> ros_gz_sim --- stderr: ros_gz_sim
CMake Error at CMakeLists.txt:28 (find_package): By not providing "Findignition-transport10.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "ignition-transport10", but CMake did not find one.

Could not find a package configuration file provided by "ignition-transport10" with any of the following names:

ignition-transport10Config.cmake
ignition-transport10-config.cmake

Add the installation prefix of "ignition-transport10" to CMAKE_PREFIX_PATH or set "ignition-transport10_DIR" to a directory containing one of the above files. If "ignition-transport10" provides a separate development

package or SDK, be sure it has been installed.

Failed <<< ros_gz_sim [1.38s, exited with code 1] Aborted <<< ros_gz_interfaces [1.81s]

Summary: 0 packages finished [1.98s] 1 package failed: ros_gz_sim 1 package aborted: ros_gz_interfaces 1 package had stderr output: ros_gz_sim 10 packages not processed ubuntu@macvm-ub22h-r2:~/ws$

I located this in answers.gazebo.org, installed the cmake-gui.exe but unable to determine the necessary paths. Where is path to ignition-transport10_DIR?

Found Solution now, I suggest you use cmake-gui.exe ,you will find at C:\Program Files\CMake\bin if you install on that directory

run cmake-gui.exe select path source code and select path to build run configure 1 time you will found error same edit path ignition-cmake0_DIR to gz-ws/ign-cmake/build/install/Release/lib/cmake/ignition-cmake0 Run again Done !!

Appreciate any assistancenecessary.