1CMAKE-POLICIES(7)                    CMake                   CMAKE-POLICIES(7)
2
3
4

NAME

6       cmake-policies - CMake Policies Reference
7

INTRODUCTION

9       Policies  in  CMake  are  used to preserve backward compatible behavior
10       across multiple releases.  When a new policy is introduced, newer CMake
11       versions will begin to warn about the backward compatible behavior.  It
12       is possible to disable the warning by explicitly requesting the OLD, or
13       backward  compatible  behavior using the cmake_policy() command.  It is
14       also possible to request NEW, or non-backward compatible behavior for a
15       policy,  also  avoiding  the  warning.   Each policy can also be set to
16       either NEW or OLD behavior explicitly on  the  command  line  with  the
17       CMAKE_POLICY_DEFAULT_CMP<NNNN> variable.
18
19       A  policy is a deprecation mechanism and not a reliable feature toggle.
20       A policy should almost never be set to OLD, except to silence  warnings
21       in  an otherwise frozen or stable codebase, or temporarily as part of a
22       larger migration path. The OLD behavior of each policy  is  undesirable
23       and will be replaced with an error condition in a future release.
24
25       The  cmake_minimum_required() command does more than report an error if
26       a too-old version of CMake is used to build a project.   It  also  sets
27       all  policies introduced in that CMake version or earlier to NEW behav‐
28       ior.  To manage policies without increasing the minimum required  CMake
29       version, the if(POLICY) command may be used:
30
31          if(POLICY CMP0990)
32            cmake_policy(SET CMP0990 NEW)
33          endif()
34
35       This has the effect of using the NEW behavior with newer CMake releases
36       which users may be using and not issuing a compatibility warning.
37
38       The setting of a policy is confined in some cases to not  propagate  to
39       the parent scope.  For example, if the files read by the include() com‐
40       mand or the find_package() command contain  a  use  of  cmake_policy(),
41       that  policy  setting will not affect the caller by default.  Both com‐
42       mands accept an optional NO_POLICY_SCOPE keyword to control this behav‐
43       ior.
44
45       The  CMAKE_MINIMUM_REQUIRED_VERSION variable may also be used to deter‐
46       mine whether to report an error on use of deprecated  macros  or  func‐
47       tions.
48

POLICIES INTRODUCED BY CMAKE 3.16

50   CMP0097
51       ExternalProject_Add() with GIT_SUBMODULES "" initializes no submodules.
52
53       The module provides a GIT_SUBMODULES option which controls what submod‐
54       ules to initialize and update. Starting  with  CMake  3.16,  explicitly
55       setting  GIT_SUBMODULES  to an empty string means no submodules will be
56       initialized or updated.
57
58       This policy provides compatibility for  projects  that  have  not  been
59       updated to expect the new behavior.
60
61       The  OLD  behavior for this policy is for GIT_SUBMODULES when set to an
62       empty string to initialize and update  all  git  submodules.   The  NEW
63       behavior  for  this  policy  is for GIT_SUBMODULES when set to an empty
64       string to initialize and update no git submodules.
65
66       This policy was introduced in CMake version 3.16.  Use  the  cmake_pol‐
67       icy()  command  to  set it to OLD or NEW explicitly.  Unlike most poli‐
68       cies, CMake version 3.16.1 does not warn when this policy  is  not  set
69       and simply uses OLD behavior.
70
71   CMP0096
72       The project() command preserves leading zeros in version components.
73
74       When a VERSION <major>[.<minor>[.<patch>[.<tweak>]]]] argument is given
75       to  the  project()  command,  it  stores  the  version  string  in  the
76       PROJECT_VERSION  variable  and stores individual integer version compo‐
77       nents in PROJECT_VERSION_{MAJOR,MINOR,PATCH,TWEAK} variables (see  pol‐
78       icy  CMP0048).   CMake  3.15  and below dropped leading zeros from each
79       component.  CMake 3.16 and higher prefer  to  preserve  leading  zeros.
80       This  policy  provides  compatibility  for  projects that have not been
81       updated to expect the new behavior.
82
83       The OLD behavior of this policy drops leading zeros in all  components,
84       e.g.   such  that  version  1.07.06 becomes 1.7.6.  The NEW behavior of
85       this policy preserves the leading zeros in all  components,  such  that
86       version 1.07.06 remains unchanged.
87
88       This  policy  was  introduced in CMake version 3.16.  Unlike many poli‐
89       cies, CMake version 3.16.1 does not warn when this policy  is  not  set
90       and  simply  uses  the OLD behavior.  Use the cmake_policy() command to
91       set it to OLD or NEW explicitly.
92
93       NOTE:
94          The OLD behavior of a policy is deprecated by definition and may  be
95          removed in a future version of CMake.
96
97   CMP0095
98       RPATH  entries  are  properly escaped in the intermediary CMake install
99       script.
100
101       In CMake 3.15 and earlier, RPATH entries set via CMAKE_INSTALL_RPATH or
102       via  INSTALL_RPATH have not been escaped before being inserted into the
103       cmake_install.cmake script. Dynamic linkers on ELF-based systems  (e.g.
104       Linux  and  FreeBSD)  allow  certain keywords in RPATH entries, such as
105       ${ORIGIN} (More details are available in the ld.so man pages  on  those
106       systems).  The syntax of these keywords can match CMake’s variable syn‐
107       tax. In order to not  be  substituted  (usually  to  an  empty  string)
108       already by the intermediary cmake_install.cmake script, the user had to
109       double-escape  such  RPATH  keywords,   e.g.    set(CMAKE_INSTALL_RPATH
110       "\\\${ORIGIN}/../lib").   Since  the  intermediary  cmake_install.cmake
111       script is an implementation detail of CMake, CMake 3.16 and later  will
112       make  sure RPATH entries are inserted literally by escaping any coinci‐
113       dental CMake syntax.
114
115       The OLD behavior of this policy is to not escape RPATH entries  in  the
116       intermediary  cmake_install.cmake  script. The NEW behavior is to prop‐
117       erly escape coincidental CMake syntax in RPATH entries when  generating
118       the intermediary cmake_install.cmake script.
119
120       This  policy was introduced in CMake version 3.16. CMake version 3.16.1
121       warns when the policy is not set and detected usage of CMake-like  syn‐
122       tax  and uses OLD behavior. Use the cmake_policy() command to set it to
123       OLD or NEW explicitly.
124
125       NOTE:
126          The OLD behavior of a policy is deprecated by definition and may  be
127          removed in a future version of CMake.
128

POLICIES INTRODUCED BY CMAKE 3.15

130   CMP0094
131       Modules FindPython3, FindPython2 and FindPython use LOCATION for lookup
132       strategy.
133
134       Starting with CMake 3.15, Modules FindPython3,  FindPython2  and  Find‐
135       Python    set    value    LOCATION    for,    respectively,   variables
136       Python3_FIND_STRATEGY, Python2_FIND_STRATEGY and  Python_FIND_STRATEGY.
137       This policy provides compatibility with projects that expect the legacy
138       behavior.
139
140       The OLD behavior for  this  policy  set  value  VERSION  for  variables
141       Python3_FIND_STRATEGY, Python2_FIND_STRATEGY and Python_FIND_STRATEGY.
142
143       This  policy  was introduced in CMake version 3.15.  Use the cmake_pol‐
144       icy() command to set it to OLD or NEW explicitly.   Unlike  many  poli‐
145       cies,  CMake  version  3.16.1 does not warn when this policy is not set
146       and simply uses the OLD behavior.
147
148       NOTE:
149          The OLD behavior of a policy is deprecated by definition and may  be
150          removed in a future version of CMake.
151
152   CMP0093
153       FindBoost reports Boost_VERSION in x.y.z format.
154
155       In  CMake 3.14 and below the module would report the Boost version num‐
156       ber as specified in the preprocessor definition  BOOST_VERSION  in  the
157       boost/version.hpp  file.  In  CMake 3.15 and later it is preferred that
158       the reported version number matches the x.y.z format  reported  by  the
159       CMake  package  shipped with Boost 1.70.0 and later. The macro value is
160       still reported in the Boost_VERSION_MACRO variable.
161
162       The OLD behavior for this policy is for FindBoost to report  Boost_VER‐
163       SION  as  specified  in  the  preprocessor  definition BOOST_VERSION in
164       boost/version.hpp. The NEW behavior for this policy is for FindBoost to
165       report Boost_VERSION in x.y.z format.
166
167       This  policy  was introduced in CMake version 3.15.  Use the cmake_pol‐
168       icy() command to set it to OLD or NEW explicitly.   Unlike  many  poli‐
169       cies,  CMake  version  3.16.1 does not warn when this policy is not set
170       and simply uses the OLD behavior.
171
172       NOTE:
173          The OLD behavior of a policy is deprecated by definition and may  be
174          removed in a future version of CMake.
175
176   CMP0092
177       MSVC warning flags are not in CMAKE_<LANG>_FLAGS by default.
178
179       When  using  MSVC-like compilers in CMake 3.14 and below, warning flags
180       like /W3 are added to CMAKE_<LANG>_FLAGS by default.  This is  problem‐
181       atic  for  projects  that want to choose a different warning level pro‐
182       grammatically.  In  particular,  it  requires  string  editing  of  the
183       CMAKE_<LANG>_FLAGS  variables  with  knowledge  of  the  CMake  builtin
184       defaults so they can be replaced.
185
186       CMake 3.15 and above prefer to leave out warning flags from  the  value
187       of CMAKE_<LANG>_FLAGS by default.
188
189       This  policy  provides  compatibility  with projects that have not been
190       updated to expect the lack of warning flags.  The policy setting  takes
191       effect as of the first project() or enable_language() command that ini‐
192       tializes CMAKE_<LANG>_FLAGS for a given lanuage <LANG>.
193
194       NOTE:
195          Once the policy has taken effect at the top of a project for a given
196          language, that choice must be used throughout the tree for that lan‐
197          guage.  In projects that have nested projects in subdirectories,  be
198          sure to convert everything together.
199
200       The  OLD behavior for this policy is to place MSVC warning flags in the
201       default CMAKE_<LANG>_FLAGS cache entries.  The NEW  behavior  for  this
202       policy is to not place MSVC warning flags in the default cache entries.
203
204       This  policy  was introduced in CMake version 3.15.  Use the cmake_pol‐
205       icy() command to set it to OLD or NEW explicitly.   Unlike  many  poli‐
206       cies,  CMake  version  3.16.1 does not warn when this policy is not set
207       and simply uses OLD behavior.
208
209       NOTE:
210          The OLD behavior of a policy is deprecated by definition and may  be
211          removed in a future version of CMake.
212
213   CMP0091
214       MSVC runtime library flags are selected by an abstraction.
215
216       Compilers  targeting the MSVC ABI have flags to select the MSVC runtime
217       library.  Runtime library selection typically varies with build config‐
218       uration because there is a separate runtime library for Debug builds.
219
220       In CMake 3.14 and below, MSVC runtime library selection flags are added
221       to the default CMAKE_<LANG>_FLAGS_<CONFIG> cache entries by CMake auto‐
222       matically.  This allows users to edit their cache entries to adjust the
223       flags.  However, the presence of such default flags is problematic  for
224       projects  that  want to choose a different runtime library programmati‐
225       cally.   In   particular,   it   requires   string   editing   of   the
226       CMAKE_<LANG>_FLAGS_<CONFIG>  variables  with  knowledge  of  the  CMake
227       builtin defaults so they can be replaced.
228
229       CMake 3.15 and above prefer to leave the MSVC runtime library selection
230       flags out of the default CMAKE_<LANG>_FLAGS_<CONFIG> values and instead
231       offer a first-class abstraction.  The CMAKE_MSVC_RUNTIME_LIBRARY  vari‐
232       able  and MSVC_RUNTIME_LIBRARY target property may be set to select the
233       MSVC runtime library.  If they are not set then CMake uses the  default
234       value  MultiThreaded$<$<CONFIG:Debug>:Debug>DLL  which is equivalent to
235       the original flags.
236
237       This policy provides compatibility with projects  that  have  not  been
238       updated  to  be  aware  of  the  abstraction.  The policy setting takes
239       effect as of the first  project()  or  enable_language()  command  that
240       enables a language whose compiler targets the MSVC ABI.
241
242       NOTE:
243          Once  the  policy  has  taken  effect  at the top of a project, that
244          choice must be used throughout the  tree.   In  projects  that  have
245          nested  projects  in  subdirectories,  be sure to convert everything
246          together.
247
248       The OLD behavior for this policy is to place MSVC runtime library flags
249       in the default CMAKE_<LANG>_FLAGS_<CONFIG> cache entries and ignore the
250       CMAKE_MSVC_RUNTIME_LIBRARY abstraction.  The NEW behavior for this pol‐
251       icy  is  to  not  place MSVC runtime library flags in the default cache
252       entries and use the abstraction instead.
253
254       This policy was introduced in CMake version 3.15.  Use  the  cmake_pol‐
255       icy()  command  to  set it to OLD or NEW explicitly.  Unlike many poli‐
256       cies, CMake version 3.16.1 does not warn when this policy  is  not  set
257       and simply uses OLD behavior.
258
259       NOTE:
260          The  OLD behavior of a policy is deprecated by definition and may be
261          removed in a future version of CMake.
262
263   CMP0090
264       export(PACKAGE) does not populate package registry by default.
265
266       In CMake 3.14 and below the export(PACKAGE) command populated the  user
267       package   registry   by   default   and   users   needed   to  set  the
268       CMAKE_EXPORT_NO_PACKAGE_REGISTRY to disable it, e.g. in automated build
269       and  packaging environments.  Since the user package registry is stored
270       outside the build tree, this side  effect  should  not  be  enabled  by
271       default.   Therefore  CMake  3.15 and above prefer that export(PACKAGE)
272       does nothing unless an explicit CMAKE_EXPORT_PACKAGE_REGISTRY  variable
273       is  set to enable it.  This policy provides compatibility with projects
274       that have not been updated.
275
276       The OLD behavior for this policy is for export(PACKAGE) command to pop‐
277       ulate the user package registry unless CMAKE_EXPORT_NO_PACKAGE_REGISTRY
278       is enabled.  The NEW behavior is  for  export(PACKAGE)  command  to  do
279       nothing unless the CMAKE_EXPORT_PACKAGE_REGISTRY is enabled.
280
281       This  policy  was introduced in CMake version 3.15.  Use the cmake_pol‐
282       icy() command to set it to OLD or NEW explicitly.   Unlike  most  poli‐
283       cies,  CMake  version  3.16.1 does not warn when this policy is not set
284       and simply uses OLD behavior.
285
286       NOTE:
287          The OLD behavior of a policy is deprecated by definition and may  be
288          removed in a future version of CMake.
289
290   CMP0089
291       Compiler id for IBM Clang-based XL compilers is now XLClang.
292
293       CMake 3.15 and above recognize that IBM’s Clang-based XL compilers that
294       define __ibmxl__ are a new front-end distinct from xlc with a different
295       command  line  and  set  of capabilities.  CMake now prefers to present
296       this to projects by setting the  CMAKE_<LANG>_COMPILER_ID  variable  to
297       XLClang  instead of XL.  However, existing projects may assume the com‐
298       piler id for Clang-based XL is just XL as  it  was  in  CMake  versions
299       prior  to  3.15.   Therefore  this policy determines for Clang-based XL
300       compilers which compiler id to report in  the  CMAKE_<LANG>_COMPILER_ID
301       variable   after  language  <LANG>  is  enabled  by  the  project()  or
302       enable_language() command.  The policy must be set prior to the invoca‐
303       tion of either command.
304
305       The  OLD  behavior  for  this policy is to use compiler id XL.  The NEW
306       behavior for this policy is to use compiler id XLClang.
307
308       This policy was introduced in CMake version 3.15.  Use  the  cmake_pol‐
309       icy() command to set this policy to OLD or NEW explicitly.  Unlike most
310       policies, CMake version 3.16.1 does not warn by default when this  pol‐
311       icy  is not set and simply uses OLD behavior.  See documentation of the
312       CMAKE_POLICY_WARNING_CMP0089 variable to control the warning.
313
314       NOTE:
315          The OLD behavior of a policy is deprecated by definition and may  be
316          removed in a future version of CMake.
317

POLICIES INTRODUCED BY CMAKE 3.14

