diff options
author | Brad King <brad.king@kitware.com> | 2024-01-29 15:36:13 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2024-01-29 15:36:22 (GMT) |
commit | d377ccbf672f4aba36131fed8151058ee0a97eed (patch) | |
tree | 5b9019cd3f09f0312f60fe407b4d74c686948d26 /Help | |
parent | fdb05a421a2e49328dc19150a872d6c98362bcf4 (diff) | |
parent | 339ae33e555b1820174ca99e9aaa04dffe29febc (diff) | |
download | CMake-d377ccbf672f4aba36131fed8151058ee0a97eed.zip CMake-d377ccbf672f4aba36131fed8151058ee0a97eed.tar.gz CMake-d377ccbf672f4aba36131fed8151058ee0a97eed.tar.bz2 |
Merge topic 'productbuild-domains-policy'
339ae33e55 CPack: Change CPACK_PRODUCTBUILD_DOMAINS default to true (CMP0161)
4e7f2397e4 CPack: Clear temporary variable after it is no longer needed
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9197
Diffstat (limited to 'Help')
-rw-r--r-- | Help/cpack_gen/productbuild.rst | 5 | ||||
-rw-r--r-- | Help/manual/cmake-policies.7.rst | 1 | ||||
-rw-r--r-- | Help/policy/CMP0161.rst | 36 | ||||
-rw-r--r-- | Help/release/dev/productbuild-domains-policy.rst | 5 |
4 files changed, 45 insertions, 2 deletions
diff --git a/Help/cpack_gen/productbuild.rst b/Help/cpack_gen/productbuild.rst index 48a9b44..ee8a03f 100644 --- a/Help/cpack_gen/productbuild.rst +++ b/Help/cpack_gen/productbuild.rst @@ -91,8 +91,9 @@ macOS using ProductBuild: .. versionadded:: 3.23 This option enables more granular control over where the product may be - installed. When it is set to true, a ``domains`` element of the following - form will be added to the productbuild Distribution XML: + installed. When it is set to true (see policy :policy:`CMP0161`), a + ``domains`` element of the following form will be added to the + productbuild Distribution XML: .. code-block:: xml diff --git a/Help/manual/cmake-policies.7.rst b/Help/manual/cmake-policies.7.rst index d37c855..bb6cfd4 100644 --- a/Help/manual/cmake-policies.7.rst +++ b/Help/manual/cmake-policies.7.rst @@ -57,6 +57,7 @@ Policies Introduced by CMake 3.29 .. toctree:: :maxdepth: 1 + CMP0161: CPACK_PRODUCTBUILD_DOMAINS defaults to true. </policy/CMP0161> CMP0160: More read-only target properties now error when trying to set them. </policy/CMP0160> CMP0159: file(STRINGS) with REGEX updates CMAKE_MATCH_<n>. </policy/CMP0159> CMP0158: add_test() honors CMAKE_CROSSCOMPILING_EMULATOR only when cross-compiling. </policy/CMP0158> diff --git a/Help/policy/CMP0161.rst b/Help/policy/CMP0161.rst new file mode 100644 index 0000000..34bb64c --- /dev/null +++ b/Help/policy/CMP0161.rst @@ -0,0 +1,36 @@ +CMP0161 +------- + +.. versionadded:: 3.29 + +The :variable:`CPACK_PRODUCTBUILD_DOMAINS` variable defaults to true. + +Before CMake 3.29, the :variable:`CPACK_PRODUCTBUILD_DOMAINS` variable is +unset by default. When using the :cpack_gen:`CPack productbuild Generator`, +this disables the use of the ``domains`` attribute in the productbuild +Distribution XML, and falls back to the ``auth`` attribute instead. +These attributes control where a productbuild package is allowed to be +installed. But the ``auth`` attribute has been deprecated by Apple, +so projects should migrate to using ``domains`` instead. + +CMake 3.29 and above prefer to use a default value of true for +:variable:`CPACK_PRODUCTBUILD_DOMAINS`, which means ``domains`` will be used +by default unless the project explicitly sets +:variable:`CPACK_PRODUCTBUILD_DOMAINS` to false. +This policy provides compatibility with projects that enabled the +:cpack_gen:`CPack productbuild Generator`, but did not explicitly set +:variable:`CPACK_PRODUCTBUILD_DOMAINS`. + +The ``OLD`` behavior for this policy is to leave +:variable:`CPACK_PRODUCTBUILD_DOMAINS` unset if it hasn't been set. +The ``NEW`` behavior for this policy is to use a default value of true for +:variable:`CPACK_PRODUCTBUILD_DOMAINS`. + +.. |INTRODUCED_IN_CMAKE_VERSION| replace:: 3.29 +.. |WARNS_OR_DOES_NOT_WARN| replace:: warns +.. include:: STANDARD_ADVICE.txt +Note that a warning will only be emitted if the +:variable:`CPACK_BINARY_PRODUCTBUILD <CPACK_BINARY_<GENNAME>>` variable is +set to true and the project is being built for an Apple platform. + +.. include:: DEPRECATED.txt diff --git a/Help/release/dev/productbuild-domains-policy.rst b/Help/release/dev/productbuild-domains-policy.rst new file mode 100644 index 0000000..2009453 --- /dev/null +++ b/Help/release/dev/productbuild-domains-policy.rst @@ -0,0 +1,5 @@ +productbuild-domains-policy +--------------------------- + +* The :variable:`CPACK_PRODUCTBUILD_DOMAINS` variable now defaults to true. + See policy :policy:`CMP0161`. |