Current Gazebo releases include the major version number of a Gazebo package in its package name. This allows multiple versions of packages to be installed side-by-side but induces churn each year for the maintainers when releasing new versions and for users when upgrading to new versions. For example, when upgrading from Harmonic to Ionic:
- In cmake, change
find_package(gz-math7)
tofind_package(gz-math8)
and any references togz-math7::*
cmake targets togz-math8::*
- In python, change
import gz.math7
toimport gz-math8
- In package.xml, change
<depend>gz-math7</depend>
to<depend>gz-math8</depend>
The Gazebo PMC has decided to change package names in Gazebo Jetty to not include version names (with the exception of gz-tools, which will be explained below), following the proposal in gazebo-tooling/release-tools#1244 (comment) with the following user-facing changes:
- The version number is removed from cmake project names (
gz-math
) and shared library names (libgz-math.so
). - In cmake, you can
find_package(gz-math)
and link to thegz-math::gz-math
cmake target. Note that you can still find a specific version using the second argument:find_package(gz-math 9.0)
. - In python, you can
import gz.math
- In package.xml, you can
<depend>gz-math</depend>
The migration to Gazebo Jetty will be the last time users need to modify these bits of code when upgrading.
The trade-off is that future versions of Gazebo will not be side-by-side installable in the same prefix, since cmake configuration files and python bindings with the same names will conflict with each other. Given that colcon workspaces and containers provide other options to install multiple versions of Gazebo on the same system, the Gazebo PMC decided this was an acceptable trade-off. This consequence will not be immediately felt, however, as Jetty will be side-by-side installable with Ionic, Harmonic, and Fortress that have versioned package names. This is possible because of the one exception to continue using the same gz-tools2 version in Jetty that is also used in Ionic to avoid name conflicts with the gz
executable. With the Gazebo K release, the package will be renamed to gz-tools with major version 3.
To reduce the scope of this change, version numbers have not yet been removed from debian package names (libgz-math9-dev
), though this is under consideration for the future. See the discussion in gazebo-tooling/release-tools#1244 for further details.