319   CMP0088
320       FindBISON runs bison in CMAKE_CURRENT_BINARY_DIR when executing.
321
322       The  module provides a BISON_TARGET macro which generates BISON output.
323       In CMake 3.13 and below the macro would generate a custom command  that
324       runs bison in the source directory.  CMake 3.14 and later prefer to run
325       it in the build directory and use CMAKE_CURRENT_BINARY_DIR as the WORK‐
326       ING_DIRECTORY  of  its  add_custom_command()  invocation.  This ensures
327       that any implicitly generated file is written to the build tree  rather
328       than the source.
329
330       This  policy  provides  compatibility  for  projects that have not been
331       updated to expect the new behavior.
332
333       The OLD behavior for this policy is for BISON_TARGET to use the current
334       source  directory  for  the  WORKING_DIRECTORY  and  where  to generate
335       implicit files. The NEW behavior of this policy is to use  the  current
336       binary  directory  for  the  WORKING_DIRECTORY  and  where  to generate
337       implicit files.
338
339       This policy was introduced in CMake version 3.14.  Use  the  cmake_pol‐
340       icy()  command  to  set it to OLD or NEW explicitly.  Unlike most poli‐
341       cies, CMake version 3.16.1 does not warn when this policy  is  not  set
342       and simply uses OLD behavior.
343
344       NOTE:
345          The  OLD behavior of a policy is deprecated by definition and may be
346          removed in a future version of CMake.
347
348   CMP0087
349       install(CODE) and install(SCRIPT) support generator expressions.
350
351       In CMake 3.13 and earlier, install(CODE) and  install(SCRIPT)  did  not
352       evaluate  generator  expressions.   CMake  3.14 and later will evaluate
353       generator expressions for install(CODE) and install(SCRIPT).
354
355       The  OLD  behavior  of   this   policy   is   for   install(CODE)   and
356       install(SCRIPT)  to not evaluate generator expressions.  The NEW behav‐
357       ior  is  to  evaluate  generator  expressions  for  install(CODE)   and
358       install(SCRIPT).
359
360       Note  that  it  is  the  value of this policy setting at the end of the
361       directory scope that is important, not its setting at the time  of  the
362       call  to  install(CODE)  or install(SCRIPT).  This has implications for
363       calling these commands from places that have their own policy scope but
364       not their own directory scope (e.g. from files brought in via include()
365       rather than add_subdirectory()).
366
367       This policy was introduced in CMake version 3.14.  CMake version 3.16.1
368       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
369       cmake_policy() command to set it to OLD or NEW explicitly.
370
371       NOTE:
372          The OLD behavior of a policy is deprecated by definition and may  be
373          removed in a future version of CMake.
374
375   CMP0086
376       UseSWIG honors SWIG_MODULE_NAME via -module flag.
377
378       Starting  with  CMake 3.14, UseSWIG passes option -module <module_name>
379       to SWIG compiler if the file property  SWIG_MODULE_NAME  is  specified.
380       This policy provides compatibility with projects that expect the legacy
381       behavior.
382
383       The OLD behavior for this policy is to never pass -module option.   The
384       NEW  behavior  is  to pass -module option to SWIG compiler if SWIG_MOD‐
385       ULE_NAME is specified.
386
387       This policy was introduced in CMake version 3.14.  CMake version 3.16.1
388       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
389       cmake_policy() command to set it to OLD or NEW explicitly.
390
391       NOTE:
392          The OLD behavior of a policy is deprecated by definition and may  be
393          removed in a future version of CMake.
394
395   CMP0085
396       $<IN_LIST:...> handles empty list items.
397
398       In CMake 3.13 and lower, the $<IN_LIST:...> generator expression always
399       returned 0 if the first argument was empty, even if the list  contained
400       an  empty item. This behavior is inconsistent with the IN_LIST behavior
401       of if(), which this generator expression is  meant  to  emulate.  CMake
402       3.14 and later handles this case correctly.
403
404       The  OLD behavior of this policy is for $<IN_LIST:...> to always return
405       0 if the first argument is empty. The NEW behavior is to  return  1  if
406       the first argument is empty and the list contains an empty item.
407
408       This policy was introduced in CMake version 3.14.  CMake version 3.16.1
409       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
410       cmake_policy() command to set it to OLD or NEW explicitly.
411
412       NOTE:
413          The  OLD behavior of a policy is deprecated by definition and may be
414          removed in a future version of CMake.
415
416   CMP0084
417       The FindQt module does not exist for find_package().
418
419       The existence of FindQt means that for Qt upstream to  provide  package
420       config  files  that  can  be  found  by find_package(Qt), the consuming
421       project has to explicitly  specify  find_package(Qt  CONFIG).  Removing
422       this  module gives Qt a path forward for exporting its own config files
423       which can easily be found by consuming projects.
424
425       This policy pretends that CMake’s internal FindQt module does not exist
426       for  find_package(). If a project really wants to use Qt 3 or 4, it can
427       call find_package(Qt[34]), include(FindQt),  or  add  FindQt  to  their
428       CMAKE_MODULE_PATH.
429
430       The  OLD  behavior of this policy is for FindQt to exist for find_pack‐
431       age(). The NEW behavior  is  to  pretend  that  it  doesn’t  exist  for
432       find_package().
433
434       This policy was introduced in CMake version 3.14.  CMake version 3.16.1
435       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
436       cmake_policy() command to set it to OLD or NEW explicitly.
437
438       NOTE:
439          The  OLD behavior of a policy is deprecated by definition and may be
440          removed in a future version of CMake.
441
442   CMP0083
443       To control generation of Position Independent Executable (PIE) or  not,
444       some flags are required at link time.
445
446       CMake  3.13  and lower did not add these link flags when POSITION_INDE‐
447       PENDENT_CODE is set.
448
449       The OLD behavior for this policy is to not manage PIE link  flags.  The
450       NEW behavior is to add link flags if POSITION_INDEPENDENT_CODE is set:
451
452       · Set  to  TRUE: flags to produce a position independent executable are
453         passed to the linker step. For example -pie for GCC.
454
455       · Set to FALSE: flags not to produce a position independent  executable
456         are passed to the linker step. For example -no-pie for GCC.
457
458       · Not set: no flags are passed to the linker step.
459
460       Since  a  given linker may not support PIE flags in all environments in
461       which it is used, it is the project’s responsibility to use the  Check‐
462       PIESupported  module  to  check  for  support  to ensure that the POSI‐
463       TION_INDEPENDENT_CODE target property for executables will  be  honored
464       at link time.
465
466       This  policy  was  introduced in CMake version 3.14. Use the cmake_pol‐
467       icy() command to set it to OLD or NEW explicitly.   Unlike  most  poli‐
468       cies,  CMake  version  3.16.1 does not warn when this policy is not set
469       and simply uses OLD behavior.
470
471       NOTE:
472          Android platform has a special handling of PIE so it is not required
473          to  use  the  CheckPIESupported module to ensure flags are passed to
474          the linker.
475
476       NOTE:
477          The OLD behavior of a policy is deprecated by definition and may  be
478          removed in a future version of CMake.
479
480   Examples
481       Behave like CMake 3.13 and do not apply any PIE flags at link stage.
482
483          cmake_minimum_required(VERSION 3.13)
484          project(foo)
485
486          # ...
487
488          add_executable(foo ...)
489          set_property(TARGET foo PROPERTY POSITION_INDEPENDENT_CODE TRUE)
490
491       Use  the CheckPIESupported module to detect whether PIE is supported by
492       the current linker and environment.  Apply PIE flags only if the linker
493       supports them.
494
495          cmake_minimum_required(VERSION 3.14) # CMP0083 NEW
496          project(foo)
497
498          include(CheckPIESupported)
499          check_pie_supported()
500
501          # ...
502
503          add_executable(foo ...)
504          set_property(TARGET foo PROPERTY POSITION_INDEPENDENT_CODE TRUE)
505
506   CMP0082
507       Install  rules from add_subdirectory() calls are interleaved with those
508       in caller.
509
510       CMake 3.13 and lower ran  the  install  rules  from  add_subdirectory()
511       after  all  other  install rules, even if add_subdirectory() was called
512       before the other install rules.  CMake 3.14 and above prefer to  inter‐
513       leave  these  add_subdirectory()  install rules with the others so that
514       they are run in the order they are declared.  This policy provides com‐
515       patibility  for  projects  that have not been updated to expect the new
516       behavior.
517
518       The OLD behavior for this policy is  to  run  the  install  rules  from
519       add_subdirectory() after the other install rules.  The NEW behavior for
520       this policy is to run all install rules in the order they are declared.
521
522       This policy was introduced in CMake version 3.14.   Unlike  most  poli‐
523       cies, CMake version 3.16.1 does not warn by default when this policy is
524       not set and  simply  uses  OLD  behavior.   See  documentation  of  the
525       CMAKE_POLICY_WARNING_CMP0082 variable to control the warning.
526
527       NOTE:
528          The  OLD behavior of a policy is deprecated by definition and may be
529          removed in a future version of CMake.
530

POLICIES INTRODUCED BY CMAKE 3.13

532   CMP0081
533       Relative paths not allowed in LINK_DIRECTORIES target property.
534
535       CMake 3.12 and lower allowed the LINK_DIRECTORIES directory property to
536       contain relative paths.  The base path for such relative entries is not
537       well defined.  CMake 3.13 and later will issue  a  FATAL_ERROR  if  the
538       LINK_DIRECTORIES   target   property   (which  is  initialized  by  the
539       LINK_DIRECTORIES directory property) contains a relative path.
540
541       The OLD behavior for this policy is not to warn about relative paths in
542       the LINK_DIRECTORIES target property.  The NEW behavior for this policy
543       is to issue a FATAL_ERROR if LINK_DIRECTORIES contains a relative path.
544
545       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
546       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
547       cmake_policy() command to set it to OLD or NEW explicitly.
548
549       NOTE:
550          The OLD behavior of a policy is deprecated by definition and may  be
551          removed in a future version of CMake.
552
553   CMP0080
554       BundleUtilities cannot be included at configure time.
555
556       The  macros  provided  by BundleUtilities are intended to be invoked at
557       install time rather than at configure time, because they depend on  the
558       listed  targets  already existing at the time they are invoked. If they
559       are invoked at configure time, the targets haven’t been built yet,  and
560       the commands will fail.
561
562       This  policy  restricts  the  inclusion  of BundleUtilities to cmake -P
563       style scripts and install rules. Specifically, it looks for  the  pres‐
564       ence of CMAKE_GENERATOR and throws a fatal error if it exists.
565
566       The  OLD  behavior  of  this  policy  is to allow BundleUtilities to be
567       included at configure time. The NEW behavior of this policy is to  dis‐
568       allow such inclusion.
569
570       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
571       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
572       cmake_policy() command to set it to OLD or NEW explicitly.
573
574       NOTE:
575          The  OLD behavior of a policy is deprecated by definition and may be
576          removed in a future version of CMake.
577
578   CMP0079
579       target_link_libraries() allows use with targets in other directories.
580
581       Prior to CMake 3.13 the target_link_libraries() command did not  accept
582       targets  not created in the calling directory as its first argument for
583       calls that update the LINK_LIBRARIES of  the  target  itself.   It  did
584       accidentally  accept  targets from other directories on calls that only
585       update the INTERFACE_LINK_LIBRARIES, but would simply  add  entries  to
586       the  property as if the call were made in the original directory.  Thus
587       link interface libraries specified this way were always  looked  up  by
588       generators in the scope of the original target rather than in the scope
589       that called target_link_libraries().
590
591       CMake 3.13 now allows the target_link_libraries() command to be  called
592       from  any  directory  to  add  link  dependencies  and  link  interface
593       libraries to targets created in other  directories.   The  entries  are
594       added  to  LINK_LIBRARIES  and INTERFACE_LINK_LIBRARIES using a special
595       (internal) suffix to tell the generators to look up the  names  in  the
596       calling scope rather than the scope that created the target.
597
598       This  policy provides compatibility with projects that already use tar‐
599       get_link_libraries() with the INTERFACE keyword on a target in  another
600       directory  to  add  INTERFACE_LINK_LIBRARIES entries to be looked up in
601       the target’s directory.  Such projects should be updated to be aware of
602       the new scoping rules in that case.
603
604       The  OLD behavior of this policy is to disallow target_link_libraries()
605       calls naming targets from another directory except  in  the  previously
606       accidentally allowed case of using the INTERFACE keyword only.  The NEW
607       behavior of this policy is to allow all such  calls  but  use  the  new
608       scoping rules.
609
610       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
611       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
612       cmake_policy() command to set it to OLD or NEW explicitly.
613
614       NOTE:
615          The  OLD behavior of a policy is deprecated by definition and may be
616          removed in a future version of CMake.
617
618   CMP0078
619       UseSWIG generates standard target names.
620
621       Starting with CMake 3.13, UseSWIG generates now standard target  names.
622       This policy provides compatibility with projects that expect the legacy
623       behavior.
624
625       The OLD behavior for this policy relies on  UseSWIG_TARGET_NAME_PREFER‐
626       ENCE  variable that can be used to specify an explicit preference.  The
627       value may be one of:
628
629       · LEGACY:   legacy   strategy   is    applied.    Variable    SWIG_MOD‐
630         ULE_<name>_REAL_NAME  must  be used to get real target name.  This is
631         the default if not specified.
632
633       · STANDARD: target name matches specified name.
634
635       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
636       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
637       cmake_policy() command to set it to OLD or NEW explicitly.
638
639       NOTE:
640          The OLD behavior of a policy is deprecated by definition and may  be
641          removed in a future version of CMake.
642
643   CMP0077
644       option() honors normal variables.
645
646       The option() command is typically used to create a cache entry to allow
647       users to set the option.  However, there are cases in  which  a  normal
648       (non-cached)  variable of the same name as the option may be defined by
649       the project prior to calling the  option()  command.   For  example,  a
650       project  that  embeds  another  project  as  a subdirectory may want to
651       hard-code options of the subproject to build the way it needs.
652
653       For historical reasons in CMake 3.12 and  below  the  option()  command
654       removes a normal (non-cached) variable of the same name when:
655
656       · a cache entry of the specified name does not exist at all, or
657
658       · a  cache  entry of the specified name exists but has not been given a
659         type (e.g. via -D<name>=ON on the command line).
660
661       In both of these cases (typically on the  first  run  in  a  new  build
662       tree), the option() command gives the cache entry type BOOL and removes
663       any normal (non-cached) variable of the same name.   In  the  remaining
664       case  that the cache entry of the specified name already exists and has
665       a type (typically on later runs in a build tree), the option()  command
666       changes nothing and any normal variable of the same name remains set.
667
668       In CMake 3.13 and above the option() command prefers to do nothing when
669       a normal variable of the given name already exists.  It does not create
670       or  update a cache entry or remove the normal variable.  The new behav‐
671       ior is consistent between the first and later runs  in  a  build  tree.
672       This  policy  provides  compatibility  with projects that have not been
673       updated to expect the new behavior.
674
675       When the option() command sees a normal variable of the given name:
676
677       · The OLD behavior for this policy is to proceed  even  when  a  normal
678         variable  of  the  same  name  exists.   If  the cache entry does not
679         already exist and have a type then it is created and/or given a  type
680         and the normal variable is removed.
681
682       · The NEW behavior for this policy is to do nothing when a normal vari‐
683         able of the same name exists.  The normal variable  is  not  removed.
684         The  cache  entry  is  not  created  or  updated and is ignored if it
685         exists.
686
687       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
688       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
689       cmake_policy() command to set it to OLD or NEW explicitly.
690
691       NOTE:
692          The OLD behavior of a policy is deprecated by definition and may  be
693          removed in a future version of CMake.
694
695   CMP0076
696       The target_sources() command converts relative paths to absolute.
697
698       In CMake 3.13 and above, the target_sources() command now converts rel‐
699       ative source file paths to absolute paths in the following cases:
700
701       · Source files are added to the target’s INTERFACE_SOURCES property.
702
703       · The   target’s   SOURCE_DIR   property   differs   from    CMAKE_CUR‐
704         RENT_SOURCE_DIR.
705
706       A  path  that begins with a generator expression is always left unmodi‐
707       fied.
708
709       This policy provides compatibility with projects  that  have  not  been
710       updated  to  expect this behavior.  The OLD behavior for this policy is
711       to leave all relative source file paths unmodified.  The  NEW  behavior
712       of  this  policy  is to convert relative paths to absolute according to
713       above rules.
714
715       This policy was introduced in CMake version 3.13.  CMake version 3.16.1
716       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
717       cmake_policy() command to set it to OLD or NEW explicitly.
718
719       NOTE:
720          The OLD behavior of a policy is deprecated by definition and may  be
721          removed in a future version of CMake.
722

