diff options
author | Brad King <brad.king@kitware.com> | 2019-03-15 14:45:39 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-03-15 14:45:51 (GMT) |
commit | 3261f2387038e251d25852069f0ffc6fb81ed0a0 (patch) | |
tree | cad862584e7da75467d5ec0070b3dc5c55980e6f /Help/variable | |
parent | a6d8165dd2abe81dd133d188c8fe81323944c469 (diff) | |
parent | 9bede5c4cecd71fba7ce6a0687c4a68e1c84a54b (diff) | |
download | CMake-3261f2387038e251d25852069f0ffc6fb81ed0a0.zip CMake-3261f2387038e251d25852069f0ffc6fb81ed0a0.tar.gz CMake-3261f2387038e251d25852069f0ffc6fb81ed0a0.tar.bz2 |
Merge topic 'export-package-default-off'
9bede5c4ce export: Disable PACKAGE mode user package registry by default
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Lukas Mosimann <lumosimann@gmail.com>
Merge-request: !3041
Diffstat (limited to 'Help/variable')
-rw-r--r-- | Help/variable/CMAKE_EXPORT_NO_PACKAGE_REGISTRY.rst | 9 | ||||
-rw-r--r-- | Help/variable/CMAKE_EXPORT_PACKAGE_REGISTRY.rst | 15 |
2 files changed, 22 insertions, 2 deletions
diff --git a/Help/variable/CMAKE_EXPORT_NO_PACKAGE_REGISTRY.rst b/Help/variable/CMAKE_EXPORT_NO_PACKAGE_REGISTRY.rst index ee109ba..768ed64 100644 --- a/Help/variable/CMAKE_EXPORT_NO_PACKAGE_REGISTRY.rst +++ b/Help/variable/CMAKE_EXPORT_NO_PACKAGE_REGISTRY.rst @@ -1,11 +1,16 @@ CMAKE_EXPORT_NO_PACKAGE_REGISTRY -------------------------------- -Disable the :command:`export(PACKAGE)` command. +Disable the :command:`export(PACKAGE)` command when :policy:`CMP0090` +is not set to ``NEW``. In some cases, for example for packaging and for system wide installations, it is not desirable to write the user package registry. -If the :variable:`CMAKE_EXPORT_NO_PACKAGE_REGISTRY` variable is enabled, +If the ``CMAKE_EXPORT_NO_PACKAGE_REGISTRY`` variable is enabled, the :command:`export(PACKAGE)` command will do nothing. +If :policy:`CMP0090` is set to ``NEW`` this variable does nothing, and the +:variable:`CMAKE_EXPORT_PACKAGE_REGISTRY` variable controls the behavior +instead. + See also :ref:`Disabling the Package Registry`. diff --git a/Help/variable/CMAKE_EXPORT_PACKAGE_REGISTRY.rst b/Help/variable/CMAKE_EXPORT_PACKAGE_REGISTRY.rst new file mode 100644 index 0000000..3476a19 --- /dev/null +++ b/Help/variable/CMAKE_EXPORT_PACKAGE_REGISTRY.rst @@ -0,0 +1,15 @@ +CMAKE_EXPORT_PACKAGE_REGISTRY +----------------------------- + +Enables the :command:`export(PACKAGE)` command when :policy:`CMP0090` +is set to ``NEW``. + +The :command:`export(PACKAGE)` command does nothing by default. In some cases +it is desirable to write to the user package registry, so the +``CMAKE_EXPORT_PACKAGE_REGISTRY`` variable may be set to enable it. + +If :policy:`CMP0090` is *not* set to ``NEW`` this variable does nothing, and +the :variable:`CMAKE_EXPORT_NO_PACKAGE_REGISTRY` variable controls the behavior +instead. + +See also :ref:`Disabling the Package Registry`. |