Merge topic 'policy-version-env'

33856b1d62 Add CMAKE_POLICY_VERSION_MINIMUM environment variable
04721acc6c Tests: Cover CMAKE_POLICY_VERSION_MINIMUM in initial cache script
729470ff6d Tests: Cover CMAKE_POLICY_VERSION_MINIMUM in script mode
6cd10ffed7 Tests: Cover CMAKE_POLICY_VERSION_MINIMUM as cache entry

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: John Parent <john.parent@kitware.com>
Merge-request: !10376
This commit is contained in:
Brad King
2025-02-21 14:12:36 +00:00
committed by Kitware Robot
38 changed files with 133 additions and 9 deletions

View File

@@ -16,6 +16,10 @@ to externally set policies for which a project has not itself been updated:
``-DCMAKE_POLICY_VERSION_MINIMUM=3.5``, to try configuring a project
that has not been updated to set at least that policy version itself.
Alternatively, users may set the :envvar:`CMAKE_POLICY_VERSION_MINIMUM`
environment variable to initialize the cache entry in new build trees
automatically.
* Projects may set this variable before a call to :command:`add_subdirectory`
that adds a third-party project in order to set its policy version without
modifying third-party code.