code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0001 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0000" href="CMP0000.html" />
    <link rel="prev" title="CMP0002" href="CMP0002.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0001

CMP0001¶

CMAKE_BACKWARDS_COMPATIBILITY should no longer be used.

The behavior is to check CMAKE_BACKWARDS_COMPATIBILITY and present
it to the user.  The NEW behavior is to ignore
CMAKE_BACKWARDS_COMPATIBILITY completely.

In CMake 2.4 and below the variable CMAKE_BACKWARDS_COMPATIBILITY was
used to request compatibility with earlier versions of CMake.  In
CMake 2.6 and above all compatibility issues are handled by policies
and the cmake_policy() command.  However, CMake must still check
CMAKE_BACKWARDS_COMPATIBILITY for projects written for CMake 2.4 and
below.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0002

Next topic

CMP0000

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0001

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0002 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0001" href="CMP0001.html" />
    <link rel="prev" title="CMP0003" href="CMP0003.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0002

CMP0002¶

Logical target names must be globally unique.

Targets names created with add_executable(), add_library(), or
add_custom_target() are logical build target names.  Logical target
names must be globally unique because:

- Unique names may be referenced unambiguously both in CMake
  code and on make tool command lines.
- Logical names are used by Xcode and VS IDE generators
  to produce meaningful project names for the targets.

The logical name of executable and library targets does not have to
correspond to the physical file names built.  Consider using the
OUTPUT_NAME target property to create two targets with the same
physical name while keeping logical names distinct.  Custom targets
must simply have globally unique names (unless one uses the global
property ALLOW_DUPLICATE_CUSTOM_TARGETS with a Makefiles generator).

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0003

Next topic

CMP0001

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0002

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.

repo_name: lazytadpole/codenamesilverfish

license: mit


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0003 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0002" href="CMP0002.html" />
    <link rel="prev" title="CMP0004" href="CMP0004.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0003

CMP0003¶

Libraries linked via full path no longer produce linker search paths.

This policy affects how libraries whose full paths are NOT known are
found at link time, but was created due to a change in how CMake deals
with libraries whose full paths are known.  Consider the code

target_link_libraries(myexe /path/to/libA.so)

CMake 2.4 and below implemented linking to libraries whose full paths
are known by splitting them on the link line into separate components
consisting of the linker search path and the library name.  The
example code might have produced something like

... -L/path/to -lA ...

in order to link to library A.  An analysis was performed to order
multiple link directories such that the linker would find library A in
the desired location, but there are cases in which this does not work.
CMake versions 2.6 and above use the more reliable approach of passing
the full path to libraries directly to the linker in most cases.  The
example code now produces something like

... /path/to/libA.so ....

Unfortunately this change can break code like

target_link_libraries(myexe /path/to/libA.so B)

where B is meant to find /path/to/libB.so.  This code is wrong
because the user is asking the linker to find library B but has not
provided a linker search path (which may be added with the
link_directories command).  However, with the old linking
implementation the code would work accidentally because the linker
search path added for library A allowed library B to be found.

In order to support projects depending on linker search paths added by
linking to libraries with known full paths, the OLD behavior for this
policy will add the linker search paths even though they are not
needed for their own libraries.  When this policy is set to OLD, CMake
will produce a link line such as

... -L/path/to /path/to/libA.so -lB ...

which will allow library B to be found as it was previously.  When
this policy is set to NEW, CMake will produce a link line such as

... /path/to/libA.so -lB ...

which more accurately matches what the project specified.

The setting for this policy used when generating the link line is that
in effect when the target is created by an add_executable or
add_library command.  For the example described above, the code

cmake_policy(SET CMP0003 OLD) # or cmake_policy(VERSION 2.4)
add_executable(myexe myexe.c)
target_link_libraries(myexe /path/to/libA.so B)

will work and suppress the warning for this policy.  It may also be
updated to work with the corrected linking approach:

cmake_policy(SET CMP0003 NEW) # or cmake_policy(VERSION 2.6)
link_directories(/path/to) # needed to find library B
add_executable(myexe myexe.c)
target_link_libraries(myexe /path/to/libA.so B)

Even better, library B may be specified with a full path:

add_executable(myexe myexe.c)
target_link_libraries(myexe /path/to/libA.so /path/to/libB.so)

When all items on the link line have known paths CMake does not check
this policy so it has no effect.

