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 Harmonic #185

Merged
merged 3 commits into from
Oct 10, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Humble | Fortress | [ros2](https://github.com/ros-controls/gz_ros2_control/tree/
Rolling | Edifice | [ros2](https://github.com/ros-controls/gz_ros2_control/tree/master) | only from source
Rolling | Fortress | [ros2](https://github.com/ros-controls/gz_ros2_control/tree/master) | https://packages.ros.org
Rolling | Garden (not released) | [ros2](https://github.com/ros-controls/gz_ros2_control/tree/master) | only from source
Rolling | Harmonic (not released) | [ros2](https://github.com/ros-controls/gz_ros2_control/tree/master) | only from source

## Build status

Expand All @@ -37,6 +38,7 @@ If you want compile this from source, you should choose the Gazebo version. The
```bash
export GZ_VERSION=fortress
export GZ_VERSION=garden
export GZ_VERSION=harmonic
```

Then create a workspace, clone the repo and compile it:
Expand Down
9 changes: 9 additions & 0 deletions gz_ros2_control/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,15 @@ if("$ENV{GZ_VERSION}" STREQUAL "garden")
set(GZ_PLUGIN gz-plugin${GZ_PLUGIN_VER}::register)
set(GZ_SIM gz-sim${GZ_SIM_VER}::core)
add_definitions(-DGZ_HEADERS)
elseif("$ENV{GZ_VERSION}" STREQUAL "harmonic")
find_package(gz-sim8 REQUIRED)
set(GZ_SIM_VER ${gz-sim8_VERSION_MAJOR})
message(STATUS "Compiling against Gazebo Harmonic")
find_package(gz-plugin2 REQUIRED)
set(GZ_PLUGIN_VER ${gz-plugin2_VERSION_MAJOR})
set(GZ_PLUGIN gz-plugin${GZ_PLUGIN_VER}::register)
set(GZ_SIM gz-sim${GZ_SIM_VER}::core)
add_definitions(-DGZ_HEADERS)
else()
find_package(ignition-gazebo6 REQUIRED)
set(GZ_SIM_VER ${ignition-gazebo6_VERSION_MAJOR})
Expand Down
2 changes: 2 additions & 0 deletions gz_ros2_control/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,12 @@
<depend condition="$GZ_VERSION == ''">ignition-gazebo6</depend>
<depend condition="$GZ_VERSION == fortress">ignition-gazebo6</depend>
<depend condition="$GZ_VERSION == garden">gz-sim7</depend>
<depend condition="$GZ_VERSION == harmonic">gz-sim8</depend>

<depend condition="$GZ_VERSION == ''">ignition-plugin</depend>
<depend condition="$GZ_VERSION == fortress">ignition-plugin</depend>
<depend condition="$GZ_VERSION == garden">gz-plugin2</depend>
<depend condition="$GZ_VERSION == harmonic">gz-plugin2</depend>
<depend>pluginlib</depend>
<depend>rclcpp</depend>
<depend>yaml_cpp_vendor</depend>
Expand Down
1 change: 1 addition & 0 deletions gz_ros2_control_demos/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
<exec_depend>rclcpp</exec_depend>
<exec_depend>robot_state_publisher</exec_depend>
<exec_depend condition="$GZ_VERSION == ''">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'harmonic'">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'garden'">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'fortress'">ros_ign_gazebo</exec_depend>
<exec_depend>ros2controlcli</exec_depend>
Expand Down
1 change: 1 addition & 0 deletions gz_ros2_control_tests/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
<exec_depend>rclcpp</exec_depend>
<exec_depend>robot_state_publisher</exec_depend>
<exec_depend condition="$GZ_VERSION == ''">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'harmonic'">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'garden'">ros_gz_sim</exec_depend>
<exec_depend condition="$GZ_VERSION == 'fortress'">ros_ign_gazebo</exec_depend>
<exec_depend>ros2controlcli</exec_depend>
Expand Down