7 # Bridge an old, deprecated, setting to a new replacement setting. 9 # Use this function when a user-visible flag is being renamed or otherwise 10 # replaced. If the old value is set, it will be given as the default value, 11 # otherwise the given default value will be used. This returned value should 12 # then be used in the ``set(CACHE)`` or ``option()`` call for the new value. 14 # If the old value is set, it will warn that it is deprecated for the new name. 16 # If replacing the setting ``OLD_SETTING`` with ``NEW_SETTING``, its usage 19 # vtk_deprecated_setting(default_setting NEW_SETTING OLD_SETTING "default value") 20 # set(NEW_SETTING "${default_setting}" 21 # CACHE STRING "Documentation for the setting.") 23 set(
default "${intended_default}")
25 message(WARNING
"The '${old}' variable is deprecated for '${new}'.")
26 set(
default "${${old}}")
29 set(
"${output_default}" "${default}" PARENT_SCOPE)
32 # Remove an old / obsolete setting 34 # Use this function when a user-visible flag is being removed entirely. If the 35 # old value is set, it will be cause a warning message letting the user know 36 # that the setting has no effect. 39 message(WARNING
"The '${old}' variable is obsolete and no longer has any effect.")
function vtk_deprecated_setting(output_default, new, old, intended_default)
function vtk_obsolete_setting(old)
macro paraview_set_with_default(var, value)