Note that the warning for this policy will be issued for at most one
target.  This avoids flooding users with messages for every target
when setting the policy once will probably fix all targets.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0004

Next topic

CMP0002

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0003

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0004 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0003" href="CMP0003.html" />
    <link rel="prev" title="CMP0005" href="CMP0005.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0004

CMP0004¶

Libraries linked may not have leading or trailing whitespace.

CMake versions 2.4 and below silently removed leading and trailing
whitespace from libraries linked with code like

target_link_libraries(myexe " A ")

This could lead to subtle errors in user projects.

The OLD behavior for this policy is to silently remove leading and
trailing whitespace.  The NEW behavior for this policy is to diagnose
the existence of such whitespace as an error.  The setting for this
policy used when checking the library names is that in effect when the
target is created by an add_executable() or add_library()
command.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0005

Next topic

CMP0003

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0004

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0005 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0004" href="CMP0004.html" />
    <link rel="prev" title="CMP0006" href="CMP0006.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0005

CMP0005¶

Preprocessor definition values are now escaped automatically.

This policy determines whether or not CMake should generate escaped
preprocessor definition values added via add_definitions.  CMake
versions 2.4 and below assumed that only trivial values would be given
for macros in add_definitions calls.  It did not attempt to escape
non-trivial values such as string literals in generated build rules.
CMake versions 2.6 and above support escaping of most values, but
cannot assume the user has not added escapes already in an attempt to
work around limitations in earlier versions.

The OLD behavior for this policy is to place definition values given
to add_definitions directly in the generated build rules without
attempting to escape anything.  The NEW behavior for this policy is to
generate correct escapes for all native build tools automatically.
See documentation of the COMPILE_DEFINITIONS target property for
limitations of the escaping implementation.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0006

Next topic

CMP0004

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0005

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0006 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0005" href="CMP0005.html" />
    <link rel="prev" title="CMP0007" href="CMP0007.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0006

CMP0006¶

Installing MACOSX_BUNDLE targets requires a BUNDLE DESTINATION.

This policy determines whether the install(TARGETS) command must be
given a BUNDLE DESTINATION when asked to install a target with the
MACOSX_BUNDLE property set.  CMake 2.4 and below did not distinguish
application bundles from normal executables when installing targets.
CMake 2.6 provides a BUNDLE option to the install(TARGETS)
command that specifies rules specific to application bundles on the Mac.
Projects should use this option when installing a target with the
MACOSX_BUNDLE property set.

The OLD behavior for this policy is to fall back to the
RUNTIME DESTINATION if a BUNDLE DESTINATION is not given.  The NEW
behavior for this policy is to produce an error if a bundle target is installed
without a BUNDLE DESTINATION.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0007

Next topic

CMP0005

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0006

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0007 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0006" href="CMP0006.html" />
    <link rel="prev" title="CMP0008" href="CMP0008.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0007

CMP0007¶

list command no longer ignores empty elements.

This policy determines whether the list command will ignore empty
elements in the list.  CMake 2.4 and below list commands ignored all
empty elements in the list.  For example, a;b;;c would have length 3
and not 4.  The OLD behavior for this policy is to ignore empty list
elements.  The NEW behavior for this policy is to correctly count
empty elements in a list.

This policy was introduced in CMake version 2.6.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0008

Next topic

CMP0006

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0007

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0008 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0007" href="CMP0007.html" />
    <link rel="prev" title="CMP0009" href="CMP0009.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0008

CMP0008¶

Libraries linked by full-path must have a valid library file name.

In CMake 2.4 and below it is possible to write code like

target_link_libraries(myexe /full/path/to/somelib)

where somelib is supposed to be a valid library file name such as
libsomelib.a or somelib.lib.  For Makefile generators this
produces an error at build time because the dependency on the full
path cannot be found.  For Visual Studio Generators IDE
and Xcode generators this used to
work by accident because CMake would always split off the library
directory and ask the linker to search for the library by name
(-lsomelib or somelib.lib).  Despite the failure with Makefiles, some
projects have code like this and build only with Visual Studio and/or Xcode.
This version of CMake prefers to pass the full path directly to the
native build tool, which will fail in this case because it does not
name a valid library file.

This policy determines what to do with full paths that do not appear
to name a valid library file.  The OLD behavior for this policy is to
split the library name from the path and ask the linker to search for
it.  The NEW behavior for this policy is to trust the given path and
pass it directly to the native build tool unchanged.