POLICIES INTRODUCED BY CMAKE 3.12

724   CMP0075
725       Include file check macros honor CMAKE_REQUIRED_LIBRARIES.
726
727       In CMake 3.12 and above, the
728
729       · check_include_file macro in the CheckIncludeFile module, the
730
731       · check_include_file_cxx  macro  in the CheckIncludeFileCXX module, and
732         the
733
734       · check_include_files macro in the CheckIncludeFiles module
735
736       now prefer to link the check executable to the libraries listed in  the
737       CMAKE_REQUIRED_LIBRARIES  variable.  This policy provides compatibility
738       with projects that have not been updated to expect this behavior.
739
740       The OLD behavior for this policy is to ignore  CMAKE_REQUIRED_LIBRARIES
741       in  the  include file check macros.  The NEW behavior of this policy is
742       to honor CMAKE_REQUIRED_LIBRARIES in the include file check macros.
743
744       This policy was introduced in CMake version 3.12.  CMake version 3.16.1
745       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
746       cmake_policy() command to set it to OLD or NEW explicitly.
747
748       NOTE:
749          The OLD behavior of a policy is deprecated by definition and may  be
750          removed in a future version of CMake.
751
752   CMP0074
753       find_package() uses <PackageName>_ROOT variables.
754
755       In  CMake  3.12  and  above the find_package(<PackageName>) command now
756       searches prefixes specified by the  <PackageName>_ROOT  CMake  variable
757       and  the  <PackageName>_ROOT  environment  variable.  Package roots are
758       maintained as a stack so nested calls to  all  find_*  commands  inside
759       find  modules  and  config  packages also search the roots as prefixes.
760       This policy provides compatibility with projects  that  have  not  been
761       updated to avoid using <PackageName>_ROOT variables for other purposes.
762
763       The  OLD behavior for this policy is to ignore <PackageName>_ROOT vari‐
764       ables.  The NEW behavior for this policy is to  use  <PackageName>_ROOT
765       variables.
766
767       This policy was introduced in CMake version 3.12.  CMake version 3.16.1
768       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
769       cmake_policy() command to set it to OLD or NEW explicitly.
770
771       NOTE:
772          The  OLD behavior of a policy is deprecated by definition and may be
773          removed in a future version of CMake.
774
775   CMP0073
776       Do not produce legacy _LIB_DEPENDS cache entries.
777
778       Ancient CMake versions once used  <tgt>_LIB_DEPENDS  cache  entries  to
779       propagate  library link dependencies.  This has long been done by other
780       means, leaving the export_library_dependencies() command  as  the  only
781       user  of these values.  That command has long been disallowed by policy
782       CMP0033, but the <tgt>_LIB_DEPENDS cache entries were left for compati‐
783       bility with possible non-standard uses by projects.
784
785       CMake  3.12  and above now prefer to not produce these cache entries at
786       all.  This policy provides compatibility with projects  that  have  not
787       been updated to avoid using them.
788
789       The  OLD  behavior  for  this  policy is to set <tgt>_LIB_DEPENDS cache
790       entries.  The NEW behavior for this policy is to not set them.
791
792       This policy was introduced in CMake version 3.12.  Use  the  cmake_pol‐
793       icy()  command  to  set it to OLD or NEW explicitly.  Unlike most poli‐
794       cies, CMake version 3.16.1 does not warn when this policy  is  not  set
795       and simply uses OLD behavior.
796
797       NOTE:
798          The  OLD behavior of a policy is deprecated by definition and may be
799          removed in a future version of CMake.
800

POLICIES INTRODUCED BY CMAKE 3.11

802   CMP0072
803       FindOpenGL prefers GLVND by default when available.
804
805       The  FindOpenGL  module  provides   an   OpenGL::GL   target   and   an
806       OPENGL_LIBRARIES variable for projects to use for legacy GL interfaces.
807       When both a legacy GL library (e.g. libGL.so) and GLVND  libraries  for
808       OpenGL  and  GLX  (e.g.  libOpenGL.so and libGLX.so) are available, the
809       module must choose between them.  It documents an  OpenGL_GL_PREFERENCE
810       variable  that  can be used to specify an explicit preference.  When no
811       such preference is set, the module must choose a default preference.
812
813       CMake 3.11 and above prefer to choose  GLVND  libraries.   This  policy
814       provides  compatibility with projects that expect the legacy GL library
815       to be used.
816
817       The OLD behavior for this policy  is  to  set  OpenGL_GL_PREFERENCE  to
818       LEGACY.   The  NEW behavior for this policy is to set OpenGL_GL_PREFER‐
819       ENCE to GLVND.
820
821       This policy was introduced in CMake version 3.11.  CMake version 3.16.1
822       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
823       cmake_policy() command to set it to OLD or NEW explicitly.
824
825       NOTE:
826          The OLD behavior of a policy is deprecated by definition and may  be
827          removed in a future version of CMake.
828

POLICIES INTRODUCED BY CMAKE 3.10

830   CMP0071
831       Let AUTOMOC and AUTOUIC process GENERATED files.
832
833       Since  version 3.10, CMake processes regular and GENERATED source files
834       in AUTOMOC and AUTOUIC.  In earlier CMake versions, only regular source
835       files were processed.  GENERATED source files were ignored silently.
836
837       This  policy affects how source files that are GENERATED get treated in
838       AUTOMOC and AUTOUIC.
839
840       The OLD behavior for this policy is to ignore GENERATED source files in
841       AUTOMOC and AUTOUIC.
842
843       The  NEW  behavior for this policy is to process GENERATED source files
844       in AUTOMOC and AUTOUIC just like regular source files.
845
846       NOTE:
847          To silence the CMP0071 warning source files  can  be  excluded  from
848          AUTOMOC and AUTOUIC processing by setting the source file properties
849          SKIP_AUTOMOC, SKIP_AUTOUIC or SKIP_AUTOGEN.
850
851       Source skip example:
852
853          # ...
854          set_property(SOURCE /path/to/file1.h PROPERTY SKIP_AUTOMOC ON)
855          set_property(SOURCE /path/to/file2.h PROPERTY SKIP_AUTOUIC ON)
856          set_property(SOURCE /path/to/file3.h PROPERTY SKIP_AUTOGEN ON)
857          # ...
858
859       This policy was introduced in CMake version 3.10.  CMake version 3.16.1
860       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
861       cmake_policy() command to set it to OLD or NEW explicitly.
862
863       NOTE:
864          The OLD behavior of a policy is deprecated by definition and may  be
865          removed in a future version of CMake.
866
867   CMP0070
868       Define file(GENERATE) behavior for relative paths.
869
870       CMake 3.10 and newer define that relative paths given to INPUT and OUT‐
871       PUT arguments of file(GENERATE) are interpreted relative to the current
872       source  and  binary directories, respectively.  CMake 3.9 and lower did
873       not define any behavior for relative paths but did  not  diagnose  them
874       either  and  accidentally  treated them relative to the process working
875       directory.  Policy CMP0070 provides compatibility  with  projects  that
876       used the old undefined behavior.
877
878       This policy affects behavior of relative paths given to file(GENERATE).
879       The OLD behavior for this policy is to treat the paths relative to  the
880       working  directory  of  CMake.   The NEW behavior for this policy is to
881       interpret relative paths with respect to the current source  or  binary
882       directory of the caller.
883
884       This policy was introduced in CMake version 3.10.  CMake version 3.16.1
885       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
886       cmake_policy() command to set it to OLD or NEW explicitly.
887
888       NOTE:
889          The  OLD behavior of a policy is deprecated by definition and may be
890          removed in a future version of CMake.
891

POLICIES INTRODUCED BY CMAKE 3.9

893   CMP0069
894       INTERPROCEDURAL_OPTIMIZATION is enforced when enabled.
895
896       CMake 3.9 and newer prefer to add IPO flags whenever the  INTERPROCEDU‐
897       RAL_OPTIMIZATION  target  property  is  enabled and produce an error if
898       flags are not known to CMake for the current compiler.  Since  a  given
899       compiler  may  not support IPO flags in all environments in which it is
900       used, it is now the project’s responsibility to  use  the  CheckIPOSup‐
901       ported  module  to  check for support before enabling the INTERPROCEDU‐
902       RAL_OPTIMIZATION target property.  This approach allows  a  project  to
903       conditionally  activate IPO when supported.  It also allows an end user
904       to set the CMAKE_INTERPROCEDURAL_OPTIMIZATION variable in  an  environ‐
905       ment known to support IPO even if the project does not enable the prop‐
906       erty.
907
908       Since CMake 3.8 and lower only honored INTERPROCEDURAL_OPTIMIZATION for
909       the  Intel  compiler on Linux, some projects may unconditionally enable
910       the target property.  Policy CMP0069 provides compatibility  with  such
911       projects.
912
913       This policy takes effect whenever the IPO property is enabled.  The OLD
914       behavior for this policy is to add IPO flags only for Intel compiler on
915       Linux.   The  NEW  behavior for this policy is to add IPO flags for the
916       current compiler or produce an error if CMake does not know the flags.
917
918       This policy was introduced in CMake version 3.9.  CMake version  3.16.1
919       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
920       cmake_policy() command to set it to OLD or NEW explicitly.
921
922       NOTE:
923          The OLD behavior of a policy is deprecated by definition and may  be
924          removed in a future version of CMake.
925
926   Examples
927       Behave  like  CMake 3.8 and do not apply any IPO flags except for Intel
928       compiler on Linux:
929
930          cmake_minimum_required(VERSION 3.8)
931          project(foo)
932
933          # ...
934
935          set_property(TARGET ... PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE)
936
937       Use the CheckIPOSupported module to detect whether IPO is supported  by
938       the  current compiler, environment, and CMake version.  Produce a fatal
939       error if support is not available:
940
941          cmake_minimum_required(VERSION 3.9) # CMP0069 NEW
942          project(foo)
943
944          include(CheckIPOSupported)
945          check_ipo_supported()
946
947          # ...
948
949          set_property(TARGET ... PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE)
950
951       Apply IPO flags only if compiler supports it:
952
953          cmake_minimum_required(VERSION 3.9) # CMP0069 NEW
954          project(foo)
955
956          include(CheckIPOSupported)
957
958          # ...
959
960          check_ipo_supported(RESULT result)
961          if(result)
962            set_property(TARGET ... PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE)
963          endif()
964
965       Apply IPO flags without any checks.  This may lead to build  errors  if
966       IPO  is not supported by the compiler in the current environment.  Pro‐
967       duce an error if CMake does not know IPO flags  for  the  current  com‐
968       piler:
969
970          cmake_minimum_required(VERSION 3.9) # CMP0069 NEW
971          project(foo)
972
973          # ...
974
975          set_property(TARGET ... PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE)
976
977   CMP0068
978       RPATH settings on macOS do not affect install_name.
979
980       CMake  3.9  and newer remove any effect the following settings may have
981       on the install_name of a target on macOS:
982
983       · BUILD_WITH_INSTALL_RPATH target property
984
985       · SKIP_BUILD_RPATH target property
986
987       · CMAKE_SKIP_RPATH variable
988
989       · CMAKE_SKIP_INSTALL_RPATH variable
990
991       Previously, setting BUILD_WITH_INSTALL_RPATH had the effect of  setting
992       both  the install_name of a target to INSTALL_NAME_DIR and the RPATH to
993       INSTALL_RPATH.  In CMake 3.9, it only affects setting of  RPATH.   How‐
994       ever, if one wants INSTALL_NAME_DIR to apply to the target in the build
995       tree, one may set BUILD_WITH_INSTALL_NAME_DIR.
996
997       If SKIP_BUILD_RPATH, CMAKE_SKIP_RPATH or CMAKE_SKIP_INSTALL_RPATH  were
998       used  to  strip  the directory portion of the install_name of a target,
999       one may set INSTALL_NAME_DIR="" instead.
1000
1001       The OLD behavior of this policy  is  to  use  the  RPATH  settings  for
1002       install_name  on  macOS.   The NEW behavior of this policy is to ignore
1003       the RPATH settings for install_name on macOS.
1004
1005       This policy was introduced in CMake version 3.9.  CMake version  3.16.1
1006       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1007       cmake_policy() command to set it to OLD or NEW explicitly.
1008
1009       NOTE:
1010          The OLD behavior of a policy is deprecated by definition and may  be
1011          removed in a future version of CMake.
1012

POLICIES INTRODUCED BY CMAKE 3.8

1014   CMP0067
1015       Honor language standard in try_compile() source-file signature.
1016
1017       The try_compile() source file signature is intended to allow callers to
1018       check whether they will be able to compile a given source file with the
1019       current  toolchain.   In order to match compiler behavior, any language
1020       standard mode should match.  However, CMake 3.7 and below  did  not  do
1021       this.   CMake  3.8 and above prefer to honor the language standard set‐
1022       tings for C, CXX (C++), and CUDA using the values of the variables:
1023
1024       · CMAKE_C_STANDARD
1025
1026       · CMAKE_C_STANDARD_REQUIRED
1027
1028       · CMAKE_C_EXTENSIONS
1029
1030       · CMAKE_CXX_STANDARD
1031
1032       · CMAKE_CXX_STANDARD_REQUIRED
1033
1034       · CMAKE_CXX_EXTENSIONS
1035
1036       · CMAKE_CUDA_STANDARD
1037
1038       · CMAKE_CUDA_STANDARD_REQUIRED
1039
1040       · CMAKE_CUDA_EXTENSIONS
1041
1042       This policy provides compatibility for projects that do not expect  the
1043       language standard settings to be used automatically.
1044
1045       The  OLD behavior of this policy is to ignore language standard setting
1046       variables when generating the try_compile test project.  The NEW behav‐
1047       ior of this policy is to honor language standard setting variables.
1048
1049       This policy was introduced in CMake version 3.8.  Unlike most policies,
1050       CMake version 3.16.1 does not warn by default when this policy  is  not
1051       set  and simply uses OLD behavior.  See documentation of the CMAKE_POL‐
1052       ICY_WARNING_CMP0067 variable to control the warning.
1053
1054       NOTE:
1055          The OLD behavior of a policy is deprecated by definition and may  be
1056          removed in a future version of CMake.
1057

POLICIES INTRODUCED BY CMAKE 3.7

1059   CMP0066
1060       Honor per-config flags in try_compile() source-file signature.
1061
1062       The  source  file signature of the try_compile() command uses the value
1063       of the CMAKE_<LANG>_FLAGS variable in the test project so that the test
1064       compilation  works as it would in the main project.  However, CMake 3.6
1065       and below do not also honor  config-specific  compiler  flags  such  as
1066       those  in  the  CMAKE_<LANG>_FLAGS_DEBUG variable.  CMake 3.7 and above
1067       prefer to honor config-specific compiler flags too.  This  policy  pro‐
1068       vides  compatibility  for  projects  that do not expect config-specific
1069       compiler flags to be used.
1070
1071       The OLD behavior of this policy is to ignore config-specific flag vari‐
1072       ables  like  CMAKE_<LANG>_FLAGS_DEBUG  and  only  use  CMake’s built-in
1073       defaults for the current compiler and platform.
1074
1075       The NEW behavior of this policy is to honor config-specific flag  vari‐
1076       abldes like CMAKE_<LANG>_FLAGS_DEBUG.
1077
1078       This policy was introduced in CMake version 3.7.  Unlike most policies,
1079       CMake version 3.16.1 does not warn by default when this policy  is  not
1080       set  and simply uses OLD behavior.  See documentation of the CMAKE_POL‐
1081       ICY_WARNING_CMP0066 variable to control the warning.
1082
1083       NOTE:
1084          The OLD behavior of a policy is deprecated by definition and may  be
1085          removed in a future version of CMake.
1086

POLICIES INTRODUCED BY CMAKE 3.4

