CMake Library

Overview

These are modules which can be included by cmake in the regular way with a macro/function api to call upon (think regular c-style library).

One nice feature of this is that you don't waste time processing macros you don't use (unlike a usual cmake module).

Usage

RoS

If using the ecl to build an ros package:

# Include the macro libraries you wish to use...e.g.
rosbuild_include(ecl_build ecl_build_utilities)
rosbuild_include(ecl_build ecl_platform_detection)
rosbuild_include(ecl_build ecl_ros_utilities)
# Call the macros
ecl_detect_platform() # a general purpose platform sniffer
ecl_ros_get_dependency_list() # get the dependency list for this project
# Finally use some of the variables it sets (this one the dependency
message(STATUS "Dependencies: ${${PROJECT_NAME}_DEPENDENCIES}")

System

Pkg-config can be used to find the macro libraries when you have a regular system install of the ecl. An example:

find_package(PkgConfig)
pkg_check_modules(ECL_CMAKE ecl_cmake) # Stores the path to the ecl cmake dir in ECL_CMAKE_PREFIX
set(CMAKE_MODULE_PATH ${ECL_CMAKE_PREFIX}/modules) # Location of the ecl cmake modules
# Include the macro libraries you wish to use...e.g.
include(ecl_build_utilities)
include(ecl_platform_detection)
include(ecl_ros_utilities)
# Call the macros
ecl_detect_platform() # a general purpose platform sniffer

The Library

See the sources (.cmake files) for more detailed usage notes and examples.

Platform Detection

File: ecl_platform_detection.cmake

Build Utilities

File: ecl_build_utilities.cmake

Ros Utilities

File: ecl_ros_utilities.cmake



ecl_build
Author(s): Daniel Stonier
autogenerated on Mon Feb 28 2022 22:18:56