diff --git a/.github/ci/packages.apt b/.github/ci/packages.apt index 47929314..ff7c066a 100644 --- a/.github/ci/packages.apt +++ b/.github/ci/packages.apt @@ -1,3 +1,3 @@ -libgz-cmake3-dev -libgz-tools2-dev -libgz-utils2-cli-dev +libgz-cmake4-dev +libgz-tools3-dev +libgz-utils3-cli-dev diff --git a/CMakeLists.txt b/CMakeLists.txt index d0313c8f..da6832e9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -8,8 +8,8 @@ project(gz-plugin3 VERSION 3.0.0) #============================================================================ # Find gz-cmake #============================================================================ -find_package(gz-cmake3 REQUIRED) -set(GZ_CMAKE_VER ${gz-cmake3_VERSION_MAJOR}) +find_package(gz-cmake4 REQUIRED) +set(GZ_CMAKE_VER ${gz-cmake4_VERSION_MAJOR}) #============================================================================ # Configure the project @@ -49,8 +49,8 @@ set(GZ_TOOLS_VER 2) #-------------------------------------- # Find gz-utils -gz_find_package(gz-utils2 REQUIRED COMPONENTS cli) -set(GZ_UTILS_VER ${gz-utils2_VERSION_MAJOR}) +gz_find_package(gz-utils3 REQUIRED COMPONENTS cli) +set(GZ_UTILS_VER ${gz-utils3_VERSION_MAJOR}) #============================================================================ # Configure the build diff --git a/MigrationFromCommon.md b/MigrationFromCommon.md index 064cc52e..63743ba9 100644 --- a/MigrationFromCommon.md +++ b/MigrationFromCommon.md @@ -11,7 +11,7 @@ framework. Some of the instructions here may also be useful to new adopters of just wants to use `PluginPtr` objects can link to `core`, e.g.: ``` -target_link_libraries(my_target PUBLIC gz-plugin2::core) +target_link_libraries(my_target PUBLIC gz-plugin3::core) ``` However, if your code wants to be able to load plugins, it should link to the @@ -19,7 +19,7 @@ However, if your code wants to be able to load plugins, it should link to the need the `gz::plugin::Loader` class to be part of your library's API: ``` -target_link_libraries(my_target PRIVATE gz-plugin2::loader) +target_link_libraries(my_target PRIVATE gz-plugin3::loader) ``` If `gz::plugin::PluginPtr` objects are part of your library's API, then @@ -28,9 +28,9 @@ you may want `loader` to be private while `core` is public: ``` target_link_libraries(my_target PUBLIC - gz-plugin2::core + gz-plugin3::core PRIVATE - gz-plugin2::loader + gz-plugin3::loader ) ``` @@ -39,7 +39,7 @@ then you should link against the `register` component. This should almost always be a private link, since plugin registration is purely internal for a library: ``` -target_link_libraries(my_plugin PRIVATE gz-plugin2::register) +target_link_libraries(my_plugin PRIVATE gz-plugin3::register) ``` # Registering a plugin diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 161179ab..ad2914c7 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -5,11 +5,11 @@ project(examples) find_package(gz-plugin3 QUIET REQUIRED COMPONENTS all) set(GZ_PLUGIN_VER ${gz-plugin3_VERSION_MAJOR}) -find_package(gz-common5 QUIET) -set(GZ_COMMON_VER ${gz-common5_VERSION_MAJOR}) +find_package(gz-common6 QUIET) +set(GZ_COMMON_VER ${gz-common6_VERSION_MAJOR}) -find_package(gz-math7 QUIET) -set(GZ_MATH_VER ${gz-math7_VERSION_MAJOR}) +find_package(gz-math8 QUIET) +set(GZ_MATH_VER ${gz-math8_VERSION_MAJOR}) add_subdirectory(plugins) diff --git a/loader/conf/CMakeLists.txt b/loader/conf/CMakeLists.txt index 5d5cc2f2..026bd3d1 100644 --- a/loader/conf/CMakeLists.txt +++ b/loader/conf/CMakeLists.txt @@ -3,7 +3,7 @@ set(gz_library_path "${CMAKE_BINARY_DIR}/test/lib/$/ruby/gz/cmd${GZ_DESI # Generate a configuration file for internal testing. # Note that the major version of the library is included in the name. -# Ex: plugin2.yaml +# Ex: plugin3.yaml configure_file( "${GZ_DESIGNATION}.yaml.in" "${CMAKE_CURRENT_BINARY_DIR}/${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.yaml.configured" @ONLY) @@ -17,7 +17,7 @@ set(gz_library_path "${CMAKE_INSTALL_PREFIX}/lib/ruby/gz/cmd${GZ_DESIGNATION}${P # Generate the configuration file that is installed. # Note that the major version of the library is included in the name. -# Ex: plugin2.yaml +# Ex: plugin3.yaml configure_file( "${GZ_DESIGNATION}.yaml.in" "${CMAKE_CURRENT_BINARY_DIR}/${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.yaml" @ONLY) diff --git a/loader/src/cmd/CMakeLists.txt b/loader/src/cmd/CMakeLists.txt index 5dd10665..f2e65249 100644 --- a/loader/src/cmd/CMakeLists.txt +++ b/loader/src/cmd/CMakeLists.txt @@ -24,7 +24,7 @@ install( #=============================================================================== # Generate the ruby script for internal testing. # Note that the major version of the library is included in the name. -# Ex: cmdplugin2.rb +# Ex: cmdplugin3.rb set(cmd_script_generated_test "${CMAKE_BINARY_DIR}/test/lib/$/ruby/gz/cmd${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.rb") set(cmd_script_configured_test "${CMAKE_CURRENT_BINARY_DIR}/test_cmd${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.rb.configured") @@ -46,7 +46,7 @@ file(GENERATE # Used for the installed version. # Generate the ruby script that gets installed. # Note that the major version of the library is included in the name. -# Ex: cmdplugin2.rb +# Ex: cmdplugin3.rb set(cmd_script_generated "${CMAKE_CURRENT_BINARY_DIR}/$/cmd${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.rb") set(cmd_script_configured "${CMAKE_CURRENT_BINARY_DIR}/cmd${GZ_DESIGNATION}${PROJECT_VERSION_MAJOR}.rb.configured") diff --git a/test/integration/plugin.cc b/test/integration/plugin.cc index f3933523..2f165212 100644 --- a/test/integration/plugin.cc +++ b/test/integration/plugin.cc @@ -257,54 +257,54 @@ void TestSetAndMapUsage( const gz::plugin::PluginPtr &plugin) { PluginPtrType1 plugin1 = plugin; - PluginPtrType2 plugin2 = plugin1; + PluginPtrType2 plugin3 = plugin1; EXPECT_TRUE(plugin1 == plugin); - EXPECT_TRUE(plugin1 == plugin2); - EXPECT_FALSE(plugin1 != plugin2); + EXPECT_TRUE(plugin1 == plugin3); + EXPECT_FALSE(plugin1 != plugin3); - EXPECT_TRUE(plugin2 == plugin); - EXPECT_TRUE(plugin2 == plugin1); - EXPECT_FALSE(plugin2 != plugin1); + EXPECT_TRUE(plugin3 == plugin); + EXPECT_TRUE(plugin3 == plugin1); + EXPECT_FALSE(plugin3 != plugin1); std::set orderedSet; EXPECT_TRUE(orderedSet.insert(plugin1).second); EXPECT_FALSE(orderedSet.insert(plugin1).second); - EXPECT_FALSE(orderedSet.insert(plugin2).second); + EXPECT_FALSE(orderedSet.insert(plugin3).second); std::unordered_set unorderedSet; EXPECT_TRUE(unorderedSet.insert(plugin1).second); EXPECT_FALSE(unorderedSet.insert(plugin1).second); - EXPECT_FALSE(unorderedSet.insert(plugin2).second); + EXPECT_FALSE(unorderedSet.insert(plugin3).second); std::map orderedMap; EXPECT_TRUE(orderedMap.insert(std::make_pair(plugin1, "some string")).second); EXPECT_FALSE(orderedMap.insert(std::make_pair(plugin1, "a string")).second); - EXPECT_FALSE(orderedMap.insert(std::make_pair(plugin2, "chars")).second); + EXPECT_FALSE(orderedMap.insert(std::make_pair(plugin3, "chars")).second); std::unordered_map unorderedMap; EXPECT_TRUE(unorderedMap.insert(std::make_pair(plugin1, "strings")).second); EXPECT_FALSE(unorderedMap.insert(std::make_pair(plugin1, "letters")).second); - EXPECT_FALSE(unorderedMap.insert(std::make_pair(plugin2, "")).second); + EXPECT_FALSE(unorderedMap.insert(std::make_pair(plugin3, "")).second); - plugin2 = loader.Instantiate("test::util::DummyMultiPlugin"); - EXPECT_TRUE(plugin1 != plugin2); - EXPECT_FALSE(plugin1 == plugin2); - EXPECT_TRUE(plugin2 != plugin1); - EXPECT_FALSE(plugin2 == plugin1); + plugin3 = loader.Instantiate("test::util::DummyMultiPlugin"); + EXPECT_TRUE(plugin1 != plugin3); + EXPECT_FALSE(plugin1 == plugin3); + EXPECT_TRUE(plugin3 != plugin1); + EXPECT_FALSE(plugin3 == plugin1); - EXPECT_TRUE(orderedSet.insert(plugin2).second); - EXPECT_FALSE(orderedSet.insert(plugin2).second); + EXPECT_TRUE(orderedSet.insert(plugin3).second); + EXPECT_FALSE(orderedSet.insert(plugin3).second); - EXPECT_TRUE(unorderedSet.insert(plugin2).second); - EXPECT_FALSE(unorderedSet.insert(plugin2).second); + EXPECT_TRUE(unorderedSet.insert(plugin3).second); + EXPECT_FALSE(unorderedSet.insert(plugin3).second); - EXPECT_TRUE(orderedMap.insert(std::make_pair(plugin2, "letters")).second); - EXPECT_FALSE(orderedMap.insert(std::make_pair(plugin2, "chars")).second); + EXPECT_TRUE(orderedMap.insert(std::make_pair(plugin3, "letters")).second); + EXPECT_FALSE(orderedMap.insert(std::make_pair(plugin3, "chars")).second); - EXPECT_TRUE(unorderedMap.insert(std::make_pair(plugin2, "abc")).second); - EXPECT_FALSE(unorderedMap.insert(std::make_pair(plugin2, "def")).second); + EXPECT_TRUE(unorderedMap.insert(std::make_pair(plugin3, "abc")).second); + EXPECT_FALSE(unorderedMap.insert(std::make_pair(plugin3, "def")).second); } ///////////////////////////////////////////////// diff --git a/tutorials/02_installation.md b/tutorials/02_installation.md index 37603a42..16b17f7a 100644 --- a/tutorials/02_installation.md +++ b/tutorials/02_installation.md @@ -35,19 +35,19 @@ wget http://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add - On Ubuntu systems, `apt-get` can be used to install `gz-plugin`: ```bash sudo apt-get update -sudo apt install libgz-plugin2-dev +sudo apt install libgz-plugin3-dev ``` ## Source Installation 1. Install Gazebo dependencies ``` - sudo apt-get install libgz-cmake3-dev libgz-tools2-dev libgz-utils2-cli-dev + sudo apt-get install libgz-cmake4-dev libgz-tools3-dev libgz-utils3-cli-dev ``` 1. Install Gazebo Tools if you want to use the `gz plugin` command line tool: ```bash - sudo apt-get install gz-tools2 + sudo apt-get install gz-tools3 ``` 2. Clone the repository @@ -91,7 +91,7 @@ Sierra (10.12) or later. 2. Run the following commands ```bash brew tap osrf/simulation - brew install gz-plugin2 + brew install gz-plugin3 ``` ## Source Installation @@ -99,7 +99,7 @@ Sierra (10.12) or later. 1. Install dependencies ```bash brew tap osrf/simulation - brew install gz-plugin2 --only-dependencies + brew install gz-plugin3 --only-dependencies ``` 2. Clone the repository