1088   CMP0065
1089       Do  not  add  flags  to  export  symbols  from  executables without the
1090       ENABLE_EXPORTS target property.
1091
1092       CMake 3.3 and below, for historical reasons, always linked  executables
1093       on  some platforms with flags like -rdynamic to export symbols from the
1094       executables for use by any plugins they may load via dlopen.  CMake 3.4
1095       and  above  prefer  to do this only for executables that are explicitly
1096       marked with the ENABLE_EXPORTS target property.
1097
1098       The OLD behavior of this policy is to always use  the  additional  link
1099       flags   when  linking  executables  regardless  of  the  value  of  the
1100       ENABLE_EXPORTS target property.
1101
1102       The NEW behavior of this policy is to  only  use  the  additional  link
1103       flags when linking executables if the ENABLE_EXPORTS target property is
1104       set to True.
1105
1106       This policy was introduced in CMake version 3.4.  Unlike most policies,
1107       CMake  version  3.16.1 does not warn by default when this policy is not
1108       set and simply uses OLD behavior.  See documentation of the  CMAKE_POL‐
1109       ICY_WARNING_CMP0065 variable to control the warning.
1110
1111       NOTE:
1112          The  OLD behavior of a policy is deprecated by definition and may be
1113          removed in a future version of CMake.
1114
1115   CMP0064
1116       Recognize TEST as a operator for the if() command.
1117
1118       The TEST operator was added to the if() command to determine if a given
1119       test name was created by the add_test() command.
1120
1121       The  OLD  behavior for this policy is to ignore the TEST operator.  The
1122       NEW behavior is to interpret the TEST operator.
1123
1124       This policy was introduced in CMake version 3.4.  CMake version  3.16.1
1125       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1126       cmake_policy() command to set it to OLD or NEW explicitly.
1127
1128       NOTE:
1129          The OLD behavior of a policy is deprecated by definition and may  be
1130          removed in a future version of CMake.
1131

POLICIES INTRODUCED BY CMAKE 3.3

