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

ign -> gz Partial Docs Migration and Project Name Followups : gz-cmake #267

Merged
merged 5 commits into from
Jun 28, 2022
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ option(BUILDSYSTEM_TESTING "Enable extended buildsystem testing" FALSE)

#--------------------------------------
# Install the ignition documentation files
# Note: This is not actually creating a doc target for ign-cmake; this is just
# Note: This is not actually creating a doc target for gz-cmake; this is just
# installing files that are useful for generating the documentation of other
# ignition projects.
add_subdirectory(doc)
Expand Down Expand Up @@ -106,7 +106,7 @@ install(
#============================================================================
# Create and install the utilities component
#============================================================================
# Deprecated: Remove the utilities component in ign-cmake4
# Deprecated: Remove the utilities component in gz-cmake4
add_library(${ign_utilities_target} INTERFACE)
target_include_directories(${ign_utilities_target}
INTERFACE
Expand Down Expand Up @@ -169,7 +169,7 @@ if (BUILD_TESTING AND BUILDSYSTEM_TESTING)
#============================================================================
# Build examples
#============================================================================
# Do a fake install of ign-cmake in order to test the examples.
# Do a fake install of gz-cmake in order to test the examples.
# Copy or symlink the config.cmake files and cmake folder
set(FAKE_BUILD_DIRECTORY "${CMAKE_BINARY_DIR}/fake/build")
set(FAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/fake/install")
Expand Down
7 changes: 3 additions & 4 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
1. User-friendly skip component warning
* [Pull request #165](https://github.com/gazebosim/gz-cmake/pull/165)

1. Run ign-cmake's copy of check_test_ran
1. Run gz-cmake's copy of check_test_ran
* [Pull request #168](https://github.com/gazebosim/gz-cmake/pull/168)

### Gazebo CMake 2.7.0 (2021-03-30)
Expand Down Expand Up @@ -157,10 +157,10 @@
1. Remove deprecated doxygen configurations
* [Pull request 136](https://github.com/gazebosim/gz-cmake/pull/136)

1. Generate doxygen tutorials for ign-cmake
1. Generate doxygen tutorials for gz-cmake
* [Pull request 137](https://github.com/gazebosim/gz-cmake/pull/137)

1. Enable make codecheck for ign-cmake
1. Enable make codecheck for gz-cmake
* [Pull request 138](https://github.com/gazebosim/gz-cmake/pull/138)

1. Generate valid visibility macros by replacing hyphens in component name
Expand Down Expand Up @@ -387,4 +387,3 @@
* [Full list of changes](https://github.com/gazebosim/gz-cmake/compare/ignition-cmake_0.4.1...ignition-cmake_0.4.0)

### Gazebo CMake 0.4.0

15 changes: 11 additions & 4 deletions Migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,17 @@ release will remove the deprecated code.
## Gazebo CMake 2.X to 3.X

1. **Deprecated**: include/ignition/utilities/SuppressWarning.hh
**Replacement**: include/ignition/utils/SuppressWarning.hh
**Replacement**: include/ignition/utils/SuppressWarning.hh
1. **Deprecated**: include/ignition/utilities/ExtraTestMacros.hh
**Replacement**: include/ignition/utils/ExtraTestMacros.hh
**Replacement**: include/ignition/utils/ExtraTestMacros.hh
1. **Deprecated**: CMake functions and macros starting with `ign_`
**Replacement**: CMake functions and macros starting with `gz_`
**Replacement**: CMake functions and macros starting with `gz_`
1. **Deprecated**: `ignition` namespaces
**Replacement**: `gz` namespaces
**Replacement**: `gz` namespaces

1. **Breaking**: The project name has been changed to use the `gz-` prefix, you **must** use the `gz` prefix!
* This also means that any generated code that use the project name (e.g. CMake variables, in-source macros) would have to be migrated.
* Some non-exhaustive examples of this include:
* `GZ_<PROJECT>_<VISIBLE/HIDDEN>`
* CMake `-config` files
* Paths that depend on the project name
94 changes: 47 additions & 47 deletions MigrationFromClassic.md

Large diffs are not rendered by default.

22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ Windows | [![Build Status](https://build.osrfoundation.org/buildStatus/ico

# Features

ignition-cmake provides a set of cmake modules that are used by the C++-based ignition projects. These modules help to control the quality and consistency of the ignition projects' build systems.
gz-cmake provides a set of cmake modules that are used by the C++-based Gazebo projects. These modules help to control the quality and consistency of the Gazebo projects' build systems.

These modules are tailored to the ignition projects, so their use for non-ignition projects might be limited, but they may serve as a useful reference for setting up a modern cmake build system using good practices.
These modules are tailored to the Gazebo projects, so their use for non-Gazebo projects might be limited, but they may serve as a useful reference for setting up a modern cmake build system using good practices.

# Install

Expand All @@ -57,7 +57,7 @@ The [Source Install](#source-install) instructions should be used if you need th

## Binary Install

On Ubuntu systems, `apt-get` can be used to install `ignition-cmake`:
On Ubuntu systems, `apt-get` can be used to install `gz-cmake`:

```
$ sudo apt install libignition-cmake<#>-dev
Expand All @@ -69,7 +69,7 @@ Be sure to replace `<#>` with a number value, such as `1` or `2`, depending on w

### Prerequisites

The only prerequisite of `ignition-cmake` is `cmake`. Ubuntu users can install cmake with the package manager:
The only prerequisite of `gz-cmake` is `cmake`. Ubuntu users can install cmake with the package manager:

```
$ sudo apt install cmake
Expand All @@ -81,7 +81,7 @@ To build and install from source, you can clone the repo and use cmake to instal

```
$ git clone https://github.com/gazebosim/gz-cmake
$ cd ign-cmake
$ cd gz-cmake
$ mkdir build
$ cd build
$ cmake .. -DCMAKE_INSTALL_PREFIX=/path/to/install/dir
Expand All @@ -99,7 +99,7 @@ Documentation can be accessed at https://gazebosim.org/libs/cmake

# Documentation

Documentation for `ignition-cmake` can be found within the source code, and also in the [MIGRATION.md guide](https://github.com/gazebosim/gz-cmake/blob/master/MIGRATION.md).
Documentation for `gz-cmake` can be found within the source code, and also in the [MIGRATION.md guide](https://github.com/gazebosim/gz-cmake/blob/master/MIGRATION.md).

# Testing

Expand All @@ -115,11 +115,11 @@ $ make test

* `cmake`: cmake modules that get installed by this package
* `codecheck`: code linting and static analyzing utilities that get installed by this package
* `config`: template files for producing the config-files of `ignition-cmake`; these are only used internally
* `doc`: template files to help ignition projects generate their own documentation
* `examples`: fake projects that are used to test `ignition-cmake`
* `include`: C++ utility header files that get installed with `ignition-cmake`
* `test`: a directory of tests for the C++ utility component of `ignition-cmake`
* `config`: template files for producing the config-files of `gz-cmake`; these are only used internally
* `doc`: template files to help Gazebo projects generate their own documentation
* `examples`: fake projects that are used to test `gz-cmake`
* `include`: C++ utility header files that get installed with `gz-cmake`
* `test`: a directory of tests for the C++ utility component of `gz-cmake`
* `tools`: scripts for continuous integration testing

# Contributing
Expand Down
4 changes: 2 additions & 2 deletions api.md.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## Ignition @IGN_DESIGNATION_CAP@
## Gazebo @IGN_DESIGNATION_CAP@

Ignition @IGN_DESIGNATION_CAP@ is a component in Ignition, a set of libraries
Gazebo @IGN_DESIGNATION_CAP@ is a component in Gazebo, a set of libraries
designed to rapidly develop robot and simulation applications.

## License
Expand Down
2 changes: 1 addition & 1 deletion cmake/Export.hh.in
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
/*
* ==========================================================================
* This file was automatically generated by CMake; do not modify it directly.
* To modify this file, make changes to ign-cmake/cmake/Export.hh.in
* To modify this file, make changes to gz-cmake/cmake/Export.hh.in
* ==========================================================================
*/

Expand Down
2 changes: 1 addition & 1 deletion cmake/IgnConfigureBuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# gz_configure_build()
#
# Configures the build rules of an ignition library project.
# Configures the build rules of a Gazebo library project.
#
#===============================================================================
# Copyright (C) 2017 Open Source Robotics Foundation
Expand Down
2 changes: 1 addition & 1 deletion cmake/IgnConfigureProject.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# gz_configure_project([VERSION_SUFFIX <pre|alpha|beta|etc>])
#
# Sets up an ignition library project.
# Sets up a Gazebo library project.
#
# NO_IGNITION_PREFIX: Optional. Don't use ignition as prefix in
# cmake project name.
Expand Down
2 changes: 1 addition & 1 deletion cmake/IgnCreateDocs.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# gz_create_docs
#
# Creates documentation for an ignition library project.
# Creates documentation for a Gazebo library project.
#
#===============================================================================
# Copyright (C) 2017 Open Source Robotics Foundation
Expand Down
6 changes: 3 additions & 3 deletions cmake/IgnPackaging.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
#
# _gz_setup_packages
#
# Sets up package information for an ignition library project.
# Sets up package information for a Gazebo library project.
# This function is internal to gz-cmake.
#
# gz_create_packages
#
# Creates a package for an ignition library project
# Creates a package for a Gazebo library project
#
#===============================================================================
# Copyright (C) 2017 Open Source Robotics Foundation
Expand Down Expand Up @@ -342,7 +342,7 @@ function(_gz_create_cmake_package)
FILE ${gz_target_ouput}
# We add a namespace that ends with a :: to the name of the exported target.
# This is so consumers of the project can call
# find_package(ignition-<project>)
# find_package(gz-<project>)
# target_link_libraries(consumer_project ignition-<project>::ignition-<project>)
# and cmake will understand that the consumer is asking to link the imported
# target "ignition-<project>" to their "consumer_project" rather than asking
Expand Down
2 changes: 1 addition & 1 deletion cmake/IgnPython.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ else()
endif()

# Tick-tock PYTHON_EXECUTABLE until Python3_EXECUTABLE is released
# TODO(jrivero) ign-cmake3: start the deprecation cycle of PYTHON_EXECUTABLE
# TODO(jrivero) gz-cmake3: start the deprecation cycle of PYTHON_EXECUTABLE
if(Python3_EXECUTABLE AND NOT PYTHON_EXECUTABLE)
set(PYTHON_EXECUTABLE ${Python3_EXECUTABLE})
endif()
2 changes: 1 addition & 1 deletion cmake/IgnSetCompilerFlags.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# _gz_set_compiler_flags()
#
# Sets up compiler flags for an ignition library project
# Sets up compiler flags for a Gazebo library project
#
#===============================================================================
# Copyright (C) 2017 Open Source Robotics Foundation
Expand Down
16 changes: 8 additions & 8 deletions cmake/IgnUtils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@
# 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
# gz_find_package(~). These arguments can also be used to overwrite the
# pkg-config entries that get generated by the ign-cmake find-module for the
# pkg-config entries that get generated by the gz-cmake find-module for the
# package. Do not hesitate to ask for help if you need to use these arguments.
#
# [PKGCONFIG]: Optional. If provided, the string that follows will be used to
Expand Down Expand Up @@ -358,14 +358,14 @@ macro(gz_find_package PACKAGE_NAME)
if(NOT gz_find_package_PKGCONFIG_IGNORE)

# Here we will set up the pkgconfig entry for this package. Ordinarily,
# these variables should be set by the ign-cmake custom find-module for
# these variables should be set by the gz-cmake custom find-module for
# the package which should use gz_pkg_check_modules[_quiet] or
# gz_pkg_config_library_entry. However, that will not be performed by
# third-party dependencies that provide their own find-module or their own
# cmake config-module. Therefore, we provide the option of specifying
# pkgconfig information through the call to gz_find_package. This also
# allows callers of gz_find_package(~) to overwrite the default
# pkg-config entry that gets generated by the ign-cmake find-modules.
# pkg-config entry that gets generated by the gz-cmake find-modules.

# If the caller has specified the arguments PKGCONFIG_LIB or PKGCONFIG,
# then we will overwrite these pkgconfig variables with the information
Expand Down Expand Up @@ -416,7 +416,7 @@ macro(gz_find_package PACKAGE_NAME)
"Could not find pkg-config information for ${PACKAGE_NAME}. "
"It was not provided by the find-module for the package, nor was it "
"explicitly passed into the call to gz_find_package(~). This is "
"most likely an error in this project's use of ign-cmake.")
"most likely an error in this project's use of gz-cmake.")

else()

Expand Down Expand Up @@ -884,7 +884,7 @@ endmacro(gz_build_warning)
# Creates a fatal error if the variable passed in does not represent a supported
# version of the C++ standard.
#
# NOTE: This function is meant for internal ign-cmake use
# NOTE: This function is meant for internal gz-cmake use
#
function(_gz_check_known_cxx_standards standard)

Expand All @@ -905,7 +905,7 @@ endfunction()
# Handles the C++ standard argument for gz_create_core_library(~) and
# gz_add_component(~).
#
# NOTE: This is only meant for internal ign-cmake use.
# NOTE: This is only meant for internal gz-cmake use.
#
macro(_gz_handle_cxx_standard prefix target pkgconfig_cflags)

Expand Down Expand Up @@ -1917,7 +1917,7 @@ endmacro()
# Set <prefix> to match the prefix that is given to cmake_parse_arguments(~).
# This should also match the name of the function or macro that called it.
#
# NOTE: This should only be used by functions inside of ign-cmake specifically.
# NOTE: This should only be used by functions inside of gz-cmake specifically.
# Other ignition projects should not use this macro.
#
macro(_gz_cmake_parse_arguments prefix options oneValueArgs multiValueArgs)
Expand All @@ -1928,7 +1928,7 @@ macro(_gz_cmake_parse_arguments prefix options oneValueArgs multiValueArgs)

# The user passed in some arguments that we don't currently recognize. We'll
# emit a warning so they can check whether they're using the correct version
# of ign-cmake.
# of gz-cmake.
message(AUTHOR_WARNING
"\nThe build script has specified some unrecognized arguments for ${prefix}(~):\n"
"${${prefix}_UNPARSED_ARGUMENTS}\n"
Expand Down
2 changes: 1 addition & 1 deletion cmake/pkgconfig/ignition-component.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ prefix=${pcfiledir}/@PC_CONFIG_RELATIVE_PATH_TO_PREFIX@
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@IGN_INCLUDE_INSTALL_DIR_POSTFIX@

Name: Ignition @IGN_DESIGNATION@ @component_name@
Name: Gazebo @IGN_DESIGNATION@ @component_name@
Description: A set of @IGN_DESIGNATION@ @component_name@ classes for robot applications
Version: @PROJECT_VERSION_FULL_NO_SUFFIX@
Requires: @component_pkgconfig_requires@
Expand Down
2 changes: 1 addition & 1 deletion cmake/pkgconfig/ignition.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ prefix=${pcfiledir}/@PC_CONFIG_RELATIVE_PATH_TO_PREFIX@
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@IGN_INCLUDE_INSTALL_DIR_POSTFIX@

Name: Ignition @IGN_DESIGNATION@
Name: Gazebo @IGN_DESIGNATION@
Description: A set of @IGN_DESIGNATION@ classes for robot applications
Version: @PROJECT_VERSION_FULL_NO_SUFFIX@
Requires: gz-cmake@IGNITION_CMAKE_VERSION_MAJOR@ >= 1.1 @PROJECT_PKGCONFIG_REQUIRES@
Expand Down
18 changes: 9 additions & 9 deletions config/ignition-cmake-config.cmake.in
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# - Config file for ignition-cmake (not for any other ignition libraries).
# - Config file for gz-cmake (not for any other Gazebo libraries).
#
# To find and load ignition-cmake modules into your project, simply invoke:
# To find and load gz-cmake modules into your project, simply invoke:
#
# find_package(@PKG_NAME@)
#
# That will define the variable @PKG_NAME@_FOUND, and will open up access
# to all the cmake-modules and find-modules that are provided by ignition-cmake.
# to all the cmake-modules and find-modules that are provided by gz-cmake.

# We explicitly set the desired cmake version to ensure that the policy settings
# of users or of toolchains do not result in the wrong behavior for our modules.
Expand Down Expand Up @@ -33,19 +33,19 @@ if(NOT TARGET @ign_utilities_import_target_name@)
endif()

# We should only perform these operations if either
# 1. ign-cmake has not been included yet, or
# 2. we need a higher version of ign-cmake than the last one that was included
# 1. gz-cmake has not been included yet, or
# 2. we need a higher version of gz-cmake than the last one that was included
#
# The only time we should need to switch to a higher version of ign-cmake is
# The only time we should need to switch to a higher version of gz-cmake is
# when importing targets for dependencies, i.e. using the find-modules of
# ign-cmake. All find-modules that are available in older versions of ign-cmake
# should be available in newer versions of ign-cmake, so this should not create
# gz-cmake. All find-modules that are available in older versions of gz-cmake
# should be available in newer versions of gz-cmake, so this should not create
# any conflicts.
if( NOT IGNITION_CMAKE_VERSION_MAJOR
OR (IGNITION_CMAKE_VERSION_MAJOR LESS @PROJECT_VERSION_MAJOR@) )

#--------------------------------------
# Create a variable to indicate what version of ignition-cmake we are using.
# Create a variable to indicate what version of gz-cmake we are using.
# This variable does not follow the usual cmake naming convention because it
# is a non-standard package variable.
set(IGNITION_CMAKE_VERSION_MAJOR @PROJECT_VERSION_MAJOR@)
Expand Down
4 changes: 2 additions & 2 deletions config/ignition-cmake.pc.in
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
prefix=${pcfiledir}/@IGN_PC_CONFIG_RELATIVE_PATH_TO_PREFIX@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@IGN_INCLUDE_INSTALL_DIR_POSTFIX@

Name: Ignition @IGN_DESIGNATION@
Description: Build system package for the ignition libraries
Name: Gazebo @IGN_DESIGNATION@
Description: Build system package for the Gazebo libraries
Version: @PROJECT_VERSION_FULL_NO_SUFFIX@
Requires:
Requires.private:
Expand Down
2 changes: 1 addition & 1 deletion configure.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
:: NOTE: This script is only meant to be used as part of the ignition developers' CI system
:: Users and developers should build and install this library using cmake and Visual Studio

:: ign-cmake has no dependencies
:: gz-cmake has no dependencies

:: Go to the directory that this file configure.bat file exists in
cd /d %~dp0
Expand Down
2 changes: 1 addition & 1 deletion examples/find_ogre2/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
A quick demonstration of searching for Ogre 2.1 vs 2.2 via ign-cmake.
A quick demonstration of searching for Ogre 2.1 vs 2.2 via gz-cmake.

To test with both versions installed:

Expand Down
2 changes: 1 addition & 1 deletion include/ignition/utilities/ExtraTestMacros.hh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

#include <ignition/utilities/detail/ExtraTestMacros.hh>

#pragma message("ign-cmake (utilities) ExtraTestMacros is deprecated, use ign-utils")
#pragma message("gz-cmake (utilities) ExtraTestMacros is deprecated, use gz-utils")

/// \brief Restrict the execution of the test for the Windows platform.
/// The test will be compiled on Windows too but will never be run as
Expand Down
Loading