diff options
author | Kyle Edwards <kyle.edwards@kitware.com> | 2018-09-12 17:33:04 (GMT) |
---|---|---|
committer | Kyle Edwards <kyle.edwards@kitware.com> | 2018-09-19 15:23:08 (GMT) |
commit | eedd91ab085d551d7953f8bb6fe01fd5540af004 (patch) | |
tree | 06c48354c007001780a079d2a6b86fd7bdd822bc /Help/policy | |
parent | fd28ea35ca5f62e52d030288bf60ca6fe769cb96 (diff) | |
download | CMake-eedd91ab085d551d7953f8bb6fe01fd5540af004.zip CMake-eedd91ab085d551d7953f8bb6fe01fd5540af004.tar.gz CMake-eedd91ab085d551d7953f8bb6fe01fd5540af004.tar.bz2 |
BundleUtilities: Disallow inclusion at configure time
This commit adds a new CMake policy, CMP0080, which prohibits the
inclusion of BundleUtilities at configure time. The old behavior is
to allow the inclusion.
Diffstat (limited to 'Help/policy')
-rw-r--r-- | Help/policy/CMP0080.rst | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/Help/policy/CMP0080.rst b/Help/policy/CMP0080.rst new file mode 100644 index 0000000..5ce9591 --- /dev/null +++ b/Help/policy/CMP0080.rst @@ -0,0 +1,25 @@ +CMP0080 +------- + +:module:`BundleUtilities` cannot be included at configure time. + +The macros provided by :module:`BundleUtilities` are intended to be invoked +at install time rather than at configure time, because they depend on the +listed targets already existing at the time they are invoked. If they are +invoked at configure time, the targets haven't been built yet, and the +commands will fail. + +This policy restricts the inclusion of :module:`BundleUtilities` to +``cmake -P`` style scripts and install rules. Specifically, it looks for the +presence of :variable:`CMAKE_GENERATOR` and throws a fatal error if it exists. + +The ``OLD`` behavior of this policy is to allow :module:`BundleUtilities` to +be included at configure time. The ``NEW`` behavior of this policy is to +disallow such inclusion. + +This policy was introduced in CMake version 3.13. CMake version +|release| warns when the policy is not set and uses ``OLD`` behavior. +Use the :command:`cmake_policy` command to set it to ``OLD`` or ``NEW`` +explicitly. + +.. include:: DEPRECATED.txt |