1133   CMP0063
1134       Honor visibility properties for all target types.
1135
1136       The <LANG>_VISIBILITY_PRESET and VISIBILITY_INLINES_HIDDEN target prop‐
1137       erties affect visibility of symbols during dynamic linking.  When first
1138       introduced  these  properties  affected  compilation of sources only in
1139       shared  libraries,  module  libraries,   and   executables   with   the
1140       ENABLE_EXPORTS  property  set.   This  was sufficient for the basic use
1141       cases of shared libraries and executables with plugins.  However,  some
1142       sources may be compiled as part of static libraries or object libraries
1143       and then linked into a shared library later.  CMake 3.3 and above  pre‐
1144       fer to honor these properties for sources compiled in all target types.
1145       This policy preserves compatibility for projects expecting the  proper‐
1146       ties to work only for some target types.
1147
1148       The OLD behavior for this policy is to ignore the visibility properties
1149       for  static  libraries,  object  libraries,  and  executables   without
1150       exports.   The  NEW behavior for this policy is to honor the visibility
1151       properties for all target types.
1152
1153       This policy was introduced in CMake version 3.3.  CMake version  3.16.1
1154       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1155       cmake_policy() command to set it to OLD or NEW explicitly.
1156
1157       NOTE:
1158          The OLD behavior of a policy is deprecated by definition and may  be
1159          removed in a future version of CMake.
1160
1161   CMP0062
1162       Disallow install() of export() result.
1163
1164       The  export()  command  generates  a  file containing Imported Targets,
1165       which is suitable for use from the build directory.  It is not suitable
1166       for  installation  because  it  contains  absolute paths to buildsystem
1167       locations, and is particular to a single build configuration.
1168
1169       The install(EXPORT) generates and installs files which contain Imported
1170       Targets.   These  files  are  generated with relative paths (unless the
1171       user specifies absolute paths), and are designed  for  multi-configura‐
1172       tion use.  See Creating Packages for more.
1173
1174       CMake  3.3  no longer allows the use of the install(FILES) command with
1175       the result of the export() command.
1176
1177       The OLD behavior for this policy is to allow installing the  result  of
1178       an  export() command.  The NEW behavior for this policy is not to allow
1179       installing the result of an export() command.
1180
1181       This policy was introduced in CMake version 3.3.  CMake version  3.16.1
1182       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1183       cmake_policy() command to set it to OLD or NEW explicitly.
1184
1185       NOTE:
1186          The OLD behavior of a policy is deprecated by definition and may  be
1187          removed in a future version of CMake.
1188
1189   CMP0061
1190       CTest does not by default tell make to ignore errors (-i).
1191
1192       The ctest_build() and build_command() commands no longer generate build
1193       commands for Makefile Generators with the -i option.   Previously  this
1194       was  done  to  help build as much of tested projects as possible.  How‐
1195       ever, this behavior is not consistent with other  generators  and  also
1196       causes the return code of the make tool to be meaningless.
1197
1198       Of  course  users  may  still  add  this  option  manually  by  setting
1199       CTEST_BUILD_COMMAND or the MAKECOMMAND  cache  entry.   See  the  CTest
1200       Build Step MakeCommand setting documentation for their effects.
1201
1202       The  OLD  behavior for this policy is to add -i to make calls in CTest.
1203       The NEW behavior for this policy is to not add -i.
1204
1205       This policy was introduced in CMake version 3.3.  Unlike most policies,
1206       CMake version 3.16.1 does not warn when this policy is not set and sim‐
1207       ply uses OLD behavior.
1208
1209       NOTE:
1210          The OLD behavior of a policy is deprecated by definition and may  be
1211          removed in a future version of CMake.
1212
1213   CMP0060
1214       Link libraries by full path even in implicit directories.
1215
1216       Policy  CMP0003  was  introduced  with  the intention of always linking
1217       library files by full path when a  full  path  is  given  to  the  tar‐
1218       get_link_libraries()  command.  However, on some platforms (e.g. HP-UX)
1219       the compiler front-end adds alternative library search  paths  for  the
1220       current   architecture   (e.g.   /usr/lib/<arch>  has  alternatives  to
1221       libraries in /usr/lib for the current architecture).  On such platforms
1222       the  find_library()  may find a library such as /usr/lib/libfoo.so that
1223       does not belong to the current architecture.
1224
1225       Prior to policy CMP0003  projects  would  still  build  in  such  cases
1226       because  the  incorrect library path would be converted to -lfoo on the
1227       link line and the linker would find the proper library in the arch-spe‐
1228       cific  search  path  provided by the compiler front-end implicitly.  At
1229       the time we chose to remain compatible with  such  projects  by  always
1230       converting  library  files  found in implicit link directories to -lfoo
1231       flags to ask the linker to search  for  them.   This  approach  allowed
1232       existing projects to continue to build while still linking to libraries
1233       outside implicit link directories via full path (such as those  in  the
1234       build tree).
1235
1236       CMake  does  allow  projects  to  override  this  behavior  by using an
1237       IMPORTED library target with its IMPORTED_LOCATION property set to  the
1238       desired  full  path  to a library file.  In fact, many Find Modules are
1239       learning to provide Imported Targets instead of  just  the  traditional
1240       Foo_LIBRARIES  variable listing library files.  However, this makes the
1241       link line generated for a library found by  a  Find  Module  depend  on
1242       whether it is linked through an imported target or not, which is incon‐
1243       sistent.  Furthermore, this behavior has been  a  source  of  confusion
1244       because the generated link line for a library file depends on its loca‐
1245       tion.  It is also problematic for projects trying  to  link  statically
1246       because flags like -Wl,-Bstatic -lfoo -Wl,-Bdynamic may be used to help
1247       the linker select libfoo.a instead of libfoo.so but then  leak  dynamic
1248       linking to following libraries.  (See the LINK_SEARCH_END_STATIC target
1249       property for a solution typically used for that problem.)
1250
1251       When the special case for libraries in implicit  link  directories  was
1252       first  introduced  the  list  of  implicit  link directories was simply
1253       hard-coded (e.g. /lib, /usr/lib, and a few others).  Since  that  time,
1254       CMake  has  learned to detect the implicit link directories used by the
1255       compiler front-end.  If necessary, the find_library() command could  be
1256       taught  to  use  this  information to help find libraries of the proper
1257       architecture.
1258
1259       For these reasons, CMake 3.3 and above prefer to drop the special  case
1260       and  link  libraries  by  full path even when they are in implicit link
1261       directories.   Policy  CMP0060  provides  compatibility  for   existing
1262       projects.
1263
1264       The  OLD  behavior  for  this policy is to ask the linker to search for
1265       libraries whose full paths are known to be in  implicit  link  directo‐
1266       ries.   The  NEW  behavior for this policy is to link libraries by full
1267       path even if they are in implicit link directories.
1268
1269       This policy was introduced in CMake version 3.3.  Unlike most policies,
1270       CMake  version  3.16.1 does not warn by default when this policy is not
1271       set and simply uses OLD behavior.  See documentation of the  CMAKE_POL‐
1272       ICY_WARNING_CMP0060 variable to control the warning.
1273
1274       NOTE:
1275          The  OLD behavior of a policy is deprecated by definition and may be
1276          removed in a future version of CMake.
1277
1278   CMP0059
1279       Do not treat DEFINITIONS as a built-in directory property.
1280
1281       CMake 3.3 and above no longer make  a  list  of  definitions  available
1282       through  the  DEFINITIONS  directory property.  The COMPILE_DEFINITIONS
1283       directory property may be used instead.
1284
1285       The OLD behavior for this policy is to provide the list of flags  given
1286       so far to the add_definitions() command.  The NEW behavior is to behave
1287       as a normal user-defined directory property.
1288
1289       This policy was introduced in CMake version 3.3.  CMake version  3.16.1
1290       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1291       cmake_policy() command to set it to OLD or NEW explicitly.
1292
1293       NOTE:
1294          The OLD behavior of a policy is deprecated by definition and may  be
1295          removed in a future version of CMake.
1296
1297   CMP0058
1298       Ninja requires custom command byproducts to be explicit.
1299
1300       When  an intermediate file generated during the build is consumed by an
1301       expensive operation or a large tree of dependents, one may  reduce  the
1302       work  needed  for an incremental rebuild by updating the file timestamp
1303       only when its content changes.  With this approach the generation  rule
1304       must  have  a  separate  output  file that is always updated with a new
1305       timestamp that is newer than any dependencies of the rule so  that  the
1306       build  tool  re-runs the rule only when the input changes.  We refer to
1307       the separate output file as a rule’s witness and the generated file  as
1308       a rule’s byproduct.
1309
1310       Byproducts  may  not  be listed as outputs because their timestamps are
1311       allowed to be older than the inputs.  No build tools (like  make)  that
1312       existed  when  CMake  was  designed  have  a way to express byproducts.
1313       Therefore CMake versions prior to 3.2  had  no  way  to  specify  them.
1314       Projects  typically left byproducts undeclared in the rules that gener‐
1315       ate them.  For example:
1316
1317          add_custom_command(
1318            OUTPUT witness.txt
1319            COMMAND ${CMAKE_COMMAND} -E copy_if_different
1320                    ${CMAKE_CURRENT_SOURCE_DIR}/input.txt
1321                    byproduct.txt # timestamp may not change
1322            COMMAND ${CMAKE_COMMAND} -E touch witness.txt
1323            DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/input.txt
1324            )
1325          add_custom_target(Provider DEPENDS witness.txt)
1326          add_custom_command(
1327            OUTPUT generated.c
1328            COMMAND expensive-task -i byproduct.txt -o generated.c
1329            DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/byproduct.txt
1330            )
1331          add_library(Consumer generated.c)
1332          add_dependencies(Consumer Provider)
1333
1334       This works well for all generators except Ninja.  The Ninja build  tool
1335       sees  a  rule listing byproduct.txt as a dependency and no rule listing
1336       it as an output.  Ninja then complains that there is no way to  satisfy
1337       the  dependency  and  stops  building  even though there are order-only
1338       dependencies that ensure byproduct.txt will exist before its  consumers
1339       need it.  See discussion of this problem in Ninja Issue 760 for further
1340       details on why Ninja works this way.
1341
1342       Instead of leaving byproducts undeclared in  the  rules  that  generate
1343       them,  Ninja  expects byproducts to be listed along with other outputs.
1344       Such rules may be marked with a restat option that tells Ninja to check
1345       the  timestamps  of outputs after the rules run.  This prevents byprod‐
1346       ucts whose timestamps do not change from causing  their  dependents  to
1347       re-build unnecessarily.
1348
1349       Since the above approach does not tell CMake what custom command gener‐
1350       ates byproduct.txt, the Ninja generator does not have  enough  informa‐
1351       tion  to  add the byproduct as an output of any rule.  CMake 2.8.12 and
1352       above work around this problem  and  allow  projects  using  the  above
1353       approach to build by generating phony build rules to tell Ninja to tol‐
1354       erate such missing files.  However, this workaround prevents Ninja from
1355       diagnosing  a  dependency that is really missing.  It also works poorly
1356       in in-source builds where every  custom  command  dependency,  even  on
1357       source  files, needs to be treated this way because CMake does not have
1358       enough information to know which files are generated as  byproducts  of
1359       custom commands.
1360
1361       CMake  3.2 introduced the BYPRODUCTS option to the add_custom_command()
1362       and add_custom_target() commands.  This option allows byproducts to  be
1363       specified explicitly:
1364
1365          add_custom_command(
1366            OUTPUT witness.txt
1367            BYPRODUCTS byproduct.txt # explicit byproduct specification
1368            COMMAND ${CMAKE_COMMAND} -E copy_if_different
1369                    ${CMAKE_CURRENT_SOURCE_DIR}/input.txt
1370                    byproduct.txt # timestamp may not change
1371          ...
1372
1373       The BYPRODUCTS option is used by the Ninja generator to list byproducts
1374       among the outputs of the custom commands that  generate  them,  and  is
1375       ignored by other generators.
1376
1377       CMake  3.3  and above prefer to require projects to specify custom com‐
1378       mand byproducts explicitly so that it can avoid using  the  phony  rule
1379       workaround  altogether.   Policy CMP0058 was introduced to provide com‐
1380       patibility with existing projects that still need the workaround.
1381
1382       This policy has no effect on generators  other  than  Ninja.   The  OLD
1383       behavior  for  this policy is to generate Ninja phony rules for unknown
1384       dependencies in the build tree.  The NEW behavior for this policy is to
1385       not  generate these and instead require projects to specify custom com‐
1386       mand BYPRODUCTS explicitly.
1387
1388       This policy was introduced in CMake version 3.3.  CMake version  3.16.1
1389       warns when it sees unknown dependencies in out-of-source build trees if
1390       the policy is not set and then uses OLD behavior.  Use  the  cmake_pol‐
1391       icy()  command  to set the policy to OLD or NEW explicitly.  The policy
1392       setting must be in scope at the end  of  the  top-level  CMakeLists.txt
1393       file of the project and has global effect.
1394
1395       NOTE:
1396          The  OLD behavior of a policy is deprecated by definition and may be
1397          removed in a future version of CMake.
1398
1399   CMP0057
1400       Support new if() IN_LIST operator.
1401
1402       CMake 3.3 adds support for the new IN_LIST operator.
1403
1404       The OLD behavior for this policy is to  ignore  the  IN_LIST  operator.
1405       The NEW behavior is to interpret the IN_LIST operator.
1406
1407       This  policy was introduced in CMake version 3.3.  CMake version 3.16.1
1408       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1409       cmake_policy() command to set it to OLD or NEW explicitly.
1410
1411       NOTE:
1412          The  OLD behavior of a policy is deprecated by definition and may be
1413          removed in a future version of CMake.
1414

POLICIES INTRODUCED BY CMAKE 3.2

1416   CMP0056
1417       Honor link flags in try_compile() source-file signature.
1418
1419       The try_compile() command  source-file  signature  generates  a  CMake‐
1420       Lists.txt  file  to build the source file into an executable.  In order
1421       to compile the source the same way as it might be compiled by the call‐
1422       ing   project,   the   generated   project   sets   the  value  of  the
1423       CMAKE_<LANG>_FLAGS variable to that in the calling project.  The  value
1424       of the CMAKE_EXE_LINKER_FLAGS variable may be needed in some cases too,
1425       but CMake 3.1 and lower did not set it in the generated project.  CMake
1426       3.2 and above prefer to set it so that linker flags are honored as well
1427       as compiler flags.  This policy provides compatibility with the pre-3.2
1428       behavior.
1429
1430       The  OLD  behavior  for  this  policy  is  to  not set the value of the
1431       CMAKE_EXE_LINKER_FLAGS variable in the generated test project.  The NEW
1432       behavior   for   this   policy   is   to   set   the   value   of   the
1433       CMAKE_EXE_LINKER_FLAGS variable in the test project to the same  as  it
1434       is in the calling project.
1435
1436       If  the  project code does not set the policy explicitly, users may set
1437       it on the command line  by  defining  the  CMAKE_POLICY_DEFAULT_CMP0056
1438       variable in the cache.
1439
1440       This policy was introduced in CMake version 3.2.  Unlike most policies,
1441       CMake version 3.16.1 does not warn by default when this policy  is  not
1442       set  and simply uses OLD behavior.  See documentation of the CMAKE_POL‐
1443       ICY_WARNING_CMP0056 variable to control the warning.
1444
1445       NOTE:
1446          The OLD behavior of a policy is deprecated by definition and may  be
1447          removed in a future version of CMake.
1448
1449   CMP0055
1450       Strict checking for the break() command.
1451
1452       CMake  3.1  and lower allowed calls to the break() command outside of a
1453       loop context and also ignored any given arguments.  This was  undefined
1454       behavior.
1455
1456       The  OLD behavior for this policy is to allow break() to be placed out‐
1457       side of loop contexts and ignores any arguments.  The NEW behavior  for
1458       this  policy is to issue an error if a misplaced break or any arguments
1459       are found.
1460
1461       This policy was introduced in CMake version 3.2.  CMake version  3.16.1
1462       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1463       cmake_policy() command to set it to OLD or NEW explicitly.
1464
1465       NOTE:
1466          The OLD behavior of a policy is deprecated by definition and may  be
1467          removed in a future version of CMake.
1468

POLICIES INTRODUCED BY CMAKE 3.1

1470   CMP0054
1471       Only interpret if() arguments as variables or keywords when unquoted.
1472
1473       CMake  3.1  and  above  no  longer  implicitly dereference variables or
1474       interpret keywords in an if() command argument  when  it  is  a  Quoted
1475       Argument or a Bracket Argument.
1476
1477       The OLD behavior for this policy is to dereference variables and inter‐
1478       pret keywords even if they are quoted or bracketed.  The  NEW  behavior
1479       is  to  not  dereference variables or interpret keywords that have been
1480       quoted or bracketed.
1481
1482       Given the following partial example:
1483
1484          set(A E)
1485          set(E "")
1486
1487          if("${A}" STREQUAL "")
1488            message("Result is TRUE before CMake 3.1 or when CMP0054 is OLD")
1489          else()
1490            message("Result is FALSE in CMake 3.1 and above if CMP0054 is NEW")
1491          endif()
1492
1493       After explicit expansion of variables this gives:
1494
1495          if("E" STREQUAL "")
1496
1497       With the policy set to OLD implicit expansion reduces this semantically
1498       to:
1499
1500          if("" STREQUAL "")
1501
1502       With  the  policy  set  to NEW the quoted arguments will not be further
1503       dereferenced:
1504
1505          if("E" STREQUAL "")
1506
1507       This policy was introduced in CMake version 3.1.  CMake version  3.16.1
1508       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1509       cmake_policy() command to set it to OLD or NEW explicitly.
1510
1511       NOTE:
1512          The OLD behavior of a policy is deprecated by definition and may  be
1513          removed in a future version of CMake.
1514
1515   CMP0053
1516       Simplify variable reference and escape sequence evaluation.
1517
1518       CMake  3.1 introduced a much faster implementation of evaluation of the
1519       Variable References and Escape Sequences documented in  the  cmake-lan‐
1520       guage(7)  manual.  While the behavior is identical to the legacy imple‐
1521       mentation in most cases, some corner cases were cleaned up to  simplify
1522       the behavior.  Specifically:
1523
1524       · Expansion  of  @VAR@ reference syntax defined by the configure_file()
1525         and string(CONFIGURE) commands is no longer performed in  other  con‐
1526         texts.
1527
1528       · Literal ${VAR} reference syntax may contain only alphanumeric charac‐
1529         ters (A-Z, a-z, 0-9) and the characters _, ., /, -, and +.  Note that
1530         $  is technically allowed in the NEW behavior, but is invalid for OLD
1531         behavior.  This is due to an oversight during the  implementation  of
1532         CMP0053  and  its  use as a literal variable reference is discouraged
1533         for this reason.  Variables with other characters in their  name  may
1534         still be referenced indirectly, e.g.
1535
1536            set(varname "otherwise & disallowed $ characters")
1537            message("${${varname}}")
1538
1539       · The setting of policy CMP0010 is not considered, so improper variable
1540         reference syntax is always an error.
1541
1542       · More characters are allowed to be escaped in variable names.   Previ‐
1543         ously,  only  ()#"  \@^  were  valid  characters  to  escape. Now any
1544         non-alphanumeric, non-semicolon, non-NUL  character  may  be  escaped
1545         following the escape_identity production in the Escape Sequences sec‐
1546         tion of the cmake-language(7) manual.
1547
1548       The OLD behavior for this policy is to honor the  legacy  behavior  for
1549       variable  references  and escape sequences.  The NEW behavior is to use
1550       the simpler variable expansion and escape sequence evaluation rules.
1551
1552       This policy was introduced in CMake version 3.1.  CMake version  3.16.1
1553       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1554       cmake_policy() command to set it to OLD or NEW explicitly.
1555
1556       NOTE:
1557          The OLD behavior of a policy is deprecated by definition and may  be
1558          removed in a future version of CMake.
1559
1560   CMP0052
1561       Reject  source  and  build dirs in installed INTERFACE_INCLUDE_DIRECTO‐
1562       RIES.
1563
1564       CMake 3.0 and lower allowed subdirectories of the source  directory  or
1565       build directory to be in the INTERFACE_INCLUDE_DIRECTORIES of installed
1566       and exported targets, if the directory was also a subdirectory  of  the
1567       installation  prefix.   This makes the installation depend on the exis‐
1568       tence of the source dir or binary dir, and  the  installation  will  be
1569       broken if either are removed after installation.
1570
1571       See  Include  Directories and Usage Requirements for more on specifying
1572       include directories for targets.
1573
1574       The OLD behavior for this policy is to export the content of the INTER‐
1575       FACE_INCLUDE_DIRECTORIES  with the source or binary directory.  The NEW
1576       behavior for this policy is to issue an error if such  a  directory  is
1577       used.
1578
1579       This  policy was introduced in CMake version 3.1.  CMake version 3.16.1
1580       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1581       cmake_policy() command to set it to OLD or NEW explicitly.
1582
1583       NOTE:
1584          The  OLD behavior of a policy is deprecated by definition and may be
1585          removed in a future version of CMake.
1586
1587   CMP0051
1588       List TARGET_OBJECTS in SOURCES target property.
1589
1590       CMake 3.0 and  lower  did  not  include  the  TARGET_OBJECTS  generator
1591       expression when returning the SOURCES target property.
1592
1593       Configure-time  CMake code is not able to handle generator expressions.
1594       If using the SOURCES target property at configure time, it may be  nec‐
1595       essary    to    first    remove   generator   expressions   using   the
1596       string(GENEX_STRIP)  command.   Generate-time  CMake   code   such   as
1597       file(GENERATE) can handle the content without stripping.
1598
1599       The  OLD behavior for this policy is to omit TARGET_OBJECTS expressions
1600       from the SOURCES target property.  The NEW behavior for this policy  is
1601       to include TARGET_OBJECTS expressions in the output.
1602
1603       This  policy was introduced in CMake version 3.1.  CMake version 3.16.1
1604       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1605       cmake_policy() command to set it to OLD or NEW explicitly.
1606
1607       NOTE:
1608          The  OLD behavior of a policy is deprecated by definition and may be
1609          removed in a future version of CMake.
1610

POLICIES INTRODUCED BY CMAKE 3.0

1612   CMP0050
1613       Disallow add_custom_command SOURCE signatures.
1614
1615       CMake 2.8.12 and lower allowed  a  signature  for  add_custom_command()
1616       which specified an input to a command.  This was undocumented behavior.
1617       Modern use of CMake  associates  custom  commands  with  their  output,
1618       rather than their input.
1619
1620       The OLD behavior for this policy is to allow the use of add_custom_com‐
1621       mand() SOURCE signatures.  The NEW behavior for this policy is to issue
1622       an error if such a signature is used.
1623
1624       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1625       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1626       cmake_policy() command to set it to OLD or NEW explicitly.
1627
1628       NOTE:
1629          The  OLD behavior of a policy is deprecated by definition and may be
1630          removed in a future version of CMake.
1631
1632   CMP0049
1633       Do not expand variables in target source entries.
1634
1635       CMake 2.8.12 and lower performed an extra layer of  variable  expansion
1636       when evaluating source file names:
1637
1638          set(a_source foo.c)
1639          add_executable(foo \${a_source})
1640
1641       This was undocumented behavior.
1642
1643       The  OLD behavior for this policy is to expand such variables when pro‐
1644       cessing the target sources.  The NEW behavior for  this  policy  is  to
1645       issue an error if such variables need to be expanded.
1646
1647       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1648       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1649       cmake_policy() command to set it to OLD or NEW explicitly.
1650
1651       NOTE:
1652          The  OLD behavior of a policy is deprecated by definition and may be
1653          removed in a future version of CMake.
1654
1655   CMP0048
1656       The project() command manages VERSION variables.
1657
1658       CMake version 3.0 introduced the VERSION option of the  project()  com‐
1659       mand  to  specify  a  project version as well as the name.  In order to
1660       keep PROJECT_VERSION and related  variables  consistent  with  variable
1661       PROJECT_NAME  it is necessary to set the VERSION variables to the empty
1662       string when no VERSION is given to project().  However, this can change
1663       behavior  for  existing  projects that set VERSION variables themselves
1664       since project() may now clear them.  This policy controls the  behavior
1665       for compatibility with such projects.
1666
1667       The  OLD  behavior  for  this  policy  is  to  leave  VERSION variables
1668       untouched.  The NEW behavior for this policy is to set VERSION as docu‐
1669       mented by the project() command.
1670
1671       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1672       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1673       cmake_policy() command to set it to OLD or NEW explicitly.
1674
1675       NOTE:
1676          The  OLD behavior of a policy is deprecated by definition and may be
1677          removed in a future version of CMake.
1678
1679   CMP0047
1680       Use QCC compiler id for the qcc drivers on QNX.
1681
1682       CMake 3.0 and above recognize that the QNX qcc compiler driver is  dif‐
1683       ferent  from  the  GNU  compiler.  CMake now prefers to present this to
1684       projects  by  setting  the  CMAKE_<LANG>_COMPILER_ID  variable  to  QCC
1685       instead  of GNU.  However, existing projects may assume the compiler id
1686       for QNX qcc is just GNU as it was  in  CMake  versions  prior  to  3.0.
1687       Therefore  this  policy  determines  for  QNX  qcc which compiler id to
1688       report in the CMAKE_<LANG>_COMPILER_ID variable after  language  <LANG>
1689       is  enabled  by the project() or enable_language() command.  The policy
1690       must be set prior to the invocation of either command.
1691
1692       The OLD behavior for this policy is to use the GNU compiler id for  the
1693       qcc  and  QCC  compiler drivers. The NEW behavior for this policy is to
1694       use the QCC compiler id for those drivers.
1695
1696       This policy was introduced in CMake version 3.0.   Use  the  cmake_pol‐
1697       icy() command to set this policy to OLD or NEW explicitly.  Unlike most
1698       policies, CMake version 3.16.1 does not warn by default when this  pol‐
1699       icy  is not set and simply uses OLD behavior.  See documentation of the
1700       CMAKE_POLICY_WARNING_CMP0047 variable to control the warning.
1701
1702       NOTE:
1703          The OLD behavior of a policy is deprecated by definition and may  be
1704          removed in a future version of CMake.
1705
1706   CMP0046
1707       Error on non-existent dependency in add_dependencies.
1708
1709       CMake  2.8.12  and  lower  silently  ignored  non-existent dependencies
1710       listed in the add_dependencies() command.
1711
1712       The OLD behavior for this policy is  to  silently  ignore  non-existent
1713       dependencies. The NEW behavior for this policy is to report an error if
1714       non-existent dependencies are listed in the add_dependencies() command.
1715
1716       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1717       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1718       cmake_policy() command to set it to OLD or NEW explicitly.
1719
1720       NOTE:
1721          The OLD behavior of a policy is deprecated by definition and may  be
1722          removed in a future version of CMake.
1723
1724   CMP0045
1725       Error on non-existent target in get_target_property.
1726
1727       In CMake 2.8.12 and lower, the get_target_property() command accepted a
1728       non-existent target argument without issuing any error or warning.  The
1729       result variable is set to a -NOTFOUND value.
1730
1731       The  OLD  behavior  for  this policy is to issue no warning and set the
1732       result variable to a -NOTFOUND value.  The NEW behavior for this policy
1733       is  to issue a FATAL_ERROR if the command is called with a non-existent
1734       target.
1735
1736       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1737       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1738       cmake_policy() command to set it to OLD or NEW explicitly.
1739
1740       NOTE:
1741          The OLD behavior of a policy is deprecated by definition and may  be
1742          removed in a future version of CMake.
1743
1744   CMP0044
1745       Case sensitive <LANG>_COMPILER_ID generator expressions
1746
1747       CMake 2.8.12 introduced the <LANG>_COMPILER_ID generator expressions to
1748       allow comparison of the CMAKE_<LANG>_COMPILER_ID  with  a  test  value.
1749       The  possible  valid  values are lowercase, but the comparison with the
1750       test value was performed case-insensitively.
1751
1752       The OLD behavior for this policy is to perform a case-insensitive  com‐
1753       parison  with  the  value in the <LANG>_COMPILER_ID expression. The NEW
1754       behavior for this policy is to perform a case-sensitive comparison with
1755       the value in the <LANG>_COMPILER_ID expression.
1756
1757       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1758       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1759       cmake_policy() command to set it to OLD or NEW explicitly.
1760
1761       NOTE:
1762          The  OLD behavior of a policy is deprecated by definition and may be
1763          removed in a future version of CMake.
1764
1765   CMP0043
1766       Ignore COMPILE_DEFINITIONS_<Config> properties
1767
1768       CMake 2.8.12 and lower allowed setting the COMPILE_DEFINITIONS_<CONFIG>
1769       target  property and COMPILE_DEFINITIONS_<CONFIG> directory property to
1770       apply configuration-specific compile definitions.
1771
1772       Since CMake 2.8.10, the COMPILE_DEFINITIONS property has supported gen‐
1773       erator  expressions  for  setting configuration-dependent content.  The
1774       continued existence of the suffixed variables is redundant, and  causes
1775       a  maintenance  burden.   Population  of  the COMPILE_DEFINITIONS_DEBUG
1776       property may be  replaced  with  a  population  of  COMPILE_DEFINITIONS
1777       directly or via target_compile_definitions():
1778
1779          # Old Interfaces:
1780          set_property(TARGET tgt APPEND PROPERTY
1781            COMPILE_DEFINITIONS_DEBUG DEBUG_MODE
1782          )
1783          set_property(DIRECTORY APPEND PROPERTY
1784            COMPILE_DEFINITIONS_DEBUG DIR_DEBUG_MODE
1785          )
1786
1787          # New Interfaces:
1788          set_property(TARGET tgt APPEND PROPERTY
1789            COMPILE_DEFINITIONS $<$<CONFIG:Debug>:DEBUG_MODE>
1790          )
1791          target_compile_definitions(tgt PRIVATE $<$<CONFIG:Debug>:DEBUG_MODE>)
1792          set_property(DIRECTORY APPEND PROPERTY
1793            COMPILE_DEFINITIONS $<$<CONFIG:Debug>:DIR_DEBUG_MODE>
1794          )
1795
1796       The  OLD behavior for this policy is to consume the content of the suf‐
1797       fixed COMPILE_DEFINITIONS_<CONFIG> target property when generating  the
1798       compilation  command. The NEW behavior for this policy is to ignore the
1799       content of the COMPILE_DEFINITIONS_<CONFIG> target property .
1800
1801       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1802       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1803       cmake_policy() command to set it to OLD or NEW explicitly.
1804
1805       NOTE:
1806          The OLD behavior of a policy is deprecated by definition and may  be
1807          removed in a future version of CMake.
1808
1809   CMP0042
1810       MACOSX_RPATH is enabled by default.
1811
1812       CMake  2.8.12  and  newer  has  support  for using @rpath in a target’s
1813       install  name.   This  was  enabled  by  setting  the  target  property
1814       MACOSX_RPATH.   The  @rpath  in  an install name is a more flexible and
1815       powerful mechanism than @executable_path or @loader_path  for  locating
1816       shared libraries.
1817
1818       CMake 3.0 and later prefer this property to be ON by default.  Projects
1819       wanting @rpath in a target’s install name may remove any setting of the
1820       INSTALL_NAME_DIR and CMAKE_INSTALL_NAME_DIR variables.
1821
1822       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1823       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1824       cmake_policy() command to set it to OLD or NEW explicitly.
1825
1826       NOTE:
1827          The  OLD behavior of a policy is deprecated by definition and may be
1828          removed in a future version of CMake.
1829
1830   CMP0041
1831       Error on relative include with generator expression.
1832
1833       Diagnostics in CMake 2.8.12 and lower silently ignored an entry in  the
1834       INTERFACE_INCLUDE_DIRECTORIES  of  a target if it contained a generator
1835       expression at any position.
1836
1837       The path entries in  that  target  property  should  not  be  relative.
1838       High-level  API  should ensure that by adding either a source directory
1839       or a install directory prefix, as appropriate.
1840
1841       As an additional diagnostic, the  INTERFACE_INCLUDE_DIRECTORIES  gener‐
1842       ated  on an IMPORTED target for the install location should not contain
1843       paths in the source directory or the build directory.
1844
1845       The OLD behavior for this policy is to ignore relative path entries  if
1846       they  contain  a generator expression. The NEW behavior for this policy
1847       is to report an error if a  generator  expression  appears  in  another
1848       location and the path is relative.
1849
1850       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1851       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1852       cmake_policy() command to set it to OLD or NEW explicitly.
1853
1854       NOTE:
1855          The  OLD behavior of a policy is deprecated by definition and may be
1856          removed in a future version of CMake.
1857
1858   CMP0040
1859       The target in the TARGET signature of add_custom_command()  must  exist
1860       and must be defined in the current directory.
1861
1862       CMake  2.8.12  and lower silently ignored a custom command created with
1863       the TARGET signature of add_custom_command() if the target  is  unknown
1864       or was defined outside the current directory.
1865
1866       The  OLD  behavior  for  this  policy  is to ignore custom commands for
1867       unknown targets.  The NEW behavior for this  policy  is  to  report  an
1868       error  if  the  target referenced in add_custom_command() is unknown or
1869       was defined outside the current directory.
1870
1871       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1872       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1873       cmake_policy() command to set it to OLD or NEW explicitly.
1874
1875       NOTE:
1876          The OLD behavior of a policy is deprecated by definition and may  be
1877          removed in a future version of CMake.
1878
1879   CMP0039
1880       Utility targets may not have link dependencies.
1881
1882       CMake  2.8.12  and lower allowed using utility targets in the left hand
1883       side position of the target_link_libraries() command. This is an  indi‐
1884       cator of a bug in user code.
1885
1886       The  OLD behavior for this policy is to ignore attempts to set the link
1887       libraries of utility targets.  The NEW behavior for this policy  is  to
1888       report  an  error  if an attempt is made to set the link libraries of a
1889       utility target.
1890
1891       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1892       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1893       cmake_policy() command to set it to OLD or NEW explicitly.
1894
1895       NOTE:
1896          The OLD behavior of a policy is deprecated by definition and may  be
1897          removed in a future version of CMake.
1898
1899   CMP0038
1900       Targets may not link directly to themselves.
1901
1902       CMake  2.8.12  and  lower  allowed  a  build  target  to link to itself
1903       directly with a target_link_libraries() call. This is an indicator of a
1904       bug in user code.
1905
1906       The  OLD behavior for this policy is to ignore targets which list them‐
1907       selves in their own link implementation.  The  NEW  behavior  for  this
1908       policy is to report an error if a target attempts to link to itself.
1909
1910       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1911       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1912       cmake_policy() command to set it to OLD or NEW explicitly.
1913
1914       NOTE:
1915          The  OLD behavior of a policy is deprecated by definition and may be
1916          removed in a future version of CMake.
1917
1918   CMP0037
1919       Target names should not be reserved and should match  a  validity  pat‐
1920       tern.
1921
1922       CMake  2.8.12  and  lower allowed creating targets using add_library(),
1923       add_executable() and add_custom_target() with unrestricted  choice  for
1924       the  target name.  Newer cmake features such as cmake-generator-expres‐
1925       sions(7) and some diagnostics expect target names to match a restricted
1926       pattern.
1927
1928       Target  names  may  contain  upper and lower case letters, numbers, the
1929       underscore character (_), dot(.), plus(+) and minus(-).  As  a  special
1930       case, ALIAS and IMPORTED targets may contain two consecutive colons.
1931
1932       Target  names reserved by one or more CMake generators are not allowed.
1933       Among others these include all, clean, help, and install.
1934
1935       Target names associated with optional features, such as test and  pack‐
1936       age,  may  also be reserved.  CMake 3.10 and below always reserve them.
1937       CMake 3.11 and above reserve them only when the  corresponding  feature
1938       is enabled (e.g. by including the CTest or CPack modules).
1939
1940       The  OLD  behavior  for  this  policy is to allow creating targets with
1941       reserved names or which do not match the  validity  pattern.   The  NEW
1942       behavior  for  this policy is to report an error if an add_* command is
1943       used with an invalid target name.
1944
1945       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1946       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1947       cmake_policy() command to set it to OLD or NEW explicitly.
1948
1949       NOTE:
1950          The OLD behavior of a policy is deprecated by definition and may  be
1951          removed in a future version of CMake.
1952
1953   CMP0036
1954       The build_name() command should not be called.
1955
1956       This  command  was  added in May 2001 to compute a name for the current
1957       operating system and compiler combination.  The command has  long  been
1958       documented   as  discouraged  and  replaced  by  the  CMAKE_SYSTEM  and
1959       CMAKE_<LANG>_COMPILER variables.
1960
1961       CMake >= 3.0 prefer that this command never be called.  The OLD  behav‐
1962       ior  for  this  policy  is  to allow the command to be called.  The NEW
1963       behavior for this policy is to issue a FATAL_ERROR when the command  is
1964       called.
1965
1966       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
1967       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
1968       cmake_policy() command to set it to OLD or NEW explicitly.
1969
1970       NOTE:
1971          The  OLD behavior of a policy is deprecated by definition and may be
1972          removed in a future version of CMake.
1973
1974   CMP0035
1975       The variable_requires() command should not be called.
1976
1977       This command was introduced in November 2001  to  perform  some  condi‐
1978       tional logic.  It has long been replaced by the if() command.
1979
1980       CMake  >= 3.0 prefer that this command never be called.  The OLD behav‐
1981       ior for this policy is to allow the command  to  be  called.   The  NEW
1982       behavior  for this policy is to issue a FATAL_ERROR when the command is
1983       called.
1984
1985       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
1986       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
1987       cmake_policy() command to set it to OLD or NEW explicitly.
1988
1989       NOTE:
1990          The OLD behavior of a policy is deprecated by definition and may  be
1991          removed in a future version of CMake.
1992
1993   CMP0034
1994       The utility_source() command should not be called.
1995
1996       This  command  was  introduced  in March 2001 to help build executables
1997       used to generate other files.  This approach has long been replaced  by
1998       add_executable() combined with add_custom_command().
1999
2000       CMake  >= 3.0 prefer that this command never be called.  The OLD behav‐
2001       ior for this policy is to allow the command  to  be  called.   The  NEW
2002       behavior  for this policy is to issue a FATAL_ERROR when the command is
2003       called.
2004
2005       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
2006       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
2007       cmake_policy() command to set it to OLD or NEW explicitly.
2008
2009       NOTE:
2010          The OLD behavior of a policy is deprecated by definition and may  be
2011          removed in a future version of CMake.
2012
2013   CMP0033
2014       The export_library_dependencies() command should not be called.
2015
2016       This  command  was  added  in  January 2003 to export <tgt>_LIB_DEPENDS
2017       internal CMake cache entries to a file for installation with a project.
2018       This was used at the time to allow transitive link dependencies to work
2019       for applications outside of the original build tree of a project.   The
2020       functionality  has  been superseded by the export() and install(EXPORT)
2021       commands.
2022
2023       CMake >= 3.0 prefer that this command never be called.  The OLD  behav‐
2024       ior  for  this  policy  is  to allow the command to be called.  The NEW
2025       behavior for this policy is to issue a FATAL_ERROR when the command  is
2026       called.
2027
2028       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2029       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2030       cmake_policy() command to set it to OLD or NEW explicitly.
2031
2032       NOTE:
2033          The  OLD behavior of a policy is deprecated by definition and may be
2034          removed in a future version of CMake.
2035
2036   CMP0032
2037       The output_required_files() command should not be called.
2038
2039       This command was added in June 2001 to expose  the  then-current  CMake
2040       implicit  dependency scanner.  CMake’s real implicit dependency scanner
2041       has evolved since then but is not exposed through  this  command.   The
2042       scanning  capabilities  of this command are very limited and this func‐
2043       tionality is better achieved through dedicated outside tools.
2044
2045       CMake >= 3.0 prefer that this command never be called.  The OLD  behav‐
2046       ior  for  this  policy  is  to allow the command to be called.  The NEW
2047       behavior for this policy is to issue a FATAL_ERROR when the command  is
2048       called.
2049
2050       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2051       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2052       cmake_policy() command to set it to OLD or NEW explicitly.
2053
2054       NOTE:
2055          The  OLD behavior of a policy is deprecated by definition and may be
2056          removed in a future version of CMake.
2057
2058   CMP0031
2059       The load_command() command should not be called.
2060
2061       This command was added in August 2002 to allow projects  to  add  arbi‐
2062       trary commands implemented in C or C++.  However, it does not work when
2063       the toolchain in use does not match the ABI of the CMake  process.   It
2064       has been mostly superseded by the macro() and function() commands.
2065
2066       CMake  >= 3.0 prefer that this command never be called.  The OLD behav‐
2067       ior for this policy is to allow the command  to  be  called.   The  NEW
2068       behavior  for this policy is to issue a FATAL_ERROR when the command is
2069       called.
2070
2071       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
2072       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
2073       cmake_policy() command to set it to OLD or NEW explicitly.
2074
2075       NOTE:
2076          The OLD behavior of a policy is deprecated by definition and may  be
2077          removed in a future version of CMake.
2078
2079   CMP0030
2080       The use_mangled_mesa() command should not be called.
2081
2082       This command was created in September 2001 to support VTK before modern
2083       CMake language and custom command capabilities.  VTK has not used it in
2084       years.
2085
2086       CMake  >= 3.0 prefer that this command never be called.  The OLD behav‐
2087       ior for this policy is to allow the command  to  be  called.   The  NEW
2088       behavior  for this policy is to issue a FATAL_ERROR when the command is
2089       called.
2090
2091       This policy was introduced in CMake version 3.0.  CMake version  3.16.1
2092       warns  when  the  policy  is  not  set  and uses OLD behavior.  Use the
2093       cmake_policy() command to set it to OLD or NEW explicitly.
2094
2095       NOTE:
2096          The OLD behavior of a policy is deprecated by definition and may  be
2097          removed in a future version of CMake.
2098
2099   CMP0029
2100       The subdir_depends() command should not be called.
2101
2102       The  implementation  of this command has been empty since December 2001
2103       but was kept in CMake for compatibility for a long time.
2104
2105       CMake >= 3.0 prefer that this command never be called.  The OLD  behav‐
2106       ior  for  this  policy  is  to allow the command to be called.  The NEW
2107       behavior for this policy is to issue a FATAL_ERROR when the command  is
2108       called.
2109
2110       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2111       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2112       cmake_policy() command to set it to OLD or NEW explicitly.
2113
2114       NOTE:
2115          The  OLD behavior of a policy is deprecated by definition and may be
2116          removed in a future version of CMake.
2117
2118   CMP0028
2119       Double colon in target name means ALIAS or IMPORTED target.
2120
2121       CMake 2.8.12 and lower allowed the use of targets and files with double
2122       colons in target_link_libraries(), with some buildsystem generators.
2123
2124       The use of double-colons is a common pattern used to namespace IMPORTED
2125       targets and ALIAS targets.  When computing the link dependencies  of  a
2126       target, the name of each dependency could either be a target, or a file
2127       on disk.  Previously, if a target was not found with a  matching  name,
2128       the  name  was considered to refer to a file on disk.  This can lead to
2129       confusing error messages if there is a typo in what should be a  target
2130       name.
2131
2132       The  OLD  behavior for this policy is to search for targets, then files
2133       on disk, even if the  search  term  contains  double-colons.   The  NEW
2134       behavior for this policy is to issue a FATAL_ERROR if a link dependency
2135       contains double-colons but is not an IMPORTED target or an  ALIAS  tar‐
2136       get.
2137
2138       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2139       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2140       cmake_policy() command to set it to OLD or NEW explicitly.
2141
2142       NOTE:
2143          The  OLD behavior of a policy is deprecated by definition and may be
2144          removed in a future version of CMake.
2145
2146   CMP0027
2147       Conditionally linked imported targets with missing include directories.
2148
2149       CMake   2.8.11   introduced   introduced   the   concept   of    INTER‐
2150       FACE_INCLUDE_DIRECTORIES, and a check at cmake time that the entries in
2151       the INTERFACE_INCLUDE_DIRECTORIES of an IMPORTED target actually exist.
2152       CMake  2.8.11  also introduced generator expression support in the tar‐
2153       get_link_libraries() command.  However, if an imported target is linked
2154       as  a  result  of a generator expression evaluation, the entries in the
2155       INTERFACE_INCLUDE_DIRECTORIES of that target were not checked for exis‐
2156       tence as they should be.
2157
2158       The  OLD  behavior of this policy is to report a warning if an entry in
2159       the INTERFACE_INCLUDE_DIRECTORIES of a generator-expression  condition‐
2160       ally linked IMPORTED target does not exist.
2161
2162       The  NEW  behavior  of this policy is to report an error if an entry in
2163       the INTERFACE_INCLUDE_DIRECTORIES of a generator-expression  condition‐
2164       ally linked IMPORTED target does not exist.
2165
2166       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2167       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2168       cmake_policy() command to set it to OLD or NEW explicitly.
2169
2170       NOTE:
2171          The  OLD behavior of a policy is deprecated by definition and may be
2172          removed in a future version of CMake.
2173
2174   CMP0026
2175       Disallow use of the LOCATION property for build targets.
2176
2177       CMake 2.8.12 and lower allowed reading  the  LOCATION  target  property
2178       (and  configuration-specific  variants) to determine the eventual loca‐
2179       tion of build targets.  This relies on the assumption that  all  neces‐
2180       sary  information is available at configure-time to determine the final
2181       location and filename of the target.  However,  this  property  is  not
2182       fully  determined  until later at generate-time.  At generate time, the
2183       $<TARGET_FILE> generator expression can be used to determine the  even‐
2184       tual LOCATION of a target output.
2185
2186       Code  which reads the LOCATION target property can be ported to use the
2187       $<TARGET_FILE> generator expression together  with  the  file(GENERATE)
2188       subcommand to generate a file containing the target location.
2189
2190       The OLD behavior for this policy is to allow reading the LOCATION prop‐
2191       erties from build-targets.  The NEW behavior for this policy is to  not
2192       to allow reading the LOCATION properties from build-targets.
2193
2194       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2195       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2196       cmake_policy() command to set it to OLD or NEW explicitly.
2197
2198       NOTE:
2199          The  OLD behavior of a policy is deprecated by definition and may be
2200          removed in a future version of CMake.
2201
2202   CMP0025
2203       Compiler id for Apple Clang is now AppleClang.
2204
2205       CMake 3.0 and above recognize that Apple Clang is a different  compiler
2206       than  upstream  Clang  and  that  they  have different version numbers.
2207       CMake  now  prefers  to  present  this  to  projects  by  setting   the
2208       CMAKE_<LANG>_COMPILER_ID variable to AppleClang instead of Clang.  How‐
2209       ever, existing projects may assume the compiler id for Apple  Clang  is
2210       just  Clang  as  it was in CMake versions prior to 3.0.  Therefore this
2211       policy determines for Apple Clang which compiler id to  report  in  the
2212       CMAKE_<LANG>_COMPILER_ID  variable  after language <LANG> is enabled by
2213       the project() or enable_language() command.  The  policy  must  be  set
2214       prior to the invocation of either command.
2215
2216       The  OLD behavior for this policy is to use compiler id Clang.  The NEW
2217       behavior for this policy is to use compiler id AppleClang.
2218
2219       This policy was introduced in CMake version 3.0.   Use  the  cmake_pol‐
2220       icy() command to set this policy to OLD or NEW explicitly.  Unlike most
2221       policies, CMake version 3.16.1 does not warn by default when this  pol‐
2222       icy  is not set and simply uses OLD behavior.  See documentation of the
2223       CMAKE_POLICY_WARNING_CMP0025 variable to control the warning.
2224
2225       NOTE:
2226          The OLD behavior of a policy is deprecated by definition and may  be
2227          removed in a future version of CMake.
2228
2229   CMP0024
2230       Disallow include export result.
2231
2232       CMake  2.8.12  and  lower allowed use of the include() command with the
2233       result of the export() command.  This relies on the assumption that the
2234       export()  command  has  an  immediate effect at configure-time during a
2235       cmake run.  Certain properties of  targets  are  not  fully  determined
2236       until  later  at  generate-time, such as the link language and complete
2237       list of link libraries.  Future refactoring will change the  effect  of
2238       the  export()  command to be executed at generate-time.  Use ALIAS tar‐
2239       gets instead in cases where the goal is to refer to targets by  another
2240       name.
2241
2242       The OLD behavior for this policy is to allow including the result of an
2243       export() command.  The NEW behavior for this policy  is  not  to  allow
2244       including the result of an export() command.
2245
2246       This  policy was introduced in CMake version 3.0.  CMake version 3.16.1
2247       warns when the policy is not  set  and  uses  OLD  behavior.   Use  the
2248       cmake_policy() command to set it to OLD or NEW explicitly.
2249
2250       NOTE:
2251          The  OLD behavior of a policy is deprecated by definition and may be
2252          removed in a future version of CMake.
2253

POLICIES INTRODUCED BY CMAKE 2.8

2255   CMP0023
2256       Plain and keyword target_link_libraries() signatures cannot be mixed.
2257
2258       CMake 2.8.12 introduced the target_link_libraries() signature using the
2259       PUBLIC,  PRIVATE,  and INTERFACE keywords to generalize the LINK_PUBLIC
2260       and LINK_PRIVATE keywords introduced in CMake 2.8.7.  Use of signatures
2261       with  any of these keywords sets the link interface of a target explic‐
2262       itly, even if empty.  This produces confusing  behavior  when  used  in
2263       combination   with   the   historical   behavior   of  the  plain  tar‐
2264       get_link_libraries() signature.  For example, consider the code:
2265
2266          target_link_libraries(mylib A)
2267          target_link_libraries(mylib PRIVATE B)
2268
2269       After the first line the link interface has not been set explicitly  so
2270       CMake  would  use  the  link  implementation, A, as the link interface.
2271       However, the second line sets the link interface to empty.  In order to
2272       avoid  this  subtle  behavior  CMake now prefers to disallow mixing the
2273       plain and keyword signatures of target_link_libraries()  for  a  single
2274       target.
2275
2276       The  OLD  behavior  for  this policy is to allow keyword and plain tar‐
2277       get_link_libraries() signatures to be mixed.  The NEW behavior for this
2278       policy is to not to allow mixing of the keyword and plain signatures.
2279
2280       This  policy  was  introduced  in  CMake version 2.8.12.  CMake version
2281       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2282       cmake_policy() command to set it to OLD or NEW explicitly.
2283
2284       NOTE:
2285          The  OLD behavior of a policy is deprecated by definition and may be
2286          removed in a future version of CMake.
2287
2288   CMP0022
2289       INTERFACE_LINK_LIBRARIES defines the link interface.
2290
2291       CMake 2.8.11 constructed the ‘link interface’ of a target from  proper‐
2292       ties  matching  (IMPORTED_)?LINK_INTERFACE_LIBRARIES(_<CONFIG>)?.   The
2293       modern way to specify config-sensitive  content  is  to  use  generator
2294       expressions  and  the  IMPORTED_ prefix makes uniform processing of the
2295       link interface  with  generator  expressions  impossible.   The  INTER‐
2296       FACE_LINK_LIBRARIES  target property was introduced as a replacement in
2297       CMake 2.8.12.  This new property is named consistently with the  INTER‐
2298       FACE_COMPILE_DEFINITIONS,   INTERFACE_INCLUDE_DIRECTORIES   and  INTER‐
2299       FACE_COMPILE_OPTIONS properties.  For in-build targets, CMake will  use
2300       the  INTERFACE_LINK_LIBRARIES property as the source of the link inter‐
2301       face only if policy CMP0022 is NEW.  When exporting a target which  has
2302       this policy set to NEW, only the INTERFACE_LINK_LIBRARIES property will
2303       be processed and generated for the IMPORTED target by default.   A  new
2304       option  to the install(EXPORT) and export commands allows export of the
2305       old-style properties for compatibility with downstream users  of  CMake
2306       versions  older  than 2.8.12.  The target_link_libraries() command will
2307       no   longer    populate    the    properties    matching    LINK_INTER‐
2308       FACE_LIBRARIES(_<CONFIG>)? if this policy is NEW.
2309
2310       Warning-free  future-compatible  code  which  works  with  CMake  2.8.7
2311       onwards can be written by using the LINK_PRIVATE and  LINK_PUBLIC  key‐
2312       words of target_link_libraries().
2313
2314       The   OLD   behavior   for   this   policy  is  to  ignore  the  INTER‐
2315       FACE_LINK_LIBRARIES property for in-build targets.   The  NEW  behavior
2316       for  this  policy  is  to use the INTERFACE_LINK_LIBRARIES property for
2317       in-build   targets,   and   ignore   the   old   properties    matching
2318       (IMPORTED_)?LINK_INTERFACE_LIBRARIES(_<CONFIG>)?.
2319
2320       This  policy  was  introduced  in  CMake version 2.8.12.  CMake version
2321       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2322       cmake_policy() command to set it to OLD or NEW explicitly.
2323
2324       NOTE:
2325          The  OLD behavior of a policy is deprecated by definition and may be
2326          removed in a future version of CMake.
2327
2328   CMP0021
2329       Fatal error on relative paths in INCLUDE_DIRECTORIES target property.
2330
2331       CMake 2.8.10.2 and lower allowed the INCLUDE_DIRECTORIES  target  prop‐
2332       erty  to  contain  relative  paths.   The  base  path for such relative
2333       entries is not well defined.  CMake 2.8.12 issues a FATAL_ERROR if  the
2334       INCLUDE_DIRECTORIES property contains a relative path.
2335
2336       The OLD behavior for this policy is not to warn about relative paths in
2337       the INCLUDE_DIRECTORIES target property.  The  NEW  behavior  for  this
2338       policy is to issue a FATAL_ERROR if INCLUDE_DIRECTORIES contains a rel‐
2339       ative path.
2340
2341       This policy was introduced in  CMake  version  2.8.12.   CMake  version
2342       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2343       cmake_policy() command to set it to OLD or NEW explicitly.
2344
2345       NOTE:
2346          The OLD behavior of a policy is deprecated by definition and may  be
2347          removed in a future version of CMake.
2348
2349   CMP0020
2350       Automatically link Qt executables to qtmain target on Windows.
2351
2352       CMake  2.8.10  and  lower required users of Qt to always specify a link
2353       dependency to the qtmain.lib static library manually on Windows.  CMake
2354       2.8.11  gained  the  ability  to  evaluate  generator expressions while
2355       determining the link dependencies from IMPORTED targets.   This  allows
2356       CMake  itself to automatically link executables which link to Qt to the
2357       qtmain.lib library when using IMPORTED Qt  targets.   For  applications
2358       already  linking  to  qtmain.lib,  this should have little impact.  For
2359       applications which supply their own alternative WinMain  implementation
2360       and  for  applications  which use the QAxServer library, this automatic
2361       linking will need to be disabled as per the documentation.
2362
2363       The OLD behavior  for  this  policy  is  not  to  link  executables  to
2364       qtmain.lib  automatically when they link to the QtCore IMPORTED target.
2365       The NEW behavior for this policy is to link executables  to  qtmain.lib
2366       automatically when they link to QtCore IMPORTED target.
2367
2368       This  policy  was  introduced  in  CMake version 2.8.11.  CMake version
2369       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2370       cmake_policy() command to set it to OLD or NEW explicitly.
2371
2372       NOTE:
2373          The  OLD behavior of a policy is deprecated by definition and may be
2374          removed in a future version of CMake.
2375
2376   CMP0019
2377       Do not re-expand variables in include and link information.
2378
2379       CMake 2.8.10 and lower re-evaluated values given to the  include_direc‐
2380       tories,  link_directories,  and  link_libraries  commands to expand any
2381       leftover variable references at the  end  of  the  configuration  step.
2382       This  was  for  strict  compatibility  with  VERY  early CMake versions
2383       because all variable references are now normally evaluated during CMake
2384       language  processing.  CMake 2.8.11 and higher prefer to skip the extra
2385       evaluation.
2386
2387       The OLD behavior for this policy  is  to  re-evaluate  the  values  for
2388       strict compatibility.  The NEW behavior for this policy is to leave the
2389       values untouched.
2390
2391       This policy was introduced in  CMake  version  2.8.11.   CMake  version
2392       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2393       cmake_policy() command to set it to OLD or NEW explicitly.
2394
2395       NOTE:
2396          The OLD behavior of a policy is deprecated by definition and may  be
2397          removed in a future version of CMake.
2398
2399   CMP0018
2400       Ignore CMAKE_SHARED_LIBRARY_<Lang>_FLAGS variable.
2401
2402       CMake  2.8.8  and lower compiled sources in SHARED and MODULE libraries
2403       using the value of the  undocumented  CMAKE_SHARED_LIBRARY_<Lang>_FLAGS
2404       platform  variable.   The  variable  contained  platform-specific flags
2405       needed to compile objects for shared libraries.  Typically it  included
2406       a  flag  such  as -fPIC for position independent code but also included
2407       other flags needed on certain platforms.  CMake 2.8.9 and higher prefer
2408       instead  to use the POSITION_INDEPENDENT_CODE target property to deter‐
2409       mine what targets should be position independent, and new  undocumented
2410       platform     variables     to     select     flags    while    ignoring
2411       CMAKE_SHARED_LIBRARY_<Lang>_FLAGS completely.
2412
2413       The default for either approach produces identical  compilation  flags,
2414       but  if  a  project modifies CMAKE_SHARED_LIBRARY_<Lang>_FLAGS from its
2415       original value this policy determines which approach to use.
2416
2417       The OLD behavior for this policy is  to  ignore  the  POSITION_INDEPEN‐
2418       DENT_CODE  property  for  all  targets  and  use  the modified value of
2419       CMAKE_SHARED_LIBRARY_<Lang>_FLAGS for SHARED and MODULE libraries.
2420
2421       The    NEW    behavior    for    this    policy    is     to     ignore
2422       CMAKE_SHARED_LIBRARY_<Lang>_FLAGS  whether  it  is  modified or not and
2423       honor the POSITION_INDEPENDENT_CODE target property.
2424
2425       This policy was introduced  in  CMake  version  2.8.9.   CMake  version
2426       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2427       cmake_policy() command to set it to OLD or NEW explicitly.
2428
2429       NOTE:
2430          The OLD behavior of a policy is deprecated by definition and may  be
2431          removed in a future version of CMake.
2432
2433   CMP0017
2434       Prefer files from the CMake module directory when including from there.
2435
2436       Starting  with  CMake 2.8.4, if a cmake-module shipped with CMake (i.e.
2437       located in the CMake module directory) calls  include()  or  find_pack‐
2438       age(),  the  files  located in the CMake module directory are preferred
2439       over the files in CMAKE_MODULE_PATH.  This makes sure that the  modules
2440       belonging  to  CMake always get those files included which they expect,
2441       and against which they were developed and tested.  In all other  cases,
2442       the  files  found  in  CMAKE_MODULE_PATH still take precedence over the
2443       ones in the CMake module directory.  The OLD behavior is to always pre‐
2444       fer  files  from  CMAKE_MODULE_PATH  over  files from the CMake modules
2445       directory.
2446
2447       This policy was introduced  in  CMake  version  2.8.4.   CMake  version
2448       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2449       cmake_policy() command to set it to OLD or NEW explicitly.
2450
2451       NOTE:
2452          The OLD behavior of a policy is deprecated by definition and may  be
2453          removed in a future version of CMake.
2454
2455   CMP0016
2456       target_link_libraries()  reports  error  if  its only argument is not a
2457       target.
2458
2459       In CMake 2.8.2 and lower the target_link_libraries()  command  silently
2460       ignored  if  it  was  called  with only one argument, and this argument
2461       wasn’t a valid target.  In CMake 2.8.3 and above it reports an error in
2462       this case.
2463
2464       This  policy  was  introduced  in  CMake  version 2.8.3.  CMake version
2465       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2466       cmake_policy() command to set it to OLD or NEW explicitly.
2467
2468       NOTE:
2469          The  OLD behavior of a policy is deprecated by definition and may be
2470          removed in a future version of CMake.
2471
2472   CMP0015
2473          link_directories() treats paths relative to the source dir.
2474
2475       In CMake 2.8.0 and lower the link_directories() command passed relative
2476       paths   unchanged  to  the  linker.   In  CMake  2.8.1  and  above  the
2477       link_directories() command prefers to  interpret  relative  paths  with
2478       respect   to   CMAKE_CURRENT_SOURCE_DIR,   which   is  consistent  with
2479       include_directories() and other commands.  The OLD  behavior  for  this
2480       policy  is  to  use relative paths verbatim in the linker command.  The
2481       NEW behavior for this policy is to convert relative paths  to  absolute
2482       paths by appending the relative path to CMAKE_CURRENT_SOURCE_DIR.
2483
2484       This  policy  was  introduced  in  CMake  version 2.8.1.  CMake version
2485       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2486       cmake_policy() command to set it to OLD or NEW explicitly.
2487
2488       NOTE:
2489          The  OLD behavior of a policy is deprecated by definition and may be
2490          removed in a future version of CMake.
2491
2492   CMP0014
2493       Input directories must have CMakeLists.txt.
2494
2495       CMake versions before 2.8 silently ignored missing CMakeLists.txt files
2496       in directories referenced by add_subdirectory() or  subdirs(), treating
2497       them as if present but empty.  In CMake 2.8.0 and above this cmake_pol‐
2498       icy() determines whether or not the case is an error.  The OLD behavior
2499       for this policy is to silently ignore the problem.   The  NEW  behavior
2500       for this policy is to report an error.
2501
2502       This  policy  was  introduced  in  CMake  version 2.8.0.  CMake version
2503       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2504       cmake_policy() command to set it to OLD or NEW explicitly.
2505
2506       NOTE:
2507          The  OLD behavior of a policy is deprecated by definition and may be
2508          removed in a future version of CMake.
2509
2510   CMP0013
2511       Duplicate binary directories are not allowed.
2512
2513       CMake 2.6.3 and below silently permitted  add_subdirectory()  calls  to
2514       create  the  same binary directory multiple times.  During build system
2515       generation files would be written and then  overwritten  in  the  build
2516       tree and could lead to strange behavior.  CMake 2.6.4 and above explic‐
2517       itly detect duplicate binary directories.  CMake 2.6.4 always considers
2518       this  case  an  error.  In CMake 2.8.0 and above this policy determines
2519       whether or not the case is an error.  The OLD behavior for this  policy
2520       is  to  allow  duplicate binary directories.  The NEW behavior for this
2521       policy is to disallow duplicate binary directories with an error.
2522
2523       This policy was introduced  in  CMake  version  2.8.0.   CMake  version
2524       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2525       cmake_policy() command to set it to OLD or NEW explicitly.
2526
2527       NOTE:
2528          The OLD behavior of a policy is deprecated by definition and may  be
2529          removed in a future version of CMake.
2530
2531   CMP0012
2532       if() recognizes numbers and boolean constants.
2533
2534       In  CMake versions 2.6.4 and lower the if() command implicitly derefer‐
2535       enced arguments corresponding to variables, even those named like  num‐
2536       bers  or  boolean  constants,  except for 0 and 1.  Numbers and boolean
2537       constants such as true, false, yes, no, on, off, y, n, notfound, ignore
2538       (all  case insensitive) were recognized in some cases but not all.  For
2539       example, the code if(TRUE) might have evaluated as false.  Numbers such
2540       as  2 were recognized only in boolean expressions like if(NOT 2) (lead‐
2541       ing to false) but not as a single-argument like if(2) (also leading  to
2542       false).   Later  versions  of CMake prefer to treat numbers and boolean
2543       constants literally, so they should not be used as variable names.
2544
2545       The OLD behavior for this policy is to implicitly dereference variables
2546       named  like  numbers  and boolean constants.  The NEW behavior for this
2547       policy is to recognize numbers and boolean constants  without  derefer‐
2548       encing variables with such names.
2549
2550       This  policy  was  introduced  in  CMake  version 2.8.0.  CMake version
2551       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2552       cmake_policy() command to set it to OLD or NEW explicitly.
2553
2554       NOTE:
2555          The  OLD behavior of a policy is deprecated by definition and may be
2556          removed in a future version of CMake.
2557

POLICIES INTRODUCED BY CMAKE 2.6

2559   CMP0011
2560       Included scripts do automatic cmake_policy() PUSH and POP.
2561
2562       In CMake 2.6.2 and below, CMake Policy settings in  scripts  loaded  by
2563       the  include()  and  find_package() commands would affect the includer.
2564       Explicit invocations of cmake_policy(PUSH) and  cmake_policy(POP)  were
2565       required  to  isolate  policy  changes and protect the includer.  While
2566       some scripts intend to affect the policies of their includer,  most  do
2567       not.  In CMake 2.6.3 and above, include() and find_package() by default
2568       PUSH and POP an entry on the policy stack around  an  included  script,
2569       but provide a NO_POLICY_SCOPE option to disable it.  This policy deter‐
2570       mines whether or not to imply NO_POLICY_SCOPE for  compatibility.   The
2571       OLD  behavior for this policy is to imply NO_POLICY_SCOPE for include()
2572       and find_package() commands.  The NEW behavior for this  policy  is  to
2573       allow the commands to do their default cmake_policy PUSH and POP.
2574
2575       This  policy  was  introduced  in  CMake  version 2.6.3.  CMake version
2576       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2577       cmake_policy() command to set it to OLD or NEW explicitly.
2578
2579       NOTE:
2580          The  OLD behavior of a policy is deprecated by definition and may be
2581          removed in a future version of CMake.
2582
2583   CMP0010
2584       Bad variable reference syntax is an error.
2585
2586       In CMake 2.6.2 and below, incorrect variable reference syntax such as a
2587       missing close-brace (${FOO) was reported but did not stop processing of
2588       CMake code.  This policy determines whether a bad variable reference is
2589       an error.  The OLD behavior for this policy is to warn about the error,
2590       leave the string untouched, and continue.  The NEW  behavior  for  this
2591       policy is to report an error.
2592
2593       If  CMP0053  is set to NEW, this policy has no effect and is treated as
2594       always being NEW.
2595
2596       This policy was introduced  in  CMake  version  2.6.3.   CMake  version
2597       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2598       cmake_policy() command to set it to OLD or NEW explicitly.
2599
2600       NOTE:
2601          The OLD behavior of a policy is deprecated by definition and may  be
2602          removed in a future version of CMake.
2603
2604   CMP0009
2605       FILE GLOB_RECURSE calls should not follow symlinks by default.
2606
2607       In CMake 2.6.1 and below, file(GLOB_RECURSE) calls would follow through
2608       symlinks, sometimes coming  up  with  unexpectedly  large  result  sets
2609       because  of  symlinks to top level directories that contain hundreds of
2610       thousands of files.
2611
2612       This policy determines whether or not to  follow  symlinks  encountered
2613       during  a file(GLOB_RECURSE) call.  The OLD behavior for this policy is
2614       to follow the symlinks.  The NEW behavior for this  policy  is  not  to
2615       follow the symlinks by default, but only if FOLLOW_SYMLINKS is given as
2616       an additional argument to the FILE command.
2617
2618       This policy was introduced  in  CMake  version  2.6.2.   CMake  version
2619       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2620       cmake_policy() command to set it to OLD or NEW explicitly.
2621
2622       NOTE:
2623          The OLD behavior of a policy is deprecated by definition and may  be
2624          removed in a future version of CMake.
2625
2626   CMP0008
2627       Libraries linked by full-path must have a valid library file name.
2628
2629       In CMake 2.4 and below it is possible to write code like
2630
2631          target_link_libraries(myexe /full/path/to/somelib)
2632
2633       where  somelib is supposed to be a valid library file name such as lib‐
2634       somelib.a or somelib.lib.  For Makefile  generators  this  produces  an
2635       error  at  build time because the dependency on the full path cannot be
2636       found.  For Visual Studio Generators IDE and Xcode generators this used
2637       to  work  by  accident because CMake would always split off the library
2638       directory and ask  the  linker  to  search  for  the  library  by  name
2639       (-lsomelib  or  somelib.lib).  Despite the failure with Makefiles, some
2640       projects have code like this and build only with Visual  Studio  and/or
2641       Xcode.  This version of CMake prefers to pass the full path directly to
2642       the native build tool, which will fail in this case because it does not
2643       name a valid library file.
2644
2645       This policy determines what to do with full paths that do not appear to
2646       name a valid library file.  The OLD behavior  for  this  policy  is  to
2647       split  the  library name from the path and ask the linker to search for
2648       it.  The NEW behavior for this policy is to trust the  given  path  and
2649       pass it directly to the native build tool unchanged.
2650
2651       This  policy  was  introduced  in  CMake  version 2.6.1.  CMake version
2652       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2653       cmake_policy() command to set it to OLD or NEW explicitly.
2654
2655       NOTE:
2656          The  OLD behavior of a policy is deprecated by definition and may be
2657          removed in a future version of CMake.
2658
2659   CMP0007
2660       list command no longer ignores empty elements.
2661
2662       This policy determines whether the list command will ignore empty  ele‐
2663       ments in the list.  CMake 2.4 and below list commands ignored all empty
2664       elements in the list.  For example, a;b;;c would have length 3 and  not
2665       4.   The OLD behavior for this policy is to ignore empty list elements.
2666       The NEW behavior for this policy is to correctly count  empty  elements
2667       in a list.
2668
2669       This  policy  was  introduced  in  CMake  version 2.6.0.  CMake version
2670       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2671       cmake_policy() command to set it to OLD or NEW explicitly.
2672
2673       NOTE:
2674          The  OLD behavior of a policy is deprecated by definition and may be
2675          removed in a future version of CMake.
2676
2677   CMP0006
2678       Installing MACOSX_BUNDLE targets requires a BUNDLE DESTINATION.
2679
2680       This policy determines whether the  install(TARGETS)  command  must  be
2681       given  a  BUNDLE  DESTINATION  when  asked to install a target with the
2682       MACOSX_BUNDLE property set.  CMake 2.4 and below  did  not  distinguish
2683       application  bundles  from  normal executables when installing targets.
2684       CMake 2.6 provides a BUNDLE option to the install(TARGETS) command that
2685       specifies  rules  specific to application bundles on the Mac.  Projects
2686       should use this option when installing a target with the  MACOSX_BUNDLE
2687       property set.
2688
2689       The  OLD behavior for this policy is to fall back to the RUNTIME DESTI‐
2690       NATION if a BUNDLE DESTINATION is not given.  The NEW behavior for this
2691       policy is to produce an error if a bundle target is installed without a
2692       BUNDLE DESTINATION.
2693
2694       This policy was introduced  in  CMake  version  2.6.0.   CMake  version
2695       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2696       cmake_policy() command to set it to OLD or NEW explicitly.
2697
2698       NOTE:
2699          The OLD behavior of a policy is deprecated by definition and may  be
2700          removed in a future version of CMake.
2701
2702   CMP0005
2703       Preprocessor definition values are now escaped automatically.
2704
2705       This  policy  determines  whether  or not CMake should generate escaped
2706       preprocessor definition values added via add_definitions.   CMake  ver‐
2707       sions 2.4 and below assumed that only trivial values would be given for
2708       macros  in  add_definitions  calls.   It  did  not  attempt  to  escape
2709       non-trivial  values  such  as string literals in generated build rules.
2710       CMake versions 2.6 and above support escaping of most values, but  can‐
2711       not assume the user has not added escapes already in an attempt to work
2712       around limitations in earlier versions.
2713
2714       The OLD behavior for this policy is to place definition values given to
2715       add_definitions  directly in the generated build rules without attempt‐
2716       ing to escape anything.  The NEW behavior for this policy is to  gener‐
2717       ate correct escapes for all native build tools automatically.  See doc‐
2718       umentation of the COMPILE_DEFINITIONS target property  for  limitations
2719       of the escaping implementation.
2720
2721       This  policy  was  introduced  in  CMake  version 2.6.0.  CMake version
2722       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2723       cmake_policy() command to set it to OLD or NEW explicitly.
2724
2725       NOTE:
2726          The  OLD behavior of a policy is deprecated by definition and may be
2727          removed in a future version of CMake.
2728
2729   CMP0004
2730       Libraries linked may not have leading or trailing whitespace.
2731
2732       CMake versions 2.4 and below  silently  removed  leading  and  trailing
2733       whitespace from libraries linked with code like
2734
2735          target_link_libraries(myexe " A ")
2736
2737       This could lead to subtle errors in user projects.
2738
2739       The  OLD  behavior  for  this  policy is to silently remove leading and
2740       trailing whitespace.  The NEW behavior for this policy is  to  diagnose
2741       the  existence  of  such  whitespace as an error.  The setting for this
2742       policy used when checking the library names is that in effect when  the
2743       target is created by an add_executable() or add_library() command.
2744
2745       This  policy  was  introduced  in  CMake  version 2.6.0.  CMake version
2746       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2747       cmake_policy() command to set it to OLD or NEW explicitly.
2748
2749       NOTE:
2750          The  OLD behavior of a policy is deprecated by definition and may be
2751          removed in a future version of CMake.
2752
2753   CMP0003
2754       Libraries linked via full path no longer produce linker search paths.
2755
2756       This policy affects how libraries whose full paths are  NOT  known  are
2757       found  at link time, but was created due to a change in how CMake deals
2758       with libraries whose full paths are known.  Consider the code
2759
2760          target_link_libraries(myexe /path/to/libA.so)
2761
2762       CMake 2.4 and below implemented linking to libraries whose  full  paths
2763       are  known  by splitting them on the link line into separate components
2764       consisting of the linker search path and the library name.  The example
2765       code might have produced something like
2766
2767          ... -L/path/to -lA ...
2768
2769       in order to link to library A.  An analysis was performed to order mul‐
2770       tiple link directories such that the linker would find library A in the
2771       desired  location,  but  there  are  cases in which this does not work.
2772       CMake versions 2.6 and above use the more reliable approach of  passing
2773       the  full  path to libraries directly to the linker in most cases.  The
2774       example code now produces something like
2775
2776          ... /path/to/libA.so ....
2777
2778       Unfortunately this change can break code like
2779
2780          target_link_libraries(myexe /path/to/libA.so B)
2781
2782       where B is meant to find /path/to/libB.so.  This code is wrong  because
2783       the  user is asking the linker to find library B but has not provided a
2784       linker search path (which may be added with the  link_directories  com‐
2785       mand).   However,  with  the  old linking implementation the code would
2786       work accidentally because the linker search path added  for  library  A
2787       allowed library B to be found.
2788
2789       In  order to support projects depending on linker search paths added by
2790       linking to libraries with known full paths, the OLD behavior  for  this
2791       policy will add the linker search paths even though they are not needed
2792       for their own libraries.  When this policy is set to  OLD,  CMake  will
2793       produce a link line such as
2794
2795          ... -L/path/to /path/to/libA.so -lB ...
2796
2797       which will allow library B to be found as it was previously.  When this
2798       policy is set to NEW, CMake will produce a link line such as
2799
2800          ... /path/to/libA.so -lB ...
2801
2802       which more accurately matches what the project specified.
2803
2804       The setting for this policy used when generating the link line is  that
2805       in   effect  when  the  target  is  created  by  an  add_executable  or
2806       add_library command.  For the example described above, the code
2807
2808          cmake_policy(SET CMP0003 OLD) # or cmake_policy(VERSION 2.4)
2809          add_executable(myexe myexe.c)
2810          target_link_libraries(myexe /path/to/libA.so B)
2811
2812       will work and suppress the warning for this policy.   It  may  also  be
2813       updated to work with the corrected linking approach:
2814
2815          cmake_policy(SET CMP0003 NEW) # or cmake_policy(VERSION 2.6)
2816          link_directories(/path/to) # needed to find library B
2817          add_executable(myexe myexe.c)
2818          target_link_libraries(myexe /path/to/libA.so B)
2819
2820       Even better, library B may be specified with a full path:
2821
2822          add_executable(myexe myexe.c)
2823          target_link_libraries(myexe /path/to/libA.so /path/to/libB.so)
2824
2825       When  all  items on the link line have known paths CMake does not check
2826       this policy so it has no effect.
2827
2828       Note that the warning for this policy will be issued for  at  most  one
2829       target.  This avoids flooding users with messages for every target when
2830       setting the policy once will probably fix all targets.
2831
2832       This policy was introduced  in  CMake  version  2.6.0.   CMake  version
2833       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2834       cmake_policy() command to set it to OLD or NEW explicitly.
2835
2836       NOTE:
2837          The OLD behavior of a policy is deprecated by definition and may  be
2838          removed in a future version of CMake.
2839
2840   CMP0002
2841       Logical target names must be globally unique.
2842
2843       Targets names created with add_executable(), add_library(), or add_cus‐
2844       tom_target() are logical build target names.  Logical target names must
2845       be globally unique because:
2846
2847          - Unique names may be referenced unambiguously both in CMake
2848            code and on make tool command lines.
2849          - Logical names are used by Xcode and VS IDE generators
2850            to produce meaningful project names for the targets.
2851
2852       The  logical  name  of  executable and library targets does not have to
2853       correspond to the physical file names built.  Consider using  the  OUT‐
2854       PUT_NAME  target  property to create two targets with the same physical
2855       name while keeping logical names distinct.  Custom targets must  simply
2856       have  globally  unique  names  (unless  one  uses  the  global property
2857       ALLOW_DUPLICATE_CUSTOM_TARGETS with a Makefiles generator).
2858
2859       This policy was introduced  in  CMake  version  2.6.0.   CMake  version
2860       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2861       cmake_policy() command to set it to OLD or NEW explicitly.
2862
2863       NOTE:
2864          The OLD behavior of a policy is deprecated by definition and may  be
2865          removed in a future version of CMake.
2866
2867   CMP0001
2868       CMAKE_BACKWARDS_COMPATIBILITY should no longer be used.
2869
2870       The  behavior  is to check CMAKE_BACKWARDS_COMPATIBILITY and present it
2871       to the user.  The NEW behavior is to ignore CMAKE_BACKWARDS_COMPATIBIL‐
2872       ITY completely.
2873
2874       In  CMake  2.4 and below the variable CMAKE_BACKWARDS_COMPATIBILITY was
2875       used to request compatibility with earlier versions of CMake.  In CMake
2876       2.6  and above all compatibility issues are handled by policies and the
2877       cmake_policy() command.  However, CMake must  still  check  CMAKE_BACK‐
2878       WARDS_COMPATIBILITY for projects written for CMake 2.4 and below.
2879
2880       This  policy  was  introduced  in  CMake  version 2.6.0.  CMake version
2881       3.16.1 warns when the policy is not set and uses OLD behavior.  Use the
2882       cmake_policy() command to set it to OLD or NEW explicitly.
2883
2884       NOTE:
2885          The  OLD behavior of a policy is deprecated by definition and may be
2886          removed in a future version of CMake.
2887
2888   CMP0000
2889       A minimum required CMake version must be specified.
2890
2891       CMake requires that projects specify the version of CMake to which they
2892       have  been  written.  This policy has been put in place so users trying
2893       to build the project may be told when they need to update their  CMake.
2894       Specifying  a  version also helps the project build with CMake versions
2895       newer than that specified.  Use the cmake_minimum_required() command at
2896       the top of your main CMakeLists.txt file:
2897
2898          cmake_minimum_required(VERSION <major>.<minor>)
2899
2900       where <major>.<minor> is the version of CMake you want to support (such
2901       as 3.14).  The command will ensure that at least the given  version  of
2902       CMake  is  running  and  help  newer  versions  be  compatible with the
2903       project.  See documentation of cmake_minimum_required() for details.
2904
2905       Note that the command invocation must appear in the CMakeLists.txt file
2906       itself;  a  call  in  an included file is not sufficient.  However, the
2907       cmake_policy() command may be called to set policy CMP0000  to  OLD  or
2908       NEW  behavior  explicitly.   The OLD behavior is to silently ignore the
2909       missing invocation.  The NEW behavior is to issue an error instead of a
2910       warning.   An  included  file  may set CMP0000 explicitly to affect how
2911       this policy is enforced for the main CMakeLists.txt file.
2912
2913       This policy was introduced in CMake version 2.6.0.
2914
2915       NOTE:
2916          The OLD behavior of a policy is deprecated by definition and may  be
2917          removed in a future version of CMake.
2918
2920       2000-2019 Kitware, Inc. and Contributors
2921
2922
2923
2924
29253.16.1                           Dec 14, 2019                CMAKE-POLICIES(7)
Impressum