cmaize.project/impl_/add_target

cmaize.project/impl_/add_target._add_target(self __at_target **kwargs)

Add a target to the project. Duplicate objects will not be added.

This internal implementation exists so a required keyword argument is not part of the public interface, as well as to handle both desc and target types. Both types are effectively strings representing target names in this algorithm and can be treated equivalently, but cannot be typecast to each other by CMakePPLang. The CMakePPLang type checking is bypassed through the aforementioned required keyword argument for the target name, essentially combining the two types.

Parameters:
  • __at_target (CMaizeTarget) – CMaizeTarget object to be added.

  • NAME (desc or target) – Required keyword argument. See description below.

  • **kwargs

    Additional keyword arguments may be necessary.

Keyword Arguments:
  • INSTALLED (bool) – Flag to indicate that the target being added is already installed on the system.

  • NAME (desc or target) – Identifying name for the target. This can match name of either the CMake target or CMaizeTarget object, but is required to do match them. This keyword argument is required.