From 4841d38a7a9c48cff7e4edeb900005c04e64398a Mon Sep 17 00:00:00 2001 From: Brad King Date: Mon, 8 Feb 2021 12:33:02 -0500 Subject: MacroAddFileDependencies: Explicitly deprecate by documentation This module has been discouraged since commit 1e20be319f (STYLE: add documentation for MACRO_ADD_FILE_DEPENDENCIES(), 2009-07-14, v2.8.0~433). It has been listed in the `cmake-modules(7)` manual as deprecated since commit df780bcc01 (Help: Move deprecated modules to appropriate section., 2018-11-12, v3.14.0-rc1~374^2). Add the explicit deprecation mark in its documentation. --- Modules/MacroAddFileDependencies.cmake | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/Modules/MacroAddFileDependencies.cmake b/Modules/MacroAddFileDependencies.cmake index c4374ee..8fdc264 100644 --- a/Modules/MacroAddFileDependencies.cmake +++ b/Modules/MacroAddFileDependencies.cmake @@ -5,15 +5,21 @@ MacroAddFileDependencies ------------------------ -MACRO_ADD_FILE_DEPENDENCIES(<_file> depend_files...) +.. deprecated:: 3.14 -Using the macro MACRO_ADD_FILE_DEPENDENCIES() is discouraged. There -are usually better ways to specify the correct dependencies. +:: + + MACRO_ADD_FILE_DEPENDENCIES( ...) + +Do not use this command in new code. It is just a wrapper around: + +.. code-block:: cmake + + set_property(SOURCE APPEND PROPERTY OBJECT_DEPENDS ...) + +Instead use the :command:`set_property` command to append to the +:prop_sf:`OBJECT_DEPENDS` source file property directly. -MACRO_ADD_FILE_DEPENDENCIES(<_file> depend_files...) is just a -convenience wrapper around the OBJECT_DEPENDS source file property. -You can just use set_property(SOURCE APPEND PROPERTY -OBJECT_DEPENDS depend_files) instead. #]=======================================================================] macro (MACRO_ADD_FILE_DEPENDENCIES _file) -- cgit v0.12