summaryrefslogtreecommitdiff
path: root/Help
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-10-16 08:26:00 -0400
committerBrad King <brad.king@kitware.com>2020-10-16 08:26:00 -0400
commit5c3a91c8080f0b12e07865e01f5dfdd76867ca09 (patch)
treeac617cae4a6985d1e436d487f15a55fe6c20f385 /Help
parentb1d9a25f35a22f41b2c1b87725f091936711a28c (diff)
downloadcmake-5c3a91c8080f0b12e07865e01f5dfdd76867ca09.tar.gz
CMP0111: Clarify that the new error is on a missing property setting
The previous wording could be confused with the file missing on disk.
Diffstat (limited to 'Help')
-rw-r--r--Help/manual/cmake-policies.7.rst2
-rw-r--r--Help/policy/CMP0111.rst13
-rw-r--r--Help/release/3.19.rst2
3 files changed, 12 insertions, 5 deletions
diff --git a/Help/manual/cmake-policies.7.rst b/Help/manual/cmake-policies.7.rst
index 0392325e83..fa10f664c4 100644
--- a/Help/manual/cmake-policies.7.rst
+++ b/Help/manual/cmake-policies.7.rst
@@ -60,7 +60,7 @@ Policies Introduced by CMake 3.19
CMP0114: ExternalProject step targets fully adopt their steps. </policy/CMP0114>
CMP0113: Makefile generators do not repeat custom commands from target dependencies. </policy/CMP0113>
CMP0112: Target file component generator expressions do not add target dependencies. </policy/CMP0112>
- CMP0111: An imported target with a missing location fails during generation. </policy/CMP0111>
+ CMP0111: An imported target missing its location property fails during generation. </policy/CMP0111>
CMP0110: add_test() supports arbitrary characters in test names. </policy/CMP0110>
CMP0109: find_program() requires permission to execute but not to read. </policy/CMP0109>
diff --git a/Help/policy/CMP0111.rst b/Help/policy/CMP0111.rst
index 37e5ad56b0..e32758354e 100644
--- a/Help/policy/CMP0111.rst
+++ b/Help/policy/CMP0111.rst
@@ -3,10 +3,17 @@ CMP0111
.. versionadded:: 3.19
-An imported target with a missing location fails during generation.
+An imported target missing its location property fails during generation.
-Prior to this the location would be generated as ``<TARGET_NAME>-NOTFOUND``,
-which would result in build failures.
+:ref:`Imported Targets` for library files and executables require that
+their location on disk is specified in a target property such as
+:prop_tgt:`IMPORTED_LOCATION`, :prop_tgt:`IMPORTED_IMPLIB`, or a
+per-configuration equivalent. If a needed location property is not set,
+CMake 3.18 and below generate the string ``<TARGET_NAME>-NOTFOUND`` in
+its place, which results in failures of the corresponding rules at build
+time. CMake 3.19 and above prefer instead to raise an error during
+generation. This policy provides compatibility for projects that have
+not been updated to expect the new behavior.
The ``OLD`` behavior of this policy is to generate the location of an imported
unknown, static or shared library target as ``<TARGET_NAME>-NOTFOUND`` if not
diff --git a/Help/release/3.19.rst b/Help/release/3.19.rst
index ea68594506..93e060e7c1 100644
--- a/Help/release/3.19.rst
+++ b/Help/release/3.19.rst
@@ -293,7 +293,7 @@ Other Changes
* The :command:`find_program` command now requires permission to execute
but not to read the file found. See policy :policy:`CMP0109`.
-* An imported target with a missing location now fails during generation
+* An imported target missing its location property fails during generation
if the location is used. See policy :policy:`CMP0111`.
* The following target-based generator expressions that query for directory or