# Copyright 2022, Collabora, Ltd. # Copyright 2000-2022, Kitware, Inc., Insight Software Consortium # # SPDX-License-Identifier: BSD-3-Clause # # CMake was initially developed by Kitware with the following sponsorship: # * National Library of Medicine at the National Institutes of Health # as part of the Insight Segmentation and Registration Toolkit (ITK). # # * US National Labs (Los Alamos, Livermore, Sandia) ASC Parallel # Visualization Initiative. # # * National Alliance for Medical Image Computing (NAMIC) is funded by the # National Institutes of Health through the NIH Roadmap for Medical Research, # Grant U54 EB005149. # # * Kitware, Inc. # # (Based on CMakeDependentOption) #[=======================================================================[.rst: OptionWithDeps -------------- Macro to provide an option dependent on other options. This macro presents an option to the user only if a set of other conditions are true. If it is already specified by the user but the conditions are not true, it triggers an error. This is based on cmake_dependent_options but meets common expectations better: if you explicitly try to enable something that is not available, you get an error instead of having it silently disabled. .. command:: option_with_deps .. code-block:: cmake option_with_deps(