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

GzConfigureProject: improve documentation #364

Merged
merged 2 commits into from
Jul 10, 2023
Merged
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
34 changes: 32 additions & 2 deletions cmake/GzConfigureProject.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,47 @@
# GzConfigureProject
# -------------------
#
# gz_configure_project([VERSION_SUFFIX <pre|alpha|beta|etc>])
# gz_configure_project([NO_PROJECT_PREFIX]
# [REPLACE_INCLUDE_PATH <new_include_path>]
# [CONFIG_EXTRAS <extra_config_files>]
# [VERSION_SUFFIX <pre|alpha|beta|etc>])
#
# Sets up a Gazebo library project.
#
# CONFIG_EXTRAS: Optional. If provided, the list that follows should indicate
# extra cmake template files that will be configured and installed to the
# same folder as the cmake configuration files for the core library target.
# NO_PROJECT_PREFIX: Optional. Don't use gz- as prefix in
# cmake project name.
# REPLACE_INCLUDE_PATH: Optional. Specify include folder
# names to replace the default value of
# gz/${GZ_DESIGNATION}
# VERSION_SUFFIX: Optional. Specify a prerelease version suffix.
#
# The following variables are automatically defined by project(~) in cmake 3:
# PROJECT_NAME
# PROJECT_VERSION_MAJOR
# PROJECT_VERSION_MINOR
# PROJECT_VERSION_PATCH
#
# This macro defines the following variables as well:
# GZ_DESIGNATION
# GZ_DESIGNATION_LOWER
# GZ_DESIGNATION_UPPER
# PKG_NAME
# PROJECT_CMAKE_EXTRAS_INSTALL_DIR
# PROJECT_CMAKE_EXTRAS_PATH_TO_PREFIX
# PROJECT_INCLUDE_DIR
# PROJECT_NAME_NO_VERSION
# PROJECT_NAME_NO_VERSION_LOWER
# PROJECT_NAME_NO_VERSION_UPPER
# PROJECT_NAME_LOWER
# PROJECT_NAME_UPPER
# PROJECT_VERSION
# PROJECT_VERSION_FULL
# PROJECT_VERSION_FULL_NO_SUFFIX
# PROJECT_VERSION_SUFFIX
#
#===============================================================================
# Copyright (C) 2017 Open Source Robotics Foundation
#
Expand All @@ -35,7 +65,7 @@ macro(ign_configure_project)

set(options NO_PROJECT_PREFIX NO_IGNITION_PREFIX) # TODO(CH3): NO_IGNITION_PREFIX IS DEPRECATED.
set(oneValueArgs REPLACE_INCLUDE_PATH REPLACE_IGNITION_INCLUDE_PATH VERSION_SUFFIX) # TODO(CH3): REPLACE_IGNITION_INCLUDE_PATH IS DEPRECATED.
set(multiValueArgs) # We are not using multiValueArgs yet
set(multiValueArgs CONFIG_EXTRAS)
_gz_cmake_parse_arguments(gz_configure_project "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})

set(gz_configure_project_skip_parsing true)
Expand Down