From c29f924aa1e85b1a23f5ee389f575d1f20b52b80 Mon Sep 17 00:00:00 2001 From: Louise Poubel Date: Fri, 27 May 2022 10:31:02 -0700 Subject: [PATCH 1/4] Rename CMake project to gz Signed-off-by: Louise Poubel --- CMakeLists.txt | 4 +-- cmake/IgnCMake.cmake | 2 +- cmake/IgnPackaging.cmake | 8 ++--- cmake/IgnUtils.cmake | 14 ++++---- cmake/ign_auto_headers.hh.in | 2 +- cmake/ignition-component-config.cmake.in | 6 ++-- cmake/ignition-config.cmake.in | 6 ++-- cmake/pkgconfig/ignition-component.pc.in | 2 +- cmake/pkgconfig/ignition.pc.in | 2 +- examples/CMakeLists.txt | 24 ++++++------- examples/comp_deps/CMakeLists.txt | 4 +-- examples/core_child/CMakeLists.txt | 8 ++--- examples/core_child/src/CMakeLists.txt | 2 +- examples/core_child_private/CMakeLists.txt | 8 ++--- .../core_child_private/src/CMakeLists.txt | 2 +- examples/core_nodep/CMakeLists.txt | 4 +-- examples/core_nodep_static/CMakeLists.txt | 4 +-- examples/core_static_child/CMakeLists.txt | 8 ++--- examples/core_static_child/src/CMakeLists.txt | 2 +- examples/find_ogre2/ogre-2.1/CMakeLists.txt | 2 +- examples/find_ogre2/ogre-2.2/CMakeLists.txt | 4 +-- examples/ign_conf/CMakeLists.txt | 4 +-- examples/no_ignition_prefix/CMakeLists.txt | 2 +- examples/prerelease/CMakeLists.txt | 4 +-- examples/sanitizers/CMakeLists.txt | 4 +-- ...test_core_child_requires_core_no_deps.bash | 36 +++++++++---------- examples/use_component_depsA/CMakeLists.txt | 6 ++-- .../use_component_depsA/src/CMakeLists.txt | 2 +- examples/use_component_depsB/CMakeLists.txt | 6 ++-- .../use_component_depsB/src/CMakeLists.txt | 2 +- examples/use_component_depsC/CMakeLists.txt | 6 ++-- .../use_component_depsC/src/CMakeLists.txt | 2 +- examples/use_config_ifp/CMakeLists.txt | 14 ++++---- ..._config.cmake => Findgz-find_config.cmake} | 0 ...onfig.cmake => gz-find_configConfig.cmake} | 0 35 files changed, 103 insertions(+), 103 deletions(-) rename examples/use_config_ifp/{Findignition-find_config.cmake => Findgz-find_config.cmake} (100%) rename examples/use_config_ifp/{ignition-find_configConfig.cmake => gz-find_configConfig.cmake} (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 888ab305..bf2e7f16 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) #============================================================================ # Initialize the project #============================================================================ -project(ignition-cmake3 VERSION 3.0.0) +project(gz-cmake3 VERSION 3.0.0) #-------------------------------------- # Initialize the IGNITION_CMAKE_DIR variable with the location of the cmake @@ -59,7 +59,7 @@ set(gz_config_output "${PROJECT_NAME_LOWER}-config.cmake") set(gz_version_output "${PROJECT_NAME_LOWER}-config-version.cmake") set(gz_config_install_dir "${CMAKE_INSTALL_DATAROOTDIR}/cmake/${PROJECT_NAME_LOWER}") set(ign_pkgconfig_input "${CMAKE_CURRENT_SOURCE_DIR}/config/ignition-cmake.pc.in") -set(ign_pkgconfig_output "${CMAKE_BINARY_DIR}/ignition-cmake${PROJECT_VERSION_MAJOR}.pc") +set(ign_pkgconfig_output "${CMAKE_BINARY_DIR}/${PROJECT_NAME}.pc") set(ign_pkgconfig_install_dir "${IGN_LIB_INSTALL_DIR}/pkgconfig") set(ign_utilities_target ${PROJECT_EXPORT_NAME}-utilities) set(ign_utilities_import_target_name ${PROJECT_EXPORT_NAME}::${ign_utilities_target}) diff --git a/cmake/IgnCMake.cmake b/cmake/IgnCMake.cmake index b4aa7e30..9a88e2cb 100644 --- a/cmake/IgnCMake.cmake +++ b/cmake/IgnCMake.cmake @@ -20,7 +20,7 @@ # limitations under the License. #============================================================================ -# ignition-cmake modules +# gz-cmake modules #============================================================================ include(IgnUtils) include(IgnConfigureProject) diff --git a/cmake/IgnPackaging.cmake b/cmake/IgnPackaging.cmake index a8b22f06..0b320590 100644 --- a/cmake/IgnPackaging.cmake +++ b/cmake/IgnPackaging.cmake @@ -175,10 +175,10 @@ endmacro() # component's name. # # NOTE: This will be called automatically by gz_create_core_library(~) and -# gz_add_component(~), so users of ignition-cmake should not call this +# gz_add_component(~), so users of gz-cmake should not call this # function. # -# NOTE: For ignition-cmake developers, the variables needed by ignition.pc.in or +# NOTE: For gz-cmake developers, the variables needed by ignition.pc.in or # ignition-component.pc.in MUST be set before calling this function. # # Create a pkgconfig file for your target, and install it. @@ -235,10 +235,10 @@ endfunction() # can be used to specify the prefix of these variables. # # NOTE: This will be called automatically by gz_create_core_library(~) and -# gz_add_component(~), so users of ignition-cmake should not call this +# gz_add_component(~), so users of gz-cmake should not call this # function. # -# NOTE: For ignition-cmake developers, some of the variables needed by +# NOTE: For gz-cmake developers, some of the variables needed by # ignition-config.cmake.in or ignition-component-config.cmake.in MUST be # set before calling this function. The following variables are set # automatically by this function: diff --git a/cmake/IgnUtils.cmake b/cmake/IgnUtils.cmake index bbde0577..26c143c2 100644 --- a/cmake/IgnUtils.cmake +++ b/cmake/IgnUtils.cmake @@ -109,7 +109,7 @@ # ========================================================================== # The following arguments pertain to the automatic generation of your # project's pkgconfig file. Ideally, this information should be provided -# automatically by ignition-cmake through the cmake find-module that is written +# automatically by gz-cmake through the cmake find-module that is written # for your dependency. However, if your package gets distributed with its own # cmake config-file or find-module, then it might not automatically set this # information. Therefore, we provide the ability to set it through your call to @@ -827,7 +827,7 @@ function(gz_install_all_headers) message(FATAL_ERROR "Developer error: You are missing the file [${config_header_in}]! " "Did you forget to move it from your project's cmake directory while " - "migrating to the use of ignition-cmake?") + "migrating to the use of gz-cmake?") endif() # Generate the "config" header that describes our project configuration @@ -1425,14 +1425,14 @@ endfunction() # Used internally by _gz_add_library_or_component to report argument errors macro(_gz_add_library_or_component_arg_error missing_arg) - message(FATAL_ERROR "ignition-cmake developer error: Must specify " + message(FATAL_ERROR "gz-cmake developer error: Must specify " "${missing_arg} to _gz_add_library_or_component!") endmacro() ################################################# -# This is only meant for internal use by ignition-cmake. If you are a consumer -# of ignition-cmake, please use gz_create_core_library(~) or +# This is only meant for internal use by gz-cmake. If you are a consumer +# of gz-cmake, please use gz_create_core_library(~) or # gz_add_component(~) instead of this. # # _gz_add_library_or_component(LIB_NAME @@ -1822,7 +1822,7 @@ macro(gz_build_tests) if(NOT gz_build_tests_TYPE) # If you have encountered this error, you are probably migrating to the - # new ignition-cmake system. Be sure to also provide a SOURCES argument + # new gz-cmake system. Be sure to also provide a SOURCES argument # when calling gz_build_tests. message(FATAL_ERROR "Developer error: You must specify a TYPE for your tests!") endif() @@ -1933,7 +1933,7 @@ macro(_gz_cmake_parse_arguments prefix options oneValueArgs multiValueArgs) "\nThe build script has specified some unrecognized arguments for ${prefix}(~):\n" "${${prefix}_UNPARSED_ARGUMENTS}\n" "Either the script has a typo, or it is using an unexpected version of ign-cmake. " - "The version of ign-cmake currently being used is ${ignition-cmake${IGNITION_CMAKE_VERSION_MAJOR}_VERSION}\n") + "The version of gz-cmake currently being used is ${gz-cmake${IGNITION_CMAKE_VERSION_MAJOR}_VERSION}\n") endif() diff --git a/cmake/ign_auto_headers.hh.in b/cmake/ign_auto_headers.hh.in index a078c63b..9a64c883 100644 --- a/cmake/ign_auto_headers.hh.in +++ b/cmake/ign_auto_headers.hh.in @@ -17,7 +17,7 @@ // ****** Do not modify this file. ****** // This file is automatically generated by CMake. Changes should instead be -// made to cmake/ign_auto_headers.hh.in in ignition-cmake +// made to cmake/ign_auto_headers.hh.in in gz-cmake #include <@PROJECT_INCLUDE_DIR@/config.hh> ${ign_headers} diff --git a/cmake/ignition-component-config.cmake.in b/cmake/ignition-component-config.cmake.in index 5a224e85..a1e1dd4e 100644 --- a/cmake/ignition-component-config.cmake.in +++ b/cmake/ignition-component-config.cmake.in @@ -45,9 +45,9 @@ endif() # Get access to the find_dependency utility include(CMakeFindDependencyMacro) -# Find ignition-cmake, because we need its modules in order to find the rest of +# Find gz-cmake, because we need its modules in order to find the rest of # our dependencies. -find_dependency(ignition-cmake@IGNITION_CMAKE_VERSION_MAJOR@) +find_dependency(gz-cmake@IGNITION_CMAKE_VERSION_MAJOR@) # Set the REQUIRED flag for the find_package(~) calls on this component's # dependencies. @@ -109,6 +109,6 @@ endif() set(@component_pkg_name@_LIBRARY @import_target_name@) -# This macro is used by ignition-cmake to automatically configure the pkgconfig +# This macro is used by gz-cmake to automatically configure the pkgconfig # files for ignition projects. gz_pkg_config_entry(@component_pkg_name@ "@component_pkg_name@") diff --git a/cmake/ignition-config.cmake.in b/cmake/ignition-config.cmake.in index 0768c0ed..279cdfe6 100644 --- a/cmake/ignition-config.cmake.in +++ b/cmake/ignition-config.cmake.in @@ -58,9 +58,9 @@ set(@PKG_NAME@_CONFIG_INCLUDED TRUE) # Get access to the find_dependency utility include(CMakeFindDependencyMacro) -# Find ignition-cmake, because we need its modules in order to find the rest of +# Find gz-cmake, because we need its modules in order to find the rest of # our dependencies. -find_dependency(ignition-cmake@IGNITION_CMAKE_VERSION_MAJOR@) +find_dependency(gz-cmake@IGNITION_CMAKE_VERSION_MAJOR@) # Set the REQUIRED flag for the find_package(~) calls on this project's # dependencies. @@ -143,7 +143,7 @@ set_and_check(@PKG_NAME@_INCLUDE_DIRS "@PACKAGE_IGN_INCLUDE_INSTALL_DIR_FULL@") set(@LEGACY_PROJECT_PREFIX@_LIBRARIES ${@PKG_NAME@_LIBRARIES}) set(@LEGACY_PROJECT_PREFIX@_INCLUDE_DIRS ${@PKG_NAME@_INCLUDE_DIRS}) -# This macro is used by ignition-cmake to automatically configure the pkgconfig +# This macro is used by gz-cmake to automatically configure the pkgconfig # files for ignition projects. gz_pkg_config_entry(@PKG_NAME@ "@PKG_NAME@") diff --git a/cmake/pkgconfig/ignition-component.pc.in b/cmake/pkgconfig/ignition-component.pc.in index 3b2a3710..fd08ea57 100644 --- a/cmake/pkgconfig/ignition-component.pc.in +++ b/cmake/pkgconfig/ignition-component.pc.in @@ -4,7 +4,7 @@ includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@IGN_INCLUDE_INSTALL_DIR_POSTFIX Name: Ignition @IGN_DESIGNATION@ @component_name@ Description: A set of @IGN_DESIGNATION@ @component_name@ classes for robot applications -Version: ignition-cmake@IGNITION_CMAKE_VERSION_MAJOR@ >= 1.1 @PROJECT_VERSION_FULL_NO_SUFFIX@ +Version: @PROJECT_VERSION_FULL_NO_SUFFIX@ Requires: @component_pkgconfig_requires@ Requires.private: @component_pkgconfig_requires_private@ Libs: -L${libdir} @component_pkgconfig_lib@ @component_pkgconfig_lib_deps@ diff --git a/cmake/pkgconfig/ignition.pc.in b/cmake/pkgconfig/ignition.pc.in index 2342f716..e6cd8748 100644 --- a/cmake/pkgconfig/ignition.pc.in +++ b/cmake/pkgconfig/ignition.pc.in @@ -5,7 +5,7 @@ includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@IGN_INCLUDE_INSTALL_DIR_POSTFIX Name: Ignition @IGN_DESIGNATION@ Description: A set of @IGN_DESIGNATION@ classes for robot applications Version: @PROJECT_VERSION_FULL_NO_SUFFIX@ -Requires: ignition-cmake@IGNITION_CMAKE_VERSION_MAJOR@ >= 1.1 @PROJECT_PKGCONFIG_REQUIRES@ +Requires: gz-cmake@IGNITION_CMAKE_VERSION_MAJOR@ >= 1.1 @PROJECT_PKGCONFIG_REQUIRES@ Requires.private: @PROJECT_PKGCONFIG_REQUIRES_PRIVATE@ Libs: -L${libdir} @project_pkgconfig_core_lib@ @PROJECT_PKGCONFIG_LIBS@ Libs.private: @PROJECT_PKGCONFIG_LIBS_PRIVATE@ diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index de4d5e1b..33117584 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -31,36 +31,36 @@ endif() foreach(example ${example_directories}) set(run_codecheck false) if (${example} STREQUAL "ign_conf") - set(example_tarball_name ignition-minimal-0.1.0.tar.bz2) + set(example_tarball_name gz-minimal-0.1.0.tar.bz2) elseif (${example} STREQUAL "no_ignition_prefix") set(example_tarball_name no_ignition_prefix-0.1.0.tar.bz2) elseif (${example} STREQUAL "prerelease") - set(example_tarball_name ignition-minimal-1.0.0~pre1.tar.bz2) + set(example_tarball_name gz-minimal-1.0.0~pre1.tar.bz2) elseif (${example} STREQUAL "core_nodep") - set(example_tarball_name ignition-core_no_deps-0.1.0.tar.bz2) + set(example_tarball_name gz-core_no_deps-0.1.0.tar.bz2) set(run_codecheck true) elseif (${example} STREQUAL "core_nodep_static") - set(example_tarball_name ignition-core_no_deps_static-0.1.0.tar.bz2) + set(example_tarball_name gz-core_no_deps_static-0.1.0.tar.bz2) set(run_codecheck true) elseif (${example} STREQUAL "core_child") - set(example_tarball_name ignition-core_child-0.1.0.tar.bz2) + set(example_tarball_name gz-core_child-0.1.0.tar.bz2) set(run_codecheck true) elseif (${example} STREQUAL "core_child_private") - set(example_tarball_name ignition-core_child_private-0.1.0.tar.bz2) + set(example_tarball_name gz-core_child_private-0.1.0.tar.bz2) set(run_codecheck true) elseif (${example} STREQUAL "core_static_child") - set(example_tarball_name ignition-core_static_child-0.1.0.tar.bz2) + set(example_tarball_name gz-core_static_child-0.1.0.tar.bz2) set(run_codecheck true) elseif (${example} STREQUAL "comp_deps") - set(example_tarball_name ignition-component_deps-0.1.0.tar.bz2) + set(example_tarball_name gz-component_deps-0.1.0.tar.bz2) elseif (${example} STREQUAL "use_component_depsA") - set(example_tarball_name ignition-use_component_depsa-0.1.0.tar.bz2) + set(example_tarball_name gz-use_component_depsa-0.1.0.tar.bz2) elseif (${example} STREQUAL "use_component_depsB") - set(example_tarball_name ignition-use_component_depsb-0.1.0.tar.bz2) + set(example_tarball_name gz-use_component_depsb-0.1.0.tar.bz2) elseif (${example} STREQUAL "use_component_depsC") - set(example_tarball_name ignition-use_component_depsc-0.1.0.tar.bz2) + set(example_tarball_name gz-use_component_depsc-0.1.0.tar.bz2) elseif (${example} STREQUAL "use_config_ifp") - set(example_tarball_name ignition-find_config-0.1.0.tar.bz2) + set(example_tarball_name gz-find_config-0.1.0.tar.bz2) else() set(example_tarball_name) diff --git a/examples/comp_deps/CMakeLists.txt b/examples/comp_deps/CMakeLists.txt index 5668fb33..43f3fd69 100644 --- a/examples/comp_deps/CMakeLists.txt +++ b/examples/comp_deps/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-component_deps VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-component_deps VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() gz_configure_build(QUIT_IF_BUILD_ERRORS COMPONENTS child parent) diff --git a/examples/core_child/CMakeLists.txt b/examples/core_child/CMakeLists.txt index 354bf802..7ef23995 100644 --- a/examples/core_child/CMakeLists.txt +++ b/examples/core_child/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-core_child VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-core_child VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-core_no_deps REQUIRED) +gz_find_package(gz-core_no_deps REQUIRED) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() -gz_create_docs(TAGFILES "${IGNITION-CORE_NO_DEPS_DOXYGEN_TAGFILE} = ${IGNITION-CORE_NO_DEPS_API_URL}") +gz_create_docs(TAGFILES "${GZ-CORE_NO_DEPS_DOXYGEN_TAGFILE} = ${GZ-CORE_NO_DEPS_API_URL}") diff --git a/examples/core_child/src/CMakeLists.txt b/examples/core_child/src/CMakeLists.txt index 3ad5f65f..81c7417f 100644 --- a/examples/core_child/src/CMakeLists.txt +++ b/examples/core_child/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PUBLIC - ignition-core_no_deps::ignition-core_no_deps) + gz-core_no_deps::gz-core_no_deps) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/core_child_private/CMakeLists.txt b/examples/core_child_private/CMakeLists.txt index 0c8b0c81..f9c0a92c 100644 --- a/examples/core_child_private/CMakeLists.txt +++ b/examples/core_child_private/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-core_child_private VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-core_child_private VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-core_no_deps PRIVATE REQUIRED) +gz_find_package(gz-core_no_deps PRIVATE REQUIRED) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() -gz_create_docs(TAGFILES "${IGNITION-CORE_NO_DEPS_DOXYGEN_TAGFILE} = ${IGNITION-CORE_NO_DEPS_API_URL}") +gz_create_docs(TAGFILES "${GZ-CORE_NO_DEPS_DOXYGEN_TAGFILE} = ${GZ-CORE_NO_DEPS_API_URL}") diff --git a/examples/core_child_private/src/CMakeLists.txt b/examples/core_child_private/src/CMakeLists.txt index ba4b1db4..e5df4369 100644 --- a/examples/core_child_private/src/CMakeLists.txt +++ b/examples/core_child_private/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PRIVATE - ignition-core_no_deps::ignition-core_no_deps) + gz-core_no_deps::gz-core_no_deps) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/core_nodep/CMakeLists.txt b/examples/core_nodep/CMakeLists.txt index 25f00d7e..126f66cf 100644 --- a/examples/core_nodep/CMakeLists.txt +++ b/examples/core_nodep/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-core_no_deps VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-core_no_deps VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() diff --git a/examples/core_nodep_static/CMakeLists.txt b/examples/core_nodep_static/CMakeLists.txt index 75361f28..c2729ee0 100644 --- a/examples/core_nodep_static/CMakeLists.txt +++ b/examples/core_nodep_static/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-core_no_deps_static VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-core_no_deps_static VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() OPTION(BUILD_SHARED_LIBS OFF) gz_configure_build(QUIT_IF_BUILD_ERRORS) diff --git a/examples/core_static_child/CMakeLists.txt b/examples/core_static_child/CMakeLists.txt index 693290c6..811e9c53 100644 --- a/examples/core_static_child/CMakeLists.txt +++ b/examples/core_static_child/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-core_static_child VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-core_static_child VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-core_no_deps_static REQUIRED) +gz_find_package(gz-core_no_deps_static REQUIRED) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() -gz_create_docs(TAGFILES "${IGNITION-CORE_NO_DEPS_STATIC_DOXYGEN_TAGFILE} = ${IGNITION-CORE_NO_DEPS_STATIC_API_URL}") +gz_create_docs(TAGFILES "${GZ-CORE_NO_DEPS_STATIC_DOXYGEN_TAGFILE} = ${GZ-CORE_NO_DEPS_STATIC_API_URL}") diff --git a/examples/core_static_child/src/CMakeLists.txt b/examples/core_static_child/src/CMakeLists.txt index 66b64fa8..52753c67 100644 --- a/examples/core_static_child/src/CMakeLists.txt +++ b/examples/core_static_child/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PUBLIC - ignition-core_no_deps_static::ignition-core_no_deps_static) + gz-core_no_deps_static::gz-core_no_deps_static) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/find_ogre2/ogre-2.1/CMakeLists.txt b/examples/find_ogre2/ogre-2.1/CMakeLists.txt index 9a3e67b7..ee558652 100644 --- a/examples/find_ogre2/ogre-2.1/CMakeLists.txt +++ b/examples/find_ogre2/ogre-2.1/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) project(ignition-ogre-2.1 VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +find_package(gz-cmake3 REQUIRED) message(STATUS "Finding OGRE 2.1") diff --git a/examples/find_ogre2/ogre-2.2/CMakeLists.txt b/examples/find_ogre2/ogre-2.2/CMakeLists.txt index 69a4b39c..2c9ec409 100644 --- a/examples/find_ogre2/ogre-2.2/CMakeLists.txt +++ b/examples/find_ogre2/ogre-2.2/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-ogre-2.2 VERSION 0.1.0) +project(gz-ogre-2.2 VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +find_package(gz-cmake3 REQUIRED) message(STATUS "Finding OGRE 2.2") diff --git a/examples/ign_conf/CMakeLists.txt b/examples/ign_conf/CMakeLists.txt index 91530c0a..3d3c3d2c 100644 --- a/examples/ign_conf/CMakeLists.txt +++ b/examples/ign_conf/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-minimal0 VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-minimal0 VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() gz_configure_build(QUIT_IF_BUILD_ERRORS) diff --git a/examples/no_ignition_prefix/CMakeLists.txt b/examples/no_ignition_prefix/CMakeLists.txt index 5c71cfaf..42ca3489 100644 --- a/examples/no_ignition_prefix/CMakeLists.txt +++ b/examples/no_ignition_prefix/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) project(no_ignition_prefix VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +find_package(gz-cmake3 REQUIRED) gz_configure_project( NO_IGNITION_PREFIX REPLACE_IGNITION_INCLUDE_PATH no_ign) diff --git a/examples/prerelease/CMakeLists.txt b/examples/prerelease/CMakeLists.txt index f081646a..a1ebbb24 100644 --- a/examples/prerelease/CMakeLists.txt +++ b/examples/prerelease/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-minimal1 VERSION 1.0.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-minimal1 VERSION 1.0.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project(VERSION_SUFFIX pre1) gz_configure_build(QUIT_IF_BUILD_ERRORS) diff --git a/examples/sanitizers/CMakeLists.txt b/examples/sanitizers/CMakeLists.txt index f581e9b8..bf5741a7 100644 --- a/examples/sanitizers/CMakeLists.txt +++ b/examples/sanitizers/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-sanitizers VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-sanitizers VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() gz_configure_build(QUIT_IF_BUILD_ERRORS) diff --git a/examples/test_core_child_requires_core_no_deps.bash b/examples/test_core_child_requires_core_no_deps.bash index 9febf845..810dfcb1 100755 --- a/examples/test_core_child_requires_core_no_deps.bash +++ b/examples/test_core_child_requires_core_no_deps.bash @@ -2,40 +2,40 @@ TEST_STATUS=0 echo -echo Expect ignition-core_child to require ignition-core_no_deps -pkg-config ignition-core_child --print-requires -if ! pkg-config ignition-core_child --print-requires \ - | grep ignition-core_no_deps +echo Expect gz-core_child to require gz-core_no_deps +pkg-config gz-core_child --print-requires +if ! pkg-config gz-core_child --print-requires \ + | grep gz-core_no_deps then echo oops TEST_STATUS=1 fi echo -echo Expect ignition-core_child to not privately require ignition-core_no_deps -pkg-config ignition-core_child --print-requires-private -if pkg-config ignition-core_child --print-requires-private \ - | grep ignition-core_no_deps +echo Expect gz-core_child to not privately require gz-core_no_deps +pkg-config gz-core_child --print-requires-private +if pkg-config gz-core_child --print-requires-private \ + | grep gz-core_no_deps then echo oops TEST_STATUS=1 fi echo -echo Expect ignition-core_child_private to privately require ignition-core_no_deps -pkg-config ignition-core_child_private --print-requires-private -if ! pkg-config ignition-core_child_private --print-requires-private \ - | grep ignition-core_no_deps +echo Expect gz-core_child_private to privately require gz-core_no_deps +pkg-config gz-core_child_private --print-requires-private +if ! pkg-config gz-core_child_private --print-requires-private \ + | grep gz-core_no_deps then echo oops TEST_STATUS=1 fi echo -echo Expect ignition-core_child_private to not require ignition-core_no_deps -pkg-config ignition-core_child_private --print-requires -if pkg-config ignition-core_child_private --print-requires \ - | grep ignition-core_no_deps +echo Expect gz-core_child_private to not require gz-core_no_deps +pkg-config gz-core_child_private --print-requires +if pkg-config gz-core_child_private --print-requires \ + | grep gz-core_no_deps then echo oops TEST_STATUS=1 @@ -44,11 +44,11 @@ fi echo if [[ $TEST_STATUS -eq 0 ]] then - echo Successfully detected ignition-core_nodep requirements + echo Successfully detected gz-core_nodep requirements cp core_child_requires_core_nodep_pass.xml ../test_results/core_child_requires_core_nodep.xml exit 0 else - echo Could not detect all ignition-core_nodep requirements correctly + echo Could not detect all gz-core_nodep requirements correctly cp core_child_requires_core_nodep_fail.xml ../test_results/core_child_requires_core_nodep.xml exit 1 fi diff --git a/examples/use_component_depsA/CMakeLists.txt b/examples/use_component_depsA/CMakeLists.txt index 9ac3fc09..874f36b1 100644 --- a/examples/use_component_depsA/CMakeLists.txt +++ b/examples/use_component_depsA/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-use_component_depsA VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-use_component_depsA VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-component_deps REQUIRED COMPONENTS parent child) +gz_find_package(gz-component_deps REQUIRED COMPONENTS parent child) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() gz_create_docs() diff --git a/examples/use_component_depsA/src/CMakeLists.txt b/examples/use_component_depsA/src/CMakeLists.txt index a474aa52..97f2e22c 100644 --- a/examples/use_component_depsA/src/CMakeLists.txt +++ b/examples/use_component_depsA/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PUBLIC - ignition-component_deps::ignition-component_deps-child) + gz-component_deps::gz-component_deps-child) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/use_component_depsB/CMakeLists.txt b/examples/use_component_depsB/CMakeLists.txt index d9e3fdb8..d80427ca 100644 --- a/examples/use_component_depsB/CMakeLists.txt +++ b/examples/use_component_depsB/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-use_component_depsB VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-use_component_depsB VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-component_deps REQUIRED COMPONENTS child parent) +gz_find_package(gz-component_deps REQUIRED COMPONENTS child parent) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() gz_create_docs() diff --git a/examples/use_component_depsB/src/CMakeLists.txt b/examples/use_component_depsB/src/CMakeLists.txt index a474aa52..97f2e22c 100644 --- a/examples/use_component_depsB/src/CMakeLists.txt +++ b/examples/use_component_depsB/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PUBLIC - ignition-component_deps::ignition-component_deps-child) + gz-component_deps::gz-component_deps-child) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/use_component_depsC/CMakeLists.txt b/examples/use_component_depsC/CMakeLists.txt index 66cf25e5..72d7d7af 100644 --- a/examples/use_component_depsC/CMakeLists.txt +++ b/examples/use_component_depsC/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-use_component_depsC VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-use_component_depsC VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) gz_configure_project() -gz_find_package(ignition-component_deps REQUIRED COMPONENTS child) +gz_find_package(gz-component_deps REQUIRED COMPONENTS child) gz_configure_build(QUIT_IF_BUILD_ERRORS) gz_create_packages() gz_create_docs() diff --git a/examples/use_component_depsC/src/CMakeLists.txt b/examples/use_component_depsC/src/CMakeLists.txt index a474aa52..97f2e22c 100644 --- a/examples/use_component_depsC/src/CMakeLists.txt +++ b/examples/use_component_depsC/src/CMakeLists.txt @@ -2,5 +2,5 @@ gz_get_libsources_and_unittests(sources gtest_sources) gz_create_core_library(SOURCES ${sources} CXX_STANDARD 11) target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME} PUBLIC - ignition-component_deps::ignition-component_deps-child) + gz-component_deps::gz-component_deps-child) gz_build_tests(TYPE UNIT SOURCES ${gtest_sources}) diff --git a/examples/use_config_ifp/CMakeLists.txt b/examples/use_config_ifp/CMakeLists.txt index 30b982d4..faaa75d2 100644 --- a/examples/use_config_ifp/CMakeLists.txt +++ b/examples/use_config_ifp/CMakeLists.txt @@ -1,17 +1,17 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) -project(ignition-find_config VERSION 0.1.0) -find_package(ignition-cmake3 REQUIRED) +project(gz-find_config VERSION 0.1.0) +find_package(gz-cmake3 REQUIRED) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/") -set(ignition-find_config_DIR "${CMAKE_SOURCE_DIR}/") -#gz_find_package(ignition-find_config) will search for Findignition-find_config.cmake before ignition-find_configConfig.cmake -gz_find_package(ignition-find_config) +set(gz-find_config_DIR "${CMAKE_SOURCE_DIR}/") +#gz_find_package(gz-find_config) will search for Findgz-find_config.cmake before gz-find_configConfig.cmake +gz_find_package(gz-find_config) if(CONFIG_TEST MATCHES "The package was found using MODULE mode") message(STATUS "The package was found using MODULE mode") else() message(SEND_ERROR "Couldn't find correct package in MODULE mode.\ngz_find_package CONFIG test failed") endif() -#After CONFIG arguemnt gz_find_package will skip MODULE mode and search for ignition-find_configConfig.cmake directly -gz_find_package(ignition-find_config CONFIG) +#After CONFIG arguemnt gz_find_package will skip MODULE mode and search for gz-find_configConfig.cmake directly +gz_find_package(gz-find_config CONFIG) if(CONFIG_TEST MATCHES "The package was found using CONFIG mode") message(STATUS "The package was found using CONFIG mode") else() diff --git a/examples/use_config_ifp/Findignition-find_config.cmake b/examples/use_config_ifp/Findgz-find_config.cmake similarity index 100% rename from examples/use_config_ifp/Findignition-find_config.cmake rename to examples/use_config_ifp/Findgz-find_config.cmake diff --git a/examples/use_config_ifp/ignition-find_configConfig.cmake b/examples/use_config_ifp/gz-find_configConfig.cmake similarity index 100% rename from examples/use_config_ifp/ignition-find_configConfig.cmake rename to examples/use_config_ifp/gz-find_configConfig.cmake From 8e7bba629c45afcf4435b34c54c77046264dc573 Mon Sep 17 00:00:00 2001 From: Louise Poubel Date: Wed, 15 Jun 2022 11:57:50 -0700 Subject: [PATCH 2/4] Remove ignition- name support Signed-off-by: Louise Poubel --- cmake/IgnConfigureProject.cmake | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/cmake/IgnConfigureProject.cmake b/cmake/IgnConfigureProject.cmake index 58a8f1ea..1c06e7d3 100644 --- a/cmake/IgnConfigureProject.cmake +++ b/cmake/IgnConfigureProject.cmake @@ -71,14 +71,8 @@ macro(gz_configure_project) # Extract the designation #============================================================================ set(IGN_DESIGNATION ${PROJECT_NAME}) - # Remove the leading project prefix ("gz-" by default) - set(PROJECT_PREFIX "gz") - # Also support "ignition-" - # TODO: remove this `if` block once all package names start with gz - if(${IGN_DESIGNATION} MATCHES "^ignition-") - set(PROJECT_PREFIX "ignition") - endif() - string(REGEX REPLACE "${PROJECT_PREFIX}-" "" IGN_DESIGNATION ${IGN_DESIGNATION}) + # Remove the leading project prefix (assume "gz-") + string(REGEX REPLACE "gz-" "" IGN_DESIGNATION ${IGN_DESIGNATION}) # Remove the trailing version number string(REGEX REPLACE "[0-9]+" "" IGN_DESIGNATION ${IGN_DESIGNATION}) From 9efff55617cd729bc4d85f530e43bef15eeac18b Mon Sep 17 00:00:00 2001 From: Louise Poubel Date: Thu, 16 Jun 2022 10:30:09 -0700 Subject: [PATCH 3/4] revert ignition prefix Signed-off-by: Louise Poubel --- cmake/IgnConfigureProject.cmake | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/cmake/IgnConfigureProject.cmake b/cmake/IgnConfigureProject.cmake index 1c06e7d3..58a8f1ea 100644 --- a/cmake/IgnConfigureProject.cmake +++ b/cmake/IgnConfigureProject.cmake @@ -71,8 +71,14 @@ macro(gz_configure_project) # Extract the designation #============================================================================ set(IGN_DESIGNATION ${PROJECT_NAME}) - # Remove the leading project prefix (assume "gz-") - string(REGEX REPLACE "gz-" "" IGN_DESIGNATION ${IGN_DESIGNATION}) + # Remove the leading project prefix ("gz-" by default) + set(PROJECT_PREFIX "gz") + # Also support "ignition-" + # TODO: remove this `if` block once all package names start with gz + if(${IGN_DESIGNATION} MATCHES "^ignition-") + set(PROJECT_PREFIX "ignition") + endif() + string(REGEX REPLACE "${PROJECT_PREFIX}-" "" IGN_DESIGNATION ${IGN_DESIGNATION}) # Remove the trailing version number string(REGEX REPLACE "[0-9]+" "" IGN_DESIGNATION ${IGN_DESIGNATION}) From fde686f0eee302a6e9b58062c7419f37c185f898 Mon Sep 17 00:00:00 2001 From: methylDragon Date: Mon, 20 Jun 2022 18:40:45 -0700 Subject: [PATCH 4/4] Update ign- in warning to gz- Signed-off-by: methylDragon --- cmake/IgnUtils.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/IgnUtils.cmake b/cmake/IgnUtils.cmake index 26c143c2..033c1194 100644 --- a/cmake/IgnUtils.cmake +++ b/cmake/IgnUtils.cmake @@ -1932,7 +1932,7 @@ macro(_gz_cmake_parse_arguments prefix options oneValueArgs multiValueArgs) message(AUTHOR_WARNING "\nThe build script has specified some unrecognized arguments for ${prefix}(~):\n" "${${prefix}_UNPARSED_ARGUMENTS}\n" - "Either the script has a typo, or it is using an unexpected version of ign-cmake. " + "Either the script has a typo, or it is using an unexpected version of gz-cmake. " "The version of gz-cmake currently being used is ${gz-cmake${IGNITION_CMAKE_VERSION_MAJOR}_VERSION}\n") endif()