1CMP0062
2-------
3
4.. versionadded:: 3.3
5
6Disallow :command:`install` of :command:`export` result.
7
8The :command:`export()` command generates a file containing
9:ref:`Imported Targets`, which is suitable for use from the build
10directory.  It is not suitable for installation because it contains absolute
11paths to buildsystem locations, and is particular to a single build
12configuration.
13
14The :command:`install(EXPORT)` generates and installs files which contain
15:ref:`Imported Targets`.  These files are generated with relative paths
16(unless the user specifies absolute paths), and are designed for
17multi-configuration use.  See :ref:`Creating Packages` for more.
18
19CMake 3.3 no longer allows the use of the :command:`install(FILES)` command
20with the result of the :command:`export()` command.
21
22The ``OLD`` behavior for this policy is to allow installing the result of
23an :command:`export()` command.  The ``NEW`` behavior for this policy is
24not to allow installing the result of an :command:`export()` command.
25
26This policy was introduced in CMake version 3.3.  CMake version
27|release| warns when the policy is not set and uses ``OLD`` behavior.  Use
28the :command:`cmake_policy()` command to set it to ``OLD`` or ``NEW``
29explicitly.
30
31.. include:: DEPRECATED.txt
32