This policy was introduced in CMake version 2.6.1.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0009

Next topic

CMP0007

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0008

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0009 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0008" href="CMP0008.html" />
    <link rel="prev" title="CMP0010" href="CMP0010.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0009

CMP0009¶

FILE GLOB_RECURSE calls should not follow symlinks by default.

In CMake 2.6.1 and below, file(GLOB_RECURSE) calls would follow
through symlinks, sometimes coming up with unexpectedly large result sets
because of symlinks to top level directories that contain hundreds of
thousands of files.

This policy determines whether or not to follow symlinks encountered
during a file(GLOB_RECURSE) call.  The OLD behavior for this
policy is to follow the symlinks.  The NEW behavior for this policy is not
to follow the symlinks by default, but only if FOLLOW_SYMLINKS is given
as an additional argument to the FILE command.

This policy was introduced in CMake version 2.6.2.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0010

Next topic

CMP0008

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0009

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0010 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0009" href="CMP0009.html" />
    <link rel="prev" title="CMP0011" href="CMP0011.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0010

CMP0010¶

Bad variable reference syntax is an error.

In CMake 2.6.2 and below, incorrect variable reference syntax such as
a missing close-brace (${FOO) was reported but did not stop
processing of CMake code.  This policy determines whether a bad
variable reference is an error.  The OLD behavior for this policy is
to warn about the error, leave the string untouched, and continue.
The NEW behavior for this policy is to report an error.

If CMP0053 is set to NEW, this policy has no effect
and is treated as always being NEW.

This policy was introduced in CMake version 2.6.3.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0011

Next topic

CMP0009

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0010

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0011 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0010" href="CMP0010.html" />
    <link rel="prev" title="CMP0012" href="CMP0012.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0011

CMP0011¶

Included scripts do automatic cmake_policy() PUSH and POP.

In CMake 2.6.2 and below, CMake Policy settings in scripts loaded by
the include() and find_package() commands would affect
the includer.  Explicit invocations of cmake_policy(PUSH) and
cmake_policy(POP) were required to isolate policy changes and protect
the includer.  While some scripts intend to affect the policies of their
includer, most do not.  In CMake 2.6.3 and above, include() and
find_package() by default PUSH and POP an entry on
the policy stack around an included
script, but provide a NO_POLICY_SCOPE option to disable it.  This
policy determines whether or not to imply NO_POLICY_SCOPE for
compatibility.  The OLD behavior for this policy is to imply
NO_POLICY_SCOPE for include() and find_package() commands.
The NEW behavior for this policy is to allow the commands to do
their default cmake_policy PUSH and POP.

This policy was introduced in CMake version 2.6.3.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0012

Next topic

CMP0010

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0011

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0012 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0011" href="CMP0011.html" />
    <link rel="prev" title="CMP0013" href="CMP0013.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0012

CMP0012¶

if() recognizes numbers and boolean constants.

In CMake versions 2.6.4 and lower the if() command implicitly
dereferenced arguments corresponding to variables, even those named
like numbers or boolean constants, except for 0 and 1.  Numbers and
boolean constants such as true, false, yes, no, on,
off, y, n, notfound, ignore (all case insensitive)
were recognized in some cases but not all.  For example, the code if(TRUE)
might have evaluated as false.
Numbers such as 2 were recognized only in boolean expressions
like if(NOT 2) (leading to false) but not as a single-argument like
if(2) (also leading to false).  Later versions of CMake prefer to
treat numbers and boolean constants literally, so they should not be
used as variable names.

The OLD behavior for this policy is to implicitly dereference
variables named like numbers and boolean constants.  The NEW behavior
for this policy is to recognize numbers and boolean constants without
dereferencing variables with such names.

This policy was introduced in CMake version 2.8.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0013

Next topic

CMP0011

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0012

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0013 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0012" href="CMP0012.html" />
    <link rel="prev" title="CMP0014" href="CMP0014.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0013

CMP0013¶

Duplicate binary directories are not allowed.

CMake 2.6.3 and below silently permitted add_subdirectory() calls to
create the same binary directory multiple times.  During build system
generation files would be written and then overwritten in the build
tree and could lead to strange behavior.  CMake 2.6.4 and above
explicitly detect duplicate binary directories.  CMake 2.6.4 always
considers this case an error.  In CMake 2.8.0 and above this policy
determines whether or not the case is an error.  The OLD behavior for
this policy is to allow duplicate binary directories.  The NEW
behavior for this policy is to disallow duplicate binary directories
with an error.

This policy was introduced in CMake version 2.8.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0014

Next topic

CMP0012

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0013

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0014 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0013" href="CMP0013.html" />
    <link rel="prev" title="CMP0015" href="CMP0015.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0014

CMP0014¶

Input directories must have CMakeLists.txt.

CMake versions before 2.8 silently ignored missing CMakeLists.txt
files in directories referenced by add_subdirectory() or  subdirs(),
treating them as if present but empty.  In CMake 2.8.0 and above this
cmake_policy() determines whether or not the case is an error.
The OLD behavior for this policy is to silently ignore the problem.
The NEW behavior for this policy is to report an error.

This policy was introduced in CMake version 2.8.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0015

Next topic

CMP0013

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0014

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0015 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0014" href="CMP0014.html" />
    <link rel="prev" title="CMP0016" href="CMP0016.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0015

CMP0015¶

link_directories() treats paths relative to the source dir.

In CMake 2.8.0 and lower the link_directories() command passed
relative paths unchanged to the linker.  In CMake 2.8.1 and above the
link_directories() command prefers to interpret relative paths with
respect to CMAKE_CURRENT_SOURCE_DIR, which is consistent with
include_directories() and other commands.  The OLD behavior for
this policy is to use relative paths verbatim in the linker command.  The
NEW behavior for this policy is to convert relative paths to absolute
paths by appending the relative path to CMAKE_CURRENT_SOURCE_DIR.

This policy was introduced in CMake version 2.8.1.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0016

Next topic

CMP0014

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0015

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0016 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0015" href="CMP0015.html" />
    <link rel="prev" title="CMP0017" href="CMP0017.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0016

CMP0016¶

target_link_libraries() reports error if its only argument
is not a target.

In CMake 2.8.2 and lower the target_link_libraries() command silently
ignored if it was called with only one argument, and this argument
wasn't a valid target.  In CMake 2.8.3 and above it reports an error
in this case.

This policy was introduced in CMake version 2.8.3.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0017

Next topic

CMP0015

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0016

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0017 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0016" href="CMP0016.html" />
    <link rel="prev" title="CMP0018" href="CMP0018.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0017

CMP0017¶

Prefer files from the CMake module directory when including from there.

Starting with CMake 2.8.4, if a cmake-module shipped with CMake (i.e.
located in the CMake module directory) calls include() or
find_package(), the files located in the CMake module directory are
preferred over the files in CMAKE_MODULE_PATH.  This makes sure
that the modules belonging to CMake always get those files included which
they expect, and against which they were developed and tested.  In all
other cases, the files found in CMAKE_MODULE_PATH still take
precedence over the ones in the CMake module directory.  The OLD
behavior is to always prefer files from CMAKE_MODULE_PATH over files
from the CMake modules directory.

This policy was introduced in CMake version 2.8.4.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0018

Next topic

CMP0016

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0017

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0018 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0017" href="CMP0017.html" />
    <link rel="prev" title="CMP0019" href="CMP0019.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0018

CMP0018¶

Ignore CMAKE_SHARED_LIBRARY_<Lang>_FLAGS variable.

CMake 2.8.8 and lower compiled sources in SHARED and MODULE libraries
using the value of the undocumented CMAKE_SHARED_LIBRARY_<Lang>_FLAGS
platform variable.  The variable contained platform-specific flags
needed to compile objects for shared libraries.  Typically it included
a flag such as -fPIC for position independent code but also included
other flags needed on certain platforms.  CMake 2.8.9 and higher
prefer instead to use the POSITION_INDEPENDENT_CODE target
property to determine what targets should be position independent, and new
undocumented platform variables to select flags while ignoring
CMAKE_SHARED_LIBRARY_<Lang>_FLAGS completely.

The default for either approach produces identical compilation flags,
but if a project modifies CMAKE_SHARED_LIBRARY_<Lang>_FLAGS from its
original value this policy determines which approach to use.

The OLD behavior for this policy is to ignore the
POSITION_INDEPENDENT_CODE property for all targets and use the
modified value of CMAKE_SHARED_LIBRARY_<Lang>_FLAGS for SHARED and
MODULE libraries.

The NEW behavior for this policy is to ignore
CMAKE_SHARED_LIBRARY_<Lang>_FLAGS whether it is modified or not and
honor the POSITION_INDEPENDENT_CODE target property.

This policy was introduced in CMake version 2.8.9.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0019

Next topic

CMP0017

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0018

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0019 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0018" href="CMP0018.html" />
    <link rel="prev" title="CMP0020" href="CMP0020.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0019

CMP0019¶

Do not re-expand variables in include and link information.

CMake 2.8.10 and lower re-evaluated values given to the
include_directories, link_directories, and link_libraries commands to
expand any leftover variable references at the end of the
configuration step.  This was for strict compatibility with VERY early
CMake versions because all variable references are now normally
evaluated during CMake language processing.  CMake 2.8.11 and higher
prefer to skip the extra evaluation.

The OLD behavior for this policy is to re-evaluate the values for
strict compatibility.  The NEW behavior for this policy is to leave
the values untouched.

This policy was introduced in CMake version 2.8.11.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0020

Next topic

CMP0018

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0019

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0020 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0019" href="CMP0019.html" />
    <link rel="prev" title="CMP0021" href="CMP0021.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0020

CMP0020¶

Automatically link Qt executables to qtmain target on Windows.

CMake 2.8.10 and lower required users of Qt to always specify a link
dependency to the qtmain.lib static library manually on Windows.
CMake 2.8.11 gained the ability to evaluate generator expressions
while determining the link dependencies from IMPORTED targets.  This
allows CMake itself to automatically link executables which link to Qt
to the qtmain.lib library when using IMPORTED Qt targets.  For
applications already linking to qtmain.lib, this should have little
impact.  For applications which supply their own alternative WinMain
implementation and for applications which use the QAxServer library,
this automatic linking will need to be disabled as per the
documentation.

The OLD behavior for this policy is not to link executables to
qtmain.lib automatically when they link to the QtCore IMPORTED target.
The NEW behavior for this policy is to link executables to qtmain.lib
automatically when they link to QtCore IMPORTED target.

This policy was introduced in CMake version 2.8.11.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0021

Next topic

CMP0019

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0020

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0021 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0020" href="CMP0020.html" />
    <link rel="prev" title="CMP0022" href="CMP0022.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0021

CMP0021¶

Fatal error on relative paths in INCLUDE_DIRECTORIES target
property.

CMake 2.8.10.2 and lower allowed the INCLUDE_DIRECTORIES target
property to contain relative paths.  The base path for such relative
entries is not well defined.  CMake 2.8.12 issues a FATAL_ERROR if the
INCLUDE_DIRECTORIES property contains a relative path.

The OLD behavior for this policy is not to warn about relative paths
in the INCLUDE_DIRECTORIES target property.  The NEW behavior for this
policy is to issue a FATAL_ERROR if INCLUDE_DIRECTORIES contains a
relative path.

This policy was introduced in CMake version 2.8.12.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0022

Next topic

CMP0020

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0021

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0022 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0021" href="CMP0021.html" />
    <link rel="prev" title="CMP0023" href="CMP0023.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0022

CMP0022¶

INTERFACE_LINK_LIBRARIES defines the link interface.

CMake 2.8.11 constructed the 'link interface' of a target from
properties matching (IMPORTED_)?LINK_INTERFACE_LIBRARIES(_<CONFIG>)?.
The modern way to specify config-sensitive content is to use generator
expressions and the IMPORTED_ prefix makes uniform processing of the
link interface with generator expressions impossible.  The
INTERFACE_LINK_LIBRARIES target property was introduced as a
replacement in CMake 2.8.12.  This new property is named consistently
with the INTERFACE_COMPILE_DEFINITIONS, INTERFACE_INCLUDE_DIRECTORIES
and INTERFACE_COMPILE_OPTIONS properties.  For in-build targets, CMake
will use the INTERFACE_LINK_LIBRARIES property as the source of the
link interface only if policy CMP0022 is NEW.  When exporting a target
which has this policy set to NEW, only the INTERFACE_LINK_LIBRARIES
property will be processed and generated for the IMPORTED target by
default.  A new option to the install(EXPORT) and export commands
allows export of the old-style properties for compatibility with
downstream users of CMake versions older than 2.8.12.  The
target_link_libraries() command will no longer populate the properties
matching LINK_INTERFACE_LIBRARIES(_<CONFIG>)? if this policy is NEW.

Warning-free future-compatible code which works with CMake 2.8.7 onwards
can be written by using the LINK_PRIVATE and LINK_PUBLIC keywords
of target_link_libraries().

The OLD behavior for this policy is to ignore the
INTERFACE_LINK_LIBRARIES property for in-build targets.
The NEW behavior for this policy is to use the INTERFACE_LINK_LIBRARIES
property for in-build targets, and ignore the old properties matching
(IMPORTED_)?LINK_INTERFACE_LIBRARIES(_<CONFIG>)?.

This policy was introduced in CMake version 2.8.12.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0023

Next topic

CMP0021

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0022

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0023 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0022" href="CMP0022.html" />
    <link rel="prev" title="CMP0024" href="CMP0024.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0023

CMP0023¶

Plain and keyword target_link_libraries() signatures cannot be mixed.

CMake 2.8.12 introduced the target_link_libraries() signature using
the PUBLIC, PRIVATE, and INTERFACE keywords to generalize the
LINK_PUBLIC and LINK_PRIVATE keywords introduced in CMake 2.8.7.
Use of signatures with any of these keywords sets the link interface of a
target explicitly, even if empty.  This produces confusing behavior
when used in combination with the historical behavior of the plain
target_link_libraries() signature.  For example, consider the code:

target_link_libraries(mylib A)
target_link_libraries(mylib PRIVATE B)

After the first line the link interface has not been set explicitly so
CMake would use the link implementation, A, as the link interface.
However, the second line sets the link interface to empty.  In order
to avoid this subtle behavior CMake now prefers to disallow mixing the
plain and keyword signatures of target_link_libraries() for a single
target.

The OLD behavior for this policy is to allow keyword and plain
target_link_libraries() signatures to be mixed.  The NEW behavior for
this policy is to not to allow mixing of the keyword and plain
signatures.

This policy was introduced in CMake version 2.8.12.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0024

Next topic

CMP0022

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0023

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0024 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0023" href="CMP0023.html" />
    <link rel="prev" title="CMP0025" href="CMP0025.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0024

CMP0024¶

Disallow include export result.

CMake 2.8.12 and lower allowed use of the include() command with the
result of the export() command.  This relies on the assumption that
the export() command has an immediate effect at configure-time during
a cmake run.  Certain properties of targets are not fully determined
until later at generate-time, such as the link language and complete
list of link libraries.  Future refactoring will change the effect of
the export() command to be executed at generate-time.  Use ALIAS
targets instead in cases where the goal is to refer to targets by
another name.

The OLD behavior for this policy is to allow including the result of
an export() command.  The NEW behavior for this policy is not to
allow including the result of an export() command.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0025

Next topic

CMP0023

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0024

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0025 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0024" href="CMP0024.html" />
    <link rel="prev" title="CMP0026" href="CMP0026.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0025

CMP0025¶

Compiler id for Apple Clang is now AppleClang.

CMake 3.0 and above recognize that Apple Clang is a different compiler
than upstream Clang and that they have different version numbers.
CMake now prefers to present this to projects by setting the
CMAKE_<LANG>_COMPILER_ID variable to AppleClang instead
of Clang.  However, existing projects may assume the compiler id for
Apple Clang is just Clang as it was in CMake versions prior to 3.0.
Therefore this policy determines for Apple Clang which compiler id to
report in the CMAKE_<LANG>_COMPILER_ID variable after
language <LANG> is enabled by the project() or
enable_language() command.  The policy must be set prior
to the invocation of either command.

The OLD behavior for this policy is to use compiler id Clang.  The
NEW behavior for this policy is to use compiler id AppleClang.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake does not warn by default, and uses OLD behavior.

See documentation of the
CMAKE_POLICY_WARNING_CMP0025
variable to control the warning.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0026

Next topic

CMP0024

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0025

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0026 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0025" href="CMP0025.html" />
    <link rel="prev" title="CMP0027" href="CMP0027.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0026

CMP0026¶

Disallow use of the LOCATION property for build targets.

CMake 2.8.12 and lower allowed reading the LOCATION target
property (and configuration-specific variants) to
determine the eventual location of build targets.  This relies on the
assumption that all necessary information is available at
configure-time to determine the final location and filename of the
target.  However, this property is not fully determined until later at
generate-time.  At generate time, the $<TARGET_FILE> generator
expression can be used to determine the eventual LOCATION of a target
output.

Code which reads the LOCATION target property can be ported to
use the $<TARGET_FILE> generator expression together with the
file(GENERATE) subcommand to generate a file containing
the target location.

The OLD behavior for this policy is to allow reading the LOCATION
properties from build-targets.  The NEW behavior for this policy is to
not to allow reading the LOCATION properties from build-targets.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0027

Next topic

CMP0025

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0026

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0027 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0026" href="CMP0026.html" />
    <link rel="prev" title="CMP0028" href="CMP0028.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0027

CMP0027¶

Conditionally linked imported targets with missing include directories.

CMake 2.8.11 introduced introduced the concept of
INTERFACE_INCLUDE_DIRECTORIES, and a check at cmake time that the
entries in the INTERFACE_INCLUDE_DIRECTORIES of an IMPORTED
target actually exist.  CMake 2.8.11 also introduced generator expression
support in the target_link_libraries() command.  However, if an
imported target is linked as a result of a generator expression evaluation, the
entries in the INTERFACE_INCLUDE_DIRECTORIES of that target were not
checked for existence as they should be.

The OLD behavior of this policy is to report a warning if an entry in
the INTERFACE_INCLUDE_DIRECTORIES of a generator-expression
conditionally linked IMPORTED target does not exist.

The NEW behavior of this policy is to report an error if an entry in
the INTERFACE_INCLUDE_DIRECTORIES of a generator-expression
conditionally linked IMPORTED target does not exist.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0028

Next topic

CMP0026

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0027

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0028 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0027" href="CMP0027.html" />
    <link rel="prev" title="CMP0029" href="CMP0029.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0028

CMP0028¶

Double colon in target name means ALIAS or IMPORTED target.

CMake 2.8.12 and lower allowed the use of targets and files with double
colons in target_link_libraries(), with some buildsystem generators.

The use of double-colons is a common pattern used to namespace IMPORTED
targets and ALIAS targets.  When computing the link dependencies of
a target, the name of each dependency could either be a target, or a file
on disk.  Previously, if a target was not found with a matching name, the name
was considered to refer to a file on disk.  This can lead to confusing error
messages if there is a typo in what should be a target name.

See also the LINK_LIBRARIES_ONLY_TARGETS target property.

The OLD behavior for this policy is to search for targets, then files on
disk, even if the search term contains double-colons.  The NEW behavior
for this policy is to issue a FATAL_ERROR if a link dependency contains
double-colons but is not an IMPORTED target or an ALIAS target.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0029

Next topic

CMP0027

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0028

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0029 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0028" href="CMP0028.html" />
    <link rel="prev" title="CMP0030" href="CMP0030.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0029

CMP0029¶

The subdir_depends() command should not be called.

The implementation of this command has been empty since December 2001
but was kept in CMake for compatibility for a long time.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0030

Next topic

CMP0028

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0029

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0030 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0029" href="CMP0029.html" />
    <link rel="prev" title="CMP0031" href="CMP0031.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0030

CMP0030¶

The use_mangled_mesa() command should not be called.

This command was created in September 2001 to support VTK before
modern CMake language and custom command capabilities.  VTK has
not used it in years.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0031

Next topic

CMP0029

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0030

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0031 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0030" href="CMP0030.html" />
    <link rel="prev" title="CMP0032" href="CMP0032.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0031

CMP0031¶

The load_command() command should not be called.

This command was added in August 2002 to allow projects to add
arbitrary commands implemented in C or C++.  However, it does
not work when the toolchain in use does not match the ABI of
the CMake process.  It has been mostly superseded by the
macro() and function() commands.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0032

Next topic

CMP0030

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0031

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0032 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0031" href="CMP0031.html" />
    <link rel="prev" title="CMP0033" href="CMP0033.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0032

CMP0032¶

The output_required_files() command should not be called.

This command was added in June 2001 to expose the then-current CMake
implicit dependency scanner.  CMake's real implicit dependency scanner
has evolved since then but is not exposed through this command.  The
scanning capabilities of this command are very limited and this
functionality is better achieved through dedicated outside tools.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0033

Next topic

CMP0031

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0032

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0033 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0032" href="CMP0032.html" />
    <link rel="prev" title="CMP0034" href="CMP0034.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0033

CMP0033¶

The export_library_dependencies() command should not be called.

This command was added in January 2003 to export <tgt>_LIB_DEPENDS
internal CMake cache entries to a file for installation with a project.
This was used at the time to allow transitive link dependencies to
work for applications outside of the original build tree of a project.
The functionality has been superseded by the export() and
install(EXPORT) commands.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0034

Next topic

CMP0032

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0033

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0034 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0033" href="CMP0033.html" />
    <link rel="prev" title="CMP0035" href="CMP0035.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0034

CMP0034¶

The utility_source() command should not be called.

This command was introduced in March 2001 to help build executables used to
generate other files.  This approach has long been replaced by
add_executable() combined with add_custom_command().

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0035

Next topic

CMP0033

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0034

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0035 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0034" href="CMP0034.html" />
    <link rel="prev" title="CMP0036" href="CMP0036.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0035

CMP0035¶

The variable_requires() command should not be called.

This command was introduced in November 2001 to perform some conditional
logic.  It has long been replaced by the if() command.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0036

Next topic

CMP0034

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0035

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0036 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0035" href="CMP0035.html" />
    <link rel="prev" title="CMP0037" href="CMP0037.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0036

CMP0036¶

The build_name() command should not be called.

This command was added in May 2001 to compute a name for the current
operating system and compiler combination.  The command has long been
documented as discouraged and replaced by the CMAKE_SYSTEM
and CMAKE_<LANG>_COMPILER variables.

CMake >= 3.0 prefer that this command never be called.
The OLD behavior for this policy is to allow the command to be called.
The NEW behavior for this policy is to issue a FATAL_ERROR when the
command is called.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0037

Next topic

CMP0035

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0036

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0037 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0036" href="CMP0036.html" />
    <link rel="prev" title="CMP0038" href="CMP0038.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0037

CMP0037¶

Target names should not be reserved and should match a validity pattern.

CMake 2.8.12 and lower allowed creating targets using add_library(),
add_executable() and add_custom_target() with unrestricted
choice for the target name.  Newer cmake features such
as cmake-generator-expressions(7) and some
diagnostics expect target names to match a restricted pattern.

Target names may contain upper and lower case letters, numbers, the underscore
character (_), dot(.), plus(+) and minus(-).
As a special case, ALIAS and IMPORTED targets may contain
two consecutive colons.

Target names reserved by one or more CMake generators are not allowed.
Among others these include all, clean, help, and install.

Target names associated with optional features, such as test and
package, may also be reserved.  CMake 3.10 and below always reserve them.
CMake 3.11 and above reserve them only when the corresponding feature is
enabled (e.g. by including the CTest or CPack modules).

The OLD behavior for this policy is to allow creating targets with
reserved names or which do not match the validity pattern.
The NEW behavior for this policy is to report an error
if an add_* command is used with an invalid target name.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0038

Next topic

CMP0036

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0037

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0038 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0037" href="CMP0037.html" />
    <link rel="prev" title="CMP0039" href="CMP0039.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0038

CMP0038¶

Targets may not link directly to themselves.

CMake 2.8.12 and lower allowed a build target to link to itself directly with
a target_link_libraries() call. This is an indicator of a bug in
user code.

The OLD behavior for this policy is to ignore targets which list themselves
in their own link implementation.  The NEW behavior for this policy is to
report an error if a target attempts to link to itself.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0039

Next topic

CMP0037

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0038

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.


code:
<!DOCTYPE html>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

  <title>CMP0039 — CMake 3.29.0-rc3 Documentation</title>

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/cmake.css" />

    <link rel="icon" href="../_static/cmake-favicon.ico"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="CMP0038" href="CMP0038.html" />
    <link rel="prev" title="CMP0040" href="CMP0040.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0039

CMP0039¶

Utility targets may not have link dependencies.

CMake 2.8.12 and lower allowed using utility targets in the left hand side
position of the target_link_libraries() command. This is an indicator
of a bug in user code.

The OLD behavior for this policy is to ignore attempts to set the link
libraries of utility targets.  The NEW behavior for this policy is to
report an error if an attempt is made to set the link libraries of a
utility target.

This policy was introduced in CMake version 3.0.
It may be set by cmake_policy() or cmake_minimum_required().
If it is not set, CMake warns, and uses OLD behavior.

Note

The OLD behavior of a policy is
deprecated by definition
and may be removed in a future version of CMake.

Previous topic

CMP0040

Next topic

CMP0038

This Page

Show Source

Quick search

    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
      <input type="submit" value="Go" />
    </form>

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

cmake-policies(7) »

CMP0039

        © Copyright 2000-2024 Kitware, Inc. and Contributors.
      Created using Sphinx 6.2.1.