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>CMake 3.17 Release Notes — 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="CMake 3.16 Release Notes" href="3.16.html" />
    <link rel="prev" title="CMake 3.18 Release Notes" href="3.18.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.17 Release Notes

CMake 3.17 Release Notes¶

Contents

CMake 3.17 Release Notes

New Features

Generators

Languages

Compilers

Command-Line

Commands

Variables

Properties

Modules

Autogen

CTest

CPack

Other

Deprecated and Removed Features

Other Changes

Updates

3.17.1

3.17.3

3.17.5

Changes made since CMake 3.16 include the following.

New Features¶

Generators¶

cmake(1) gained a Ninja Multi-Config generator,
which is similar to the Ninja generator but can be used to build
multiple configurations at once.

Visual Studio Generators learned to support per-config sources.
Previously only Command-Line Build Tool Generators supported them.

Visual Studio Generators for VS 2010 and above now support
specifying the VCTargetsPath value for project files in
CMAKE_GENERATOR_TOOLSET setting.

Visual Studio Generators for VS 2010 and above learned to
support .NET Standard and .NET Core.  See the
DOTNET_TARGET_FRAMEWORK target property and
associated CMAKE_DOTNET_TARGET_FRAMEWORK variable.

Languages¶

The Compile Features functionality
now offers meta-features for the CUDA language standard levels
(e.g. cuda_std_03, cuda_std_14).  See
CMAKE_CUDA_KNOWN_FEATURES.

Compilers¶

The IBM XL Fortran compiler is now supported by the Ninja
generator.

Command-Line¶

cmake(1) gained a --debug-find command-line option to
enable additional human-readable output on where find_* commands search.

cmake(1) gained a --trace-format command-line option that
can be used to set the --trace output format. Currently, the old
human readable and the new JSON format are supported. The new JSON format
is easier to parse automatically than the existing format.

cmake(1) gained a -E rm command-line tool that can be
used to remove directories and files.  This supersedes the existing
-E remove and -E remove_directory tools and has better semantics.

Commands¶

The add_custom_command() command learned to interpret paths in
DEPENDS arguments that are specified relative to the current
binary directory.

The foreach() command learned a new ZIP_LISTS option to iterate
over multiple lists simultaneously.

The load_cache(READ_WITH_PREFIX) command mode is now allowed
when using cmake -P to Run a Script.

The message() command learned to output context provided in
the CMAKE_MESSAGE_CONTEXT variable for log levels
NOTICE and below.  Enable this output with the new --log-context
command-line option or CMAKE_MESSAGE_CONTEXT_SHOW variable.

The message() command gained new keywords CHECK_START,
CHECK_PASS and CHECK_FAIL.

The target_compile_options() command now honors the BEFORE
keyword more consistently.  See policy CMP0101.

Variables¶

A CMAKE_CTEST_ARGUMENTS variable was added to specify a list
of command-line arguments passed to CTest when running through the
test (or RUN_TESTS) target of the generated build system.

The following variables are now defined inside a function():

CMAKE_CURRENT_FUNCTION

CMAKE_CURRENT_FUNCTION_LIST_DIR

CMAKE_CURRENT_FUNCTION_LIST_FILE

CMAKE_CURRENT_FUNCTION_LIST_LINE

The CMAKE_CUDA_RUNTIME_LIBRARY variable and
CUDA_RUNTIME_LIBRARY target property were introduced to
select the CUDA runtime library used when linking targets that
use CUDA.

The CMAKE_FIND_DEBUG_MODE variable was introduced to
print extra find_* call information during the cmake run to standard
error. Output is designed for human consumption and not for parsing.

The CMAKE_EXPORT_COMPILE_COMMANDS variable now takes its
initial value from the CMAKE_EXPORT_COMPILE_COMMANDS environment
variable if no explicit configuration is given.

The CMAKE_<LANG>_COMPILER_LAUNCHER variable, if not set
explicitly, now takes its initial value from the
CMAKE_<LANG>_COMPILER_LAUNCHER environment variable.

The CMAKE_MESSAGE_LOG_LEVEL variable can now be used
to persist a log level between CMake runs, unlike the --log-level
command line option which only applies to that particular run.

The CMAKE_XCODE_SCHEME_ENVIRONMENT variable was added
to initialize the XCODE_SCHEME_ENVIRONMENT target property.

The CMAKE_XCODE_SCHEME_WORKING_DIRECTORY variable and
associated XCODE_SCHEME_WORKING_DIRECTORY target property
were added to tell the Xcode generator to set the value of
the Custom Working Directory schema option.

Properties¶

The AIX_EXPORT_ALL_SYMBOLS target property and associated
CMAKE_AIX_EXPORT_ALL_SYMBOLS variable were created to
optionally explicitly disable automatic export of symbols from shared
libraries on AIX.

The DEPRECATION target property was added to mark
a target as deprecated.  If a linked target is marked as
deprecated, a warning with the deprecation message is issued
at generate time.

The INSTALL_NAME_DIR target property now supports
generator expressions.
In particular, the $<INSTALL_PREFIX> generator expression can
be used to set the directory relative to the install-time prefix.

Target properties MACHO_COMPATIBILITY_VERSION and
MACHO_CURRENT_VERSION were added to set the
compatibility_version and curent_version, respectively,
for Mach-O binaries.  For backwards compatibility, if these properties
are not set, SOVERSION and VERSION
are used respectively as fallbacks.

The VS_DOTNET_DOCUMENTATION_FILE target property was added
to tell Visual Studio Generators to generate a DocumentationFile
reference in .csproj files.

Modules¶

The ExternalProject module ExternalProject_Add()
command gained a GIT_SUBMODULES_RECURSE option to specify whether
Git submodules should be updated recursively.  The default is on to
preserve existing behavior.

The FindCUDAToolkit module was added to find the
CUDA Toolkit without enabling CUDA as a language.

The FindCURL module learned to find CURL using
the CURLConfig.cmake package configuration file generated by
CURL's cmake buildsystem.  It also gained a new CURL_NO_CURL_CMAKE
option to disable this behavior.

The FindFLEX module's FLEX_TARGET command now runs flex
with CMAKE_CURRENT_BINARY_DIR as the working directory.
See policy CMP0098.

The FindLibArchive module now provides an imported target
for libarchive.

The FindPython module has learned to find Python components
in active virtual environments managed by conda.

The FindPython3 and FindPython modules gained,
respectively, variable Python3_SOABI and Python_SOABI giving
the standard extension suffix for modules. Moreover, commands
Python3_add_library() and Python_add_library() gained the option
WITH_SOABI to prefix the library suffix with the value of SOABI.

The FindLibXml2 module now provides an imported target for the
xmllint executable.

Autogen¶

AUTOMOC and AUTOUIC learned to process headers
with a .hh extension.  See policy CMP0100.

CTest¶

The CTEST_CONFIGURATION_TYPE variable is now set from the
command line when ctest(1) is invoked with -C <cfg>.

The ctest(1) tool gained support for Dr. Memory to run
memcheck runs.

The ctest(1) tool gained a --no-tests=<[error|ignore]> option
to explicitly set and unify the behavior between direct invocation and
script mode if no tests were found.

The ctest(1) tool gained a --repeat <mode>:<n> option
to specify conditions in which to repeat tests.  This generalizes
the existing --repeat-until-fail <n> option to add modes for
until-pass and after-timeout.

The ctest_test() command gained a REPEAT <mode>:<n> option
to specify conditions in which to repeat tests.

CPack¶

The CPack DragNDrop Generator learned to use
the CPACK_DMG_<component>_FILE_NAME variable
to set a custom filename when packaging components into
their own DMGs.

The CPack DragNDrop Generator learned to handle
RTF formatted license files.  When CPACK_DMG_SLA_DIR
variable is set, <language>.license.rtf is considered, but
only as a fallback when the plaintext (.txt) file is not found
in order to maintain backwards compatibility.

The CPack NSIS Generator gained a new variable
CPACK_NSIS_MUI_HEADERIMAGE to set the header image.
To not break existing setups, it still defaults to
CPACK_PACKAGE_ICON if the new variable is not set.

The CPack NSIS Generator now supports
CPACK_NSIS_UNINSTALL_NAME.
This can be used to specify the name of the Uninstall program.

The CPack NSIS Generator now supports
CPACK_NSIS_WELCOME_TITLE and
CPACK_NSIS_WELCOME_TITLE_3LINES.
These can be used to specify the welcome page title and display it in 3 lines.

The CPack NSIS Generator now supports
CPACK_NSIS_FINISH_TITLE and
CPACK_NSIS_FINISH_TITLE_3LINES.
These can be used to specify the finish page title and display it in 3 lines.

The CPack productbuild Generator gained support for a
CPACK_PRODUCTBUILD_BACKGROUND variable to specify a background
image for the macOS installer.

Other¶

ccmake(1) now displays cache values using colors
based on the entry type if the terminal supports color.

ccmake(1) now displays messages and a progress bar during
configure and generate.  It will keep the output displayed if any
errors or warnings occurred.

Deprecated and Removed Features¶

An explicit deprecation diagnostic was added for policy CMP0068
and policy CMP0069 (CMP0067 and below were already deprecated).
The cmake-policies(7) manual explains that the OLD behaviors
of all policies are deprecated and that projects should port to the
NEW behaviors.

The CPack PackageMaker generator has been
deprecated because Xcode no longer distributes the PackageMaker tools.
The undocumented OSXX11 generator has also been deprecated.

The cmake(1) command-line -E remove and -E remove_directory
tools are deprecated in favor of the new -E rm tool.  The older tools
always returned 0 if a named path did not exist even without the force
option and cannot be fixed without breaking compatibility, and so have
been superseded.

The CPack NSIS Generator now requires NSIS 3.0 or later.

Other Changes¶

The file API index file now emits a
multiConfig flag specifying whether or not the generator supports
multiple output configurations.

Target link properties INTERFACE_LINK_OPTIONS,
INTERFACE_LINK_DIRECTORIES and
INTERFACE_LINK_DEPENDS are now transitive over private
dependencies on static libraries.
See policy CMP0099.

When using MinGW tools, the find_library() command no longer
finds .dll files by default.  Instead, it expects .dll.a import
libraries to be available.

The MinGW Makefiles generator no longer issues an error if
sh.exe is present in the environment's PATH.

The Ninja generator now prefers the first ninja build
tool to appear in the PATH no matter whether it is called
ninja-build, ninja, or samu.  Previously the first
of those names to appear anywhere in the PATH would be preferred.

With SDCC the sdar tool is now preferred over sdcclib as librarian.
The latter was deprecated by SDCC 3.2.0 and removed in SDCC 3.8.6.

With SDCC the default flags no longer include any target-specific flags.
Previously the default flags were hard-coded for 8051.

The CMAKE_VS_GLOBALS variable value now applies during
compiler identification and in targets created by the
add_custom_target() command.

The Xcode generator no longer hard-codes -Wmost,
-Wno-four-char-constants, and -Wno-unknown-pragmas warning flags.

Updates¶

Changes made since CMake 3.17.0 include the following.

3.17.1¶

CMake 3.17.0 updated the CPack NSIS Generator with changes
that require NSIS 3.0 or later.  CMake 3.17.1 now enforces the use
of a sufficiently new version.

3.17.3¶

Selection of the Objective C or C++ compiler now considers the
CC or CXX environment variable if the
OBJC or OBJCXX environment variable is not set.

The FindPkgConfig module now extracts include directories
prefixed with -isystem into the *_INCLUDE_DIRS variables and
INTERFACE_INCLUDE_DIRECTORIES target properties.
Previously they would be places in *_CFLAGS_OTHER variables and
INTERFACE_COMPILE_OPTIONS target properties.

3.17.5¶

The default value of CMAKE_AUTOMOC_PATH_PREFIX was changed to
OFF because this feature can break existing projects that have
identically named header files in different include directories.
This restores compatibility with behavior of CMake 3.15 and below.
The default was also changed to OFF in 3.16.9.

Table of Contents

CMake 3.17 Release Notes

New Features

Generators

Languages

Compilers

Command-Line

Commands

Variables

Properties

Modules

Autogen

CTest

CPack

Other

Deprecated and Removed Features

Other Changes

Updates

3.17.1

3.17.3

3.17.5

Previous topic

CMake 3.18 Release Notes

Next topic

CMake 3.16 Release Notes

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 Release Notes »

CMake 3.17 Release Notes

        © 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>CMake 3.18 Release Notes — 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="CMake 3.17 Release Notes" href="3.17.html" />
    <link rel="prev" title="CMake 3.19 Release Notes" href="3.19.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.18 Release Notes

CMake 3.18 Release Notes¶

Contents

CMake 3.18 Release Notes

New Features

Languages

Command-Line

Commands

Variables

Properties

Modules

Generator Expressions

CTest

CPack

Other

Deprecated and Removed Features

Other Changes

Updates

3.18.1

3.18.2

3.18.3

Changes made since CMake 3.17 include the following.

New Features¶

Languages¶

The CUDA language can now be compiled using Clang on non-Windows
platforms. Separable compilation is not yet supported on any platform.

Command-Line¶

cmake(1) gained support for profiling of CMake scripts through
the parameters --profiling-output and --profiling-format.

cmake(1) gained a cat command line
option that can be used to concatenate files and print them
on standard output.

Commands¶

The add_library() and add_executable() commands
learned to create Alias Targets referencing non-GLOBAL
Imported Targets.

The cmake_language() command was added for meta-operations on
scripted or built-in commands, starting with a mode to CALL other
commands, and EVAL CODE to inplace evaluate a CMake script.

The execute_process() command gained the ECHO_OUTPUT_VARIABLE
and ECHO_ERROR_VARIABLE options.

The export() command now raise an error if used multiple times with
same FILE without APPEND. See policy CMP0103.

The file() command gained the ARCHIVE_CREATE and
ARCHIVE_EXTRACT subcommands to expose the cmake(1) -E tar
functionality to CMake scripting code.

The file(CONFIGURE) subcommand was created in order to replicate
the configure_file() functionality without resorting to a
pre-existing file on disk as input. The content is instead passed as a
string.

The file(UPLOAD) command gained TLS_VERIFY and TLS_CAINFO
options to control server certificate verification.

The find_program(), find_library(), find_path()
and find_file() commands gained a new REQUIRED option that will
stop processing with an error message if nothing is found.

The get_property() command with SOURCE scope gained the
DIRECTORY and TARGET_DIRECTORY options to get a property
from the provided directory scope.

The get_source_file_property() command gained the DIRECTORY
and TARGET_DIRECTORY options to get a property from the
provided directory scope.

The list() operation SORT gained the NATURAL sort
option to sort using natural order (see strverscmp(3) manual).

The set_property() command with the SOURCE scope gained the
DIRECTORY and TARGET_DIRECTORY options to set properties
in the provided directory scopes.

The set_source_files_properties() command gained the DIRECTORY
and TARGET_DIRECTORY options to set properties in the provided
directory scopes.

The string() command learned a new HEX sub-command, which
converts strings into their hexadecimal representation.

Variables¶

A CMAKE_CUDA_ARCHITECTURES variable was added to specify
CUDA output architectures.  Users are encouraged to use this instead of
specifying options manually, as this approach is compiler-agnostic.
The variable is initialized automatically when
CMAKE_CUDA_COMPILER_ID is NVIDIA.
The variable is used to initialize the new CUDA_ARCHITECTURES
target property.  See policy CMP0104.

The CMAKE_PCH_WARN_INVALID variable was added to initialize the
PCH_WARN_INVALID target property to allow the removal of the
precompiled header invalid warning.

Properties¶

The CUDA_ARCHITECTURES target property was added to specify
CUDA output architectures. Users are encouraged to use this instead of
specifying options manually, as this approach is compiler-agnostic.
The property is initialized by the new CMAKE_CUDA_ARCHITECTURES
variable.  See policy CMP0104.

The Fortran_PREPROCESS target property and
Fortran_PREPROCESS source-file property were added to
control preprocessing of Fortran source files.

The FRAMEWORK_MULTI_CONFIG_POSTFIX_<CONFIG> target property
and associated CMAKE_FRAMEWORK_MULTI_CONFIG_POSTFIX_<CONFIG>
variable were created to allow adding a postfix to the name of a
framework file name when using a multi-config generator.

The OBJECT_OUTPUTS source file property now supports
generator expressions.

The PCH_WARN_INVALID target property was added to allow the
removal of the precompiled header invalid warning.

The UNITY_BUILD_MODE target property was added to tell
generators which algorithm to use for grouping included source
files.

The VS_SOURCE_SETTINGS_<tool> target property was added
to tell Visual Studio Generators for VS 2010 and above to add
metadata to non-built source files using <tool>.

The VS_SETTINGS source file property was added to tell
Visual Studio Generators for VS 2010 and above to add
metadata to a non-built source file.

The VS_PLATFORM_TOOLSET target property was added to tell
Visual Studio Generators for VS 2010 and above to override
the platform toolset.

The VS_SOLUTION_DEPLOY target property was added to tell
Visual Studio Generators for VS 2010 and above to mark a
target for deployment even when not building for Windows Phone/Store/CE.

Modules¶

The CheckLinkerFlag module has been added to provide a
facility to check validity of link flags.

The ExternalProject module ExternalProject_Add() command
gained a new GIT_REMOTE_UPDATE_STRATEGY keyword.  This can be used to
specify how failed rebase operations during a git update should be handled.
The CMAKE_EP_GIT_REMOTE_UPDATE_STRATEGY variable was also added as a
global default and is honored by both the ExternalProject and
FetchContent modules.

The FetchContent module FetchContent_Declare() command
now supports a SOURCE_SUBDIR option.  It can be used to direct
FetchContent_MakeAvailable() to look in a different location
for the CMakeLists.txt file.

The FindBLAS module now provides an imported target.

The FindCUDAToolkit module:

gained the variable
CUDAToolkit_LIBRARY_ROOT, which is the directory containing the
nvvm directory and version.txt.

uses toolkit and library root found during CUDA compiler detection.

The FindLAPACK module now provides an imported target.

The FindPython3, FindPython2 and FindPython
modules:

gained the possibility to create per-artifact cache variables for
interactive editing in cmake-gui(1) and ccmake(1).

gained sub-components Development.Module and
Development.Embed under the Development component.

gained the capability to specify which Python implementations to find,
including IronPython and PyPy.

The FindRuby module input and output variables were all renamed
from RUBY_ to Ruby_ for consistency with other find modules.
Input variables of the old case will be honored if provided, and output
variables of the old case are always provided.

The FindSWIG module now accepts target languages as  COMPONENTS
and OPTIONAL_COMPONENTS arguments to find_package.

The GoogleTest module gtest_discover_tests() command:

gained a new DISCOVERY_MODE option to control when the test
discovery step is run.  It offers a new PRE_TEST setting to
run the discovery at test time instead of build time.  A new
CMAKE_GTEST_DISCOVER_TESTS_DISCOVERY_MODE variable can be used
to change the default globally.

gained a new optional parameter XML_OUTPUT_DIR. When set the
JUnit XML test results are stored in that directory.

The FindLibXslt module now provides imported targets.

The UseSWIG module now supports Fortran as a target language if
the SWIG_EXECUTABLE is SWIG-Fortran.

Generator Expressions¶

The $<DEVICE_LINK:...> and $<HOST_LINK:...>
generator expressions were added to manage device and host link steps.

The $<LINK_LANGUAGE:...> and $<LINK_LANG_AND_ID:...>
generator expressions were added.

CTest¶

ctest(1) gained a new CTEST_RESOURCE_SPEC_FILE
variable, which can be used to specify a
resource specification file.

ctest(1) gained a --stop-on-failure option,
which can be used to stop running the tests once one has failed.

The ctest_test() command gained a STOP_ON_FAILURE option
which can be used to stop running the tests once one has failed.

The CTestCoverageCollectGCOV module
ctest_coverage_collect_gcov() command gained a
TARBALL_COMPRESSION option to control compression of the
tarball of collected results.

CPack¶

The CPack Archive Generator's TXZ format learned the
CPACK_ARCHIVE_THREADS variable to enable parallel compression.
Requires support in the liblzma used by CMake.

The CPack NSIS Generator gained a new variable
CPACK_NSIS_MANIFEST_DPI_AWARE to declare that the
installer is DPI-aware.

The CPack RPM Generator gained
CPACK_RPM_PRE_TRANS_SCRIPT_FILE and
CPACK_RPM_POST_TRANS_SCRIPT_FILE
variables to specify pre- and post-transaction scripts.

Other¶

cmake-gui(1) now populates its generator selection
widget default value from the CMAKE_GENERATOR environment
variable.  Additionally, environment variables
CMAKE_GENERATOR_PLATFORM and CMAKE_GENERATOR_TOOLSET
are used to populate their respective widget defaults.

ccmake(1) learned to read a CCMAKE_COLORS
environment variable to customize colors.

The Compile Features functionality
is now aware of the availability of C11 features in MSVC 19.27 and 19.28,
including support for the c_restrict, c_static_assert features and
the -std:c11 flag.

Deprecated and Removed Features¶

The Documentation module has been deprecated via
CMP0106. This module was essentially VTK code that CMake should
not be shipping anymore.

An explicit deprecation diagnostic was added for policy CMP0070
and policy CMP0071 (CMP0069 and below were already deprecated).
The cmake-policies(7) manual explains that the OLD behaviors
of all policies are deprecated and that projects should port to the
NEW behaviors.

Other Changes¶

On Windows, the Ninja and Ninja Multi-Config
generators, when a compiler is not explicitly specified, now select
the first compiler (of any name) found in directories listed by the
PATH environment variable.

The LINK_OPTIONS and INTERFACE_LINK_OPTIONS target
properties are now used for the device link step.
See policy CMP0105.

Creation of an ALIAS target overwriting an existing target now raises an
error. See policy CMP0107.

Linking a target to itself through an alias now raises an error.
See policy CMP0108.

The FindPackageHandleStandardArgs module option REQUIRED_VARS
is now optional if HANDLE_COMPONENTS is specified.

The source_group() command now also recognizes forward slashes
as subgroup delimiters, not just backslashes.

ctest(1) now logs environment variables that it sets for each test,
either due to the ENVIRONMENT property or the
resource allocation feature, and submits
this log to CDash. It does not log environment variables that were set
outside of CTest.

When building CMake itself from source and not using a system-provided
libcurl, HTTP/2 support is now enabled for commands supporting
network communication via http(s), such as file(DOWNLOAD),
file(UPLOAD), and ctest_submit().
The precompiled binaries provided on cmake.org now support HTTP/2.

The cmake-file-api(7) "codemodel" version 2 version field has
been updated to 2.1.

The cmake-file-api(7) "codemodel" version 2 "target" object gained
a new precompileHeaders field in the compileGroups objects.

Updates¶

Changes made since CMake 3.18.0 include the following.

3.18.1¶

The Xcode generator, when CMAKE_OSX_ARCHITECTURES
is not defined, now selects $(NATIVE_ARCH_ACTUAL) as the default
architecture (the Xcode ARCHS setting).  This is needed for Xcode 12
to select the host's architecture, which older versions of Xcode did
by default.

In CMake 3.18.0 the add_test() command learned to support
special characters in test names.  This was accidentally left out of
its release notes.  Unfortunately the fix breaks existing projects
that were using manual quoting or escaping to work around the prior
limitation.  This fix has been reverted in 3.18.1, but may be
re-introduced in future versions of CMake with a policy for compatibility.

3.18.2¶

The default value of CMAKE_AUTOMOC_PATH_PREFIX was changed to
OFF because this feature can break existing projects that have
identically named header files in different include directories.
This restores compatibility with behavior of CMake 3.15 and below.
The default was also changed to OFF in 3.16.9 and 3.17.5.

The Compile Features functionality
was updated for MSVC 19.27 as mentioned above (c_restrict).

3.18.3¶

The Compile Features functionality
was updated for MSVC 19.28 as mentioned above (c_static_assert).

Table of Contents

CMake 3.18 Release Notes

New Features

Languages

Command-Line

Commands

Variables

Properties

Modules

Generator Expressions

CTest

CPack

Other

Deprecated and Removed Features

Other Changes

Updates

3.18.1

3.18.2

3.18.3

Previous topic

CMake 3.19 Release Notes

Next topic

CMake 3.17 Release Notes

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 Release Notes »

CMake 3.18 Release Notes

        © 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>CMake 3.19 Release Notes — 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="CMake 3.18 Release Notes" href="3.18.html" />
    <link rel="prev" title="CMake 3.20 Release Notes" href="3.20.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.19 Release Notes

CMake 3.19 Release Notes¶

Contents

CMake 3.19 Release Notes

New Features

Presets

Generators

Languages

Platforms

File-Based API

Command-Line

GUI

Commands

Variables

Properties

Modules

CTest

CPack

Other

Deprecated and Removed Features

Documentation

Other Changes

Updates

3.19.1

3.19.2

3.19.3

3.19.4

3.19.5

3.19.6

3.19.7

Changes made since CMake 3.18 include the following.

New Features¶

Presets¶

cmake(1) and cmake-gui(1) now recognize
CMakePresets.json and CMakeUserPresets.json files (see
cmake-presets(7)).

Generators¶

The Xcode generator now uses the Xcode "new build system"
when generating for Xcode 12.0 or higher.
See the CMAKE_XCODE_BUILD_SYSTEM variable.
One may use -T buildsystem=1 to switch to the legacy build system.

The Xcode generator gained support for linking libraries and
frameworks via the Link Binaries With Libraries build phase instead of
always by embedding linker flags directly.  This behavior is controlled by
a new XCODE_LINK_BUILD_PHASE_MODE target property, which is
initialized by a new CMAKE_XCODE_LINK_BUILD_PHASE_MODE
variable.

The Visual Studio Generators for VS 2015 and above gained support
for the Visual Studio Tools for Android.  One may now set
CMAKE_SYSTEM_NAME to Android to generate .vcxproj files
for the Android tools.

Languages¶

CMake learned to support ISPC as a first-class language that can be
enabled via the project() and enable_language() commands.
ISPC is currently supported by the Makefile Generators
and the Ninja generator on Linux, macOS, and Windows
using the Intel ISPC compiler.

CUDA language support for Clang now includes:

separable compilation (CUDA_SEPARABLE_COMPILATION), and

finding scattered toolkit installations when cross-compiling.

CUDA language support now works on QNX.

Platforms¶

Apple Silicon is now supported (since CMake 3.19.2):

The CMAKE_HOST_SYSTEM_PROCESSOR is selected using uname -m.
Since this may vary based on CMake's own architecture and that of
the invoking process tree, the CMAKE_APPLE_SILICON_PROCESSOR
variable or CMAKE_APPLE_SILICON_PROCESSOR environment
variable may be set to specify a host architecture explicitly.

If CMAKE_OSX_ARCHITECTURES is not set, CMake adds explicit
flags to tell the compiler to build for the
CMAKE_HOST_SYSTEM_PROCESSOR so the toolchain does not
have to guess based on the process tree's architecture.

File-Based API¶

The cmake-file-api(7) "codemodel" version 2 version field has
been updated to 2.2.

The cmake-file-api(7) "codemodel" version 2 "target" object
gained a new languageStandard field in the compileGroups objects.

Command-Line¶

The cmake(1) command-line tool's --install mode gained a
--default-directory-permissions option.

cmake(1) gained a -E create_hardlink command-line tool
that can be used to create hardlinks between files.

GUI¶

The CMake GUI now has an environment variable
editor.

Commands¶

The add_test() command now (officially) supports whitespace and
other special characters in the name for the test it creates.
See policy CMP0110.

The cmake_language() command gained a DEFER mode to
schedule command calls to occur at the end of processing a directory.

The configure_file() command gained a NO_SOURCE_PERMISSIONS
option to suppress copying the input file's permissions to the output file.

The execute_process() command gained a COMMAND_ERROR_IS_FATAL
option to specify a fatal error.

The file(ARCHIVE_CREATE) command gained a COMPRESSION_LEVEL
option to specify the compression level.

The file(CHMOD) and file(CHMOD_RECURSE) subcommands
were added to set permissions of files and directories.

The file(DOWNLOAD) command <file> argument is now
optional.  If it is not specified, the file is not saved.

The file(GENERATE) command gained a new TARGET keyword to
support resolving target-dependent generator expressions.

The file() command gained a new REAL_PATH sub-command to
compute a path with symlinks resolved.

The find_package() command learned to handle a version range.

The separate_arguments() command gained a new PROGRAM option.
It allows the arguments to be treated as a program invocation and will
resolve the executable to a full path if it can be found.

The DIRECTORY option of the set_property(),
get_property(), and get_directory_property() commands
now accepts references to binary directory paths, such as the value of
CMAKE_CURRENT_BINARY_DIR.

The string() command gained a set of new JSON sub commands
that provide JSON parsing capabilities.

Variables¶

The CMAKE_CLANG_VFS_OVERLAY variable was added to tell
Clang to use a VFS overlay to support the Windows SDK when
cross-compiling from hosts with case-sensitive filesystems.

The CMAKE_MFC_FLAG variable now supports generator expressions.

The CMAKE_OPTIMIZE_DEPENDENCIES variable was added to
initialize the new OPTIMIZE_DEPENDENCIES target property and
avoid unnecessarily building dependencies for a static library.

The CMAKE_PCH_INSTANTIATE_TEMPLATES variable was added to
initialize the new PCH_INSTANTIATE_TEMPLATES target property.

The CMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION_MAXIMUM variable
was added to tell the Visual Studio Generators what maximum
version of the Windows SDK to choose.

Properties¶

The EXCLUDE_FROM_ALL target property now supports
generator expressions.

The OPTIMIZE_DEPENDENCIES target property was added to
avoid unnecessarily building dependencies for a static library.

The PCH_INSTANTIATE_TEMPLATES target property was added to enable
template instantiation in the precompiled header. This is enabled by default
and may significantly improve compile times. Currently only supported for
Clang (version 11 or later).

The WIN32_EXECUTABLE target property now supports
generator expressions.

Modules¶

The CheckCompilerFlag module has been added to
generalize CheckCCompilerFlag and
CheckCXXCompilerFlag to more languages.
It also supports the CUDA and ISPC languages.

The CheckLinkerFlag module now supports the CUDA language.

The CheckSourceCompiles module has been added to
generalize CheckCSourceCompiles and
CheckCXXSourceCompiles to more languages.
It also supports the CUDA and ISPC languages.

The CheckSourceRuns module has been added to
generalize CheckCSourceRuns and
CheckCXXSourceRuns to more languages.
It also supports the CUDA language.

The CMakePackageConfigHelpers module gained support for version
ranges.

The FindCUDAToolkit module gained support for finding CUDA
toolkits that do not contain nvcc, as well as for finding scattered
toolkit installations when cross-compiling.

The FindPackageHandleStandardArgs module learned to handle
version ranges. It also gained the find_package_check_version() command
to check the validity of a version against version-related arguments of
find_package() command.

The FindPython3, FindPython2 and FindPython
modules gained the ability to handle a version range.

The FindPython3, FindPython2 and FindPython
modules provide, respectively, the variable Python3_LINK_OPTIONS,
Python2_LINK_OPTIONS and Python_LINK_OPTIONS for link options.

The FindSDL module now provides:

An imported target SDL::SDL.

Result variables SDL_LIBRARIES and SDL_INCLUDE_DIRS.

Version variables SDL_VERSION, SDL_VERSION_MAJOR,
SDL_VERSION_MINOR, and SDL_VERSION_PATCH.

The FindSWIG module gained the ability to handle a version range.

The FindTIFF module gained a CXX component to
find the tiffxx library containing C++ bindings.

The FindVulkan module now provides a Vulkan::glslc imported
target and associated Vulkan_GLSLC_EXECUTABLE variable which contain
the path to the GLSL SPIR-V compiler.

The UseSWIG module gained support for new source file properties
OUTPUT_DIR and OUTFILE_DIR to manage output directories on a
per-source basis.

CTest¶

ctest(1) now supports the CUDA compute-sanitizer checker
(previously known as cuda-memcheck) as the CTEST_MEMORYCHECK_COMMAND.
The different tools (memcheck, racecheck, synccheck and
initcheck) supported by compute-sanitizer can be selected by
adding appropriate flags to the CTEST_MEMORYCHECK_COMMAND_OPTIONS
variable.  The default flags are --tool memcheck --leak-check full.

CPack¶

CPack gained the CPACK_PRE_BUILD_SCRIPTS,
CPACK_POST_BUILD_SCRIPTS, and CPACK_PACKAGE_FILES
variables.

The CPack External Generator gained the
CPACK_EXTERNAL_BUILT_PACKAGES variable.

The CPack WIX Generator gained a
CPACK_WIX_CUSTOM_XMLNS option to specify custom XML namespaces.

Other¶

Interface Libraries may now have source files added via
add_library() or target_sources().  Those
with sources will be generated as part of the build system.

Deprecated and Removed Features¶

Compatibility with versions of CMake older than 2.8.12 is now deprecated
and will be removed from a future version.  Calls to
cmake_minimum_required() or cmake_policy() that set
the policy version to an older value now issue a deprecation diagnostic.

An explicit deprecation diagnostic was added for policy CMP0071
(CMP0071 and below were already deprecated).
The cmake-policies(7) manual explains that the OLD behaviors
of all policies are deprecated and that projects should port to the
NEW behaviors.

macOS SDKs older than 10.5 are no longer supported.

cmake-gui(1) now requires Qt5.
Support for compiling with Qt4 has been removed.

The cmake(1) command-line option --warn-unused-vars has
been removed and is now silently ignored.  The option has not worked
correctly since CMake 3.3.

Documentation¶

The following guides have been added:

IDE Integration Guide

Importing and Exporting Guide

Other Changes¶

Building for macOS will now use the latest SDK available on the system,
unless the user has explicitly chosen a SDK using
CMAKE_OSX_SYSROOT.  The deployment target or system macOS
version will not affect the choice of SDK.

The CMAKE_<LANG>_COMPILER variable may now be used to
store "mandatory" compiler flags like the CC and other environment
variables.

The CMAKE_<LANG>_FLAGS_INIT variable will now be considered
during the compiler identification check if other sources like
CMAKE_<LANG>_FLAGS or CFLAGS are not set.

The find_program() command now requires permission to execute
but not to read the file found.  See policy CMP0109.

An imported target missing its location property fails during generation
if the location is used.  See policy CMP0111.

The following target-based generator expressions that query for directory or
file name components no longer add a dependency on the evaluated target.
See policy CMP0112.

TARGET_FILE_DIR

TARGET_LINKER_FILE_BASE_NAME

TARGET_LINKER_FILE_NAME

TARGET_LINKER_FILE_DIR

TARGET_SONAME_FILE_NAME

TARGET_SONAME_FILE_DIR

TARGET_PDB_FILE_NAME

TARGET_PDB_FILE_DIR

TARGET_BUNDLE_DIR

TARGET_BUNDLE_CONTENT_DIR

Makefile Generators no longer repeat custom commands from target
dependencies.  See policy CMP0113.

The ExternalProject module handling of step target dependencies
has been revised.  See policy CMP0114.

The OSX_ARCHITECTURES target property is now respected
for the ASM language.

If CUDA compiler detection fails with user-specified
CMAKE_CUDA_ARCHITECTURES or
CMAKE_CUDA_HOST_COMPILER, an error is raised.

Updates¶

Changes made since CMake 3.19.0 include the following.

3.19.1¶

CMake 3.19.0 compiles source files with the LANGUAGE
property by passing an explicit language flag such as -x c.
This is consistent with the property's documented meaning that
the source file is written in the specified language.  However,
it can break projects that were using the property only to
cause the specified language's compiler to be used.  This has
been reverted to restore behavior from CMake 3.18 and below.

CUDA 11.1 support for Clang.

3.19.2¶

The precompiled macOS binary provided on cmake.org is now a
universal binary with x86_64 and arm64 architectures.
It requires macOS 10.10 or newer.
The package file naming pattern has been changed from
cmake-$ver-Darwin-x86_64 to cmake-$ver-macos-universal.

Apple Silicon host architecture selection support was updated.
CMake 3.19.0 and 3.19.1 always chose arm64 as the host architecture.
CMake 3.19.2 returns to using uname -m as CMake 3.18 and below did.
Since this may vary based on CMake's own architecture and that of
the invoking process tree, the CMAKE_APPLE_SILICON_PROCESSOR
variable or CMAKE_APPLE_SILICON_PROCESSOR environment
variable may be set to specify a host architecture explicitly.

The CMAKE_ISPC_HEADER_SUFFIX variable and corresponding
ISPC_HEADER_SUFFIX target property were added to control
the header suffix used by ISPC compiler generated headers.

3.19.3¶

A precompiled Linux aarch64 binary is now provided on cmake.org.

Two precompiled macOS binaries are now provided on cmake.org:

The naming pattern cmake-$ver-macos-universal is a universal
binary with x86_64 and arm64 architectures.  It requires
macOS 10.13 or newer.

The naming pattern cmake-$ver-macos10.10-universal is a universal
binary with x86_64 and arm64 architectures.  It requires
macOS 10.10 or newer.

3.19.4¶

The CMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION_MAXIMUM
variable introduced in 3.19.0 previously worked only with the
Visual Studio 14 2015 generator.  It has now been fixed to
work with Visual Studio Generators for later VS versions too.

3.19.5¶

When IOS_INSTALL_COMBINED is enabled and the Xcode
generator is used, it is now possible to initiate an install or package
creation by running cmake --install or cpack from the command line.
When using the Xcode new build system, these are the only supported methods
due to a limitation of Xcode.  Initiating these operations by building the
install or package targets in Xcode is only supported when using
the legacy build system.

The framework handling introduced in 3.19.0 as part of supporting Xcode's
Link Binaries With Libraries build phase broke the ability to switch
between device and simulator builds without reconfiguring.  That capability
has now been restored.

3.19.6¶

The cmake-presets(7) feature no longer allows comments in
CMakePresets.json or CMakeUserPresets.json files.
This was mistakenly allowed by the implementation in CMake 3.19.0 through
CMake 3.19.5, and was not documented.

3.19.7¶

With Visual Studio Generators for VS 2017 and higher, the
CMAKE_GENERATOR_TOOLSET field version= now accepts
three-component MSVC toolset versions such as 14.28.29910.
See the CMAKE_VS_PLATFORM_TOOLSET_VERSION variable.

Table of Contents

CMake 3.19 Release Notes

New Features

Presets

Generators

Languages

Platforms

File-Based API

Command-Line

GUI

Commands

Variables

Properties

Modules

CTest

CPack

Other

Deprecated and Removed Features

Documentation

Other Changes

Updates

3.19.1

3.19.2

3.19.3

3.19.4

3.19.5

3.19.6

3.19.7

Previous topic

CMake 3.20 Release Notes

Next topic

CMake 3.18 Release Notes

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 Release Notes »

CMake 3.19 Release Notes

        © 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>CMake 3.2 Release Notes — 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="CMake 3.1 Release Notes" href="3.1.html" />
    <link rel="prev" title="CMake 3.3 Release Notes" href="3.3.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.2 Release Notes

CMake 3.2 Release Notes¶

Contents

CMake 3.2 Release Notes

New Features

Syntax

Commands

Variables

Properties

Modules

CTest

CPack

Other

New Diagnostics

Deprecated and Removed Features

Other Changes

Changes made since CMake 3.1 include the following.

New Features¶

Syntax¶

CMake learned to support unicode characters
encoded as UTF-8
on Windows.  This was already supported on platforms whose
system APIs accept UTF-8 encoded strings.
Unicode characters may now be used in CMake code, paths to
source files, configured files such as .h.in files, and
other files read and written by CMake.  Note that because CMake
interoperates with many other tools, there may still be some
limitations when using certain unicode characters.

Commands¶

The add_custom_command() and add_custom_target()
commands learned a new BYPRODUCTS option to specify files
produced as side effects of the custom commands.  These are not
outputs because they do not always have to be newer than inputs.

The add_custom_command() and add_custom_target()
commands learned a new USES_TERMINAL option to request that
the command be given direct access to the terminal if possible.
The Ninja generator will places such commands in the
console pool.  Build targets provided by CMake
that are meant for individual interactive use, such as install, are now
placed in this pool.

A new continue() command was added that can be called inside loop
contexts to end the current iteration and start the next one at the top of
the loop block.

The file(LOCK) subcommand was created to allow CMake
processes to synchronize through file and directory locks.

The file(STRINGS) now supports UTF-16LE, UTF-16BE,
UTF-32LE, UTF-32BE as ENCODING options.

The install(EXPORT) command now works with an absolute
DESTINATION even if targets in the export set are installed
with a destination or usage requirements
specified relative to the install prefix.  The value of the
CMAKE_INSTALL_PREFIX variable is hard-coded into the installed
export file as the base for relative references.

The try_compile() command source file signature now honors
link flags (e.g. CMAKE_EXE_LINKER_FLAGS) in the generated
test project.  See policy CMP0056.

The try_run() command learned to honor the LINK_LIBRARIES
option just as try_compile() already does.

The file(GENERATE) command now generates the output file with
the same permissions as the input file if set.

The file(GENERATE) command can now generate files which are
used as source files for buildsystem targets.  Generated files
automatically get their GENERATED property set to TRUE.

Variables¶

The CMAKE_MATCH_COUNT variable was introduced to record the
number of matches made in the last regular expression matched in an
if() command or a string() command.

Properties¶

An ANDROID_API_MIN target property was introduced to
specify the minimum version to be targeted by the toolchain.

A VS_SHADER_FLAGS source file property was added to specify
additional shader flags to .hlsl files, for the Visual Studio
generators.

Modules¶

The ExternalData module learned to support
Custom Fetch Scripts.
This allows projects to specify custom .cmake scripts for
fetching data objects during the build.

The ExternalProject module learned options to create
independent external project step targets that do not depend
on the builtin steps.

The ExternalProject module ExternalProject_Add()
command learned a new CMAKE_CACHE_DEFAULT_ARGS option to
initialize cache values in the external project without setting
them on future builds.

The ExternalProject module ExternalProject_Add()
command learned a new TEST_EXCLUDE_FROM_MAIN option to exclude
tests from the main build.

The ExternalProject module ExternalProject_Add()
command learned a new UPDATE_DISCONNECTED option to avoid
automatically updating the source tree checkout from version control.

The FindCUDA module learned about the cusolver
library in CUDA 7.0.

The FindGit module learned to find the git command-line tool
that comes with GitHub for Windows installed in user home directories.

A FindGSL module was introduced to find the
GNU Scientific Library.

A FindIntl module was introduced to find the
Gettext libintl library.

The FindLATEX module learned to support components.

The FindMPI module learned to find MS-MPI on Windows.

The FindOpenSSL module now reports crypto and ssl
libraries separately in OPENSSL_CRYPTO_LIBRARY and
OPENSSL_SSL_LIBRARY, respectively, to allow applications to
link to one without the other.

The WriteCompilerDetectionHeader module learned to
create a define for portability of the cxx_thread_local feature.
The define expands to either the C++11 thread_local keyword, or a
pre-standardization compiler-specific equivalent, as appropriate.

The WriteCompilerDetectionHeader module learned to create
multiple output files per compiler and per language, instead of creating
one large file.

CTest¶

The ctest_coverage() command learned to support Delphi coverage.

The ctest_coverage() command learned to support Javascript coverage.

The CTestCoverageCollectGCOV module was introduced as an
alternative to the ctest_coverage() command for collecting
gcov results for submission to CDash.

CPack¶

The CPack RPM Generator learned options to set per-component
descriptions and summaries.  See the
CPACK_RPM_<component>_PACKAGE_DESCRIPTION and
CPACK_RPM_<component>_PACKAGE_SUMMARY variables.

The CPack RPM Generator learned options to specify
requirements for pre- and post-install scripts.  See the
CPACK_RPM_PACKAGE_REQUIRES_PRE and
CPACK_RPM_PACKAGE_REQUIRES_POST variables.

The CPack RPM Generator learned options to specify
requirements for pre- and post-uninstall scripts.  See the
CPACK_RPM_PACKAGE_REQUIRES_PREUN and
CPACK_RPM_PACKAGE_REQUIRES_POSTUN variables.

The CPack RPM Generator learned a new
CPACK_RPM_<COMPONENT>_PACKAGE_PREFIX variable to
specify a component-specific value to use instead of
CPACK_PACKAGING_INSTALL_PREFIX.

The CPack RPM Generator learned a new
CPACK_RPM_RELOCATION_PATHS variable to
specify multiple relocation prefixes for a single rpm package.

Other¶

The cmake(1) -E tar command now supports creating
.xz-compressed archives with the J flag.

The cmake(1) -E tar command learned a new
--files-from=<file> option to specify file names using
lines in a file to overcome command-line length limits.

The cmake(1) -E tar command learned a new
--mtime=<date> option to specify the modification time
recorded in tarball entries.

The Compile Features functionality
is now aware of features supported by more compilers, including:

Apple Clang (AppleClang) for Xcode versions 4.4 though 6.1.

GNU compiler versions 4.4 through 5.0 on UNIX and Apple (GNU).

Microsoft Visual Studio (MSVC) for versions 2010 through 2015.

Oracle SolarisStudio (SunPro) version 12.4.

The AUTORCC feature now tracks files listed in .qrc files
as dependencies. If an input file to the rcc tool is changed, the tool
is automatically re-run.

New Diagnostics¶

The break() command now rejects calls outside of a loop
context or that pass arguments to the command.
See policy CMP0055.

Deprecated and Removed Features¶

Files written in the cmake-language(7), such as
CMakeLists.txt or *.cmake files, are now expected to be
encoded as UTF-8.  If files are already ASCII, they will be
compatible.  If files were in a different encoding, including
Latin 1, they will need to be converted.

The FindOpenGL module no longer explicitly searches
for any dependency on X11 libraries with the FindX11
module.  Such dependencies should not need to be explicit.
Applications using X11 APIs themselves should find and link
to X11 libraries explicitly.

The implementation of CMake now relies on some C++ compiler features which
are not supported by some older compilers.  As a result, those old compilers
can no longer be used to build CMake itself.  CMake continues to be able to
generate Makefiles and project files for users of those old compilers
however.  Compilers known to no longer be capable of building CMake are:

Visual Studio 6 and 7.0 -- superseded by VisualStudio 7.1 and newer.

GCC 2.95 -- superseded by GCC 3 and newer compilers.

Borland compilers -- superseded by other Windows compilers.

Compaq compilers -- superseded by other compilers.

SGI compilers -- IRIX was dropped as a host platform.

Other Changes¶

On Windows and OS X, commands supporting network communication
via https, such as file(DOWNLOAD),
file(UPLOAD), and ctest_submit(), now support
SSL/TLS even when CMake is not built against OpenSSL.
The Windows or OS X native SSL/TLS implementation is used by default.
OS-configured certificate authorities will be trusted automatically.

On other platforms, when CMake is built with OpenSSL, these
commands now search for OS-configured certificate authorities
in a few /etc paths to be trusted automatically.

On OS X with Makefile and Ninja generators, when a compiler is found
in /usr/bin it is now mapped to the corresponding compiler inside
the Xcode application folder, if any.  This allows such build
trees to continue to work with their original compiler even when
xcode-select switches to a different Xcode installation.

The Visual Studio generators now write solution and project
files in UTF-8 instead of Windows-1252.  Windows-1252 supported
Latin 1 languages such as those found in North and South America
and Western Europe.  With UTF-8, additional languages are now
supported.

The Xcode generator no longer requires a value for
the CMAKE_MAKE_PROGRAM variable to be located up front.
It now locates xcodebuild when needed at build time.

When building CMake itself using SolarisStudio 12, the default libCStd
standard library is not sufficient to build CMake.  The SolarisStudio
distribution supports compiler options to use STLPort4 or libstdc++.
An appropriate option to select the standard library is now added
automatically when building CMake with SolarisStudio compilers.

Table of Contents

CMake 3.2 Release Notes

New Features

Syntax

Commands

Variables

Properties

Modules

CTest

CPack

Other

New Diagnostics

Deprecated and Removed Features

Other Changes

Previous topic

CMake 3.3 Release Notes

Next topic

CMake 3.1 Release Notes

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 Release Notes »

CMake 3.2 Release Notes

        © 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>CMake 3.20 Release Notes — 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="CMake 3.19 Release Notes" href="3.19.html" />
    <link rel="prev" title="CMake 3.21 Release Notes" href="3.21.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.20 Release Notes

CMake 3.20 Release Notes¶

Contents

CMake 3.20 Release Notes

New Features

Presets

Generators

Languages

Compilers

Platforms

File-Based API

Commands

Variables

Properties

Modules

Autogen

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.20.1

3.20.2

3.20.3, 3.20.4, 3.20.5, 3.20.6

Changes made since CMake 3.19 include the following.

New Features¶

Presets¶

cmake-presets(7) gained support for build and test presets.

Generators¶

Makefile Generators, for some toolchains, now use the compiler
to extract implicit dependencies while compiling source files.

Languages¶

C++23 compiler modes may now be specified via the CXX_STANDARD,
CUDA_STANDARD, or OBJCXX_STANDARD target properties,
or via the Compile Features
functionality's cxx_std_23 meta-feature.

CUDA language support now works when nvcc is a symbolic link,
for example due to a ccache or colornvcc wrapper script.

The CUDAARCHS environment variable was added for initializing
CMAKE_CUDA_ARCHITECTURES. Useful in cases where the compiler
default is unsuitable for the machine's GPU.

Compilers¶

The NVIDIA HPC SDK compilers are now supported with compiler id NVHPC.

The Intel oneAPI NextGen LLVM compilers are now supported with
compiler id IntelLLVM:

The icx/icpx C/C++ compilers on Linux, and the icx
C/C++ compiler on Windows, are fully supported as of oneAPI 2021.1.

The ifx Fortran compiler on Linux is supported as of oneAPI 2021.1.

The ifx Fortran compiler on Windows is not yet supported.

The Intel oneAPI Classic compilers (icc, icpc, and ifort)
continue to be supported with compiler id Intel.

Support was added for the IAR STM8 compiler.

Platforms¶

CMake's support for Cross Compiling for Android
is now merged with the Android NDK's toolchain file.
They now have similar behavior, though some variable names differ.
User-facing changes include:

find_* functions will search NDK ABI / API specific paths by default.

The default CMAKE_BUILD_TYPE for Android is
now RelWithDebInfo.

The CMAKE_ANDROID_NDK_VERSION variable was added to
report the version of the NDK.

File-Based API¶

The cmake-file-api(7) gained a new "toolchains" object
kind that describes the compiler used for each enabled language.

Commands¶

add_custom_command() and add_custom_target() now
support generator expressions
in their OUTPUT and BYPRODUCTS options.

Their COMMAND, WORKING_DIRECTORY, and DEPENDS options gained
support for new generator expressions $<COMMAND_CONFIG:...> and
$<OUTPUT_CONFIG:...> that control cross-config handling when using
the Ninja Multi-Config generator.

The add_custom_command() command gained DEPFILE support on
Makefile Generators.

The add_library() command previously prohibited imported object
libraries when using potentially multi-architecture configurations.
This mostly affected the Xcode generator, e.g. when targeting
iOS or one of the other device platforms.  This restriction has now been
removed.

The cmake_path() command was added for operations on
filesystem paths.

The configure_file() command gained USE_SOURCE_PERMISSIONS
and FILE_PERMISSIONS options to support copying of permissions of the
source file and using specified permissions respectively.

The file(GENERATE) command gained a NEWLINE_STYLE option to
specify how newlines are handled for the generated file.

The file(GENERATE) command gained NO_SOURCE_PERMISSIONS,
USE_SOURCE_PERMISSIONS, and FILE_PERMISSIONS options for controlling
the permissions of the generated file.

The install(FILES) command RENAME option learned to
support generator expressions.

The target_include_directories() command gained a new option
AFTER.

The target_sources() command now supports targets created
by the add_custom_target() command.

The try_run() command gained a WORKING_DIRECTORY option to
set the working directory in which to run the compiled check executable.

Variables¶

The CMAKE_<LANG>_BYTE_ORDER variable was added to provide the
target architecture byte order detected from the toolchain.

The CMAKE_RUNTIME_OUTPUT_DIRECTORY,
CMAKE_LIBRARY_OUTPUT_DIRECTORY, and
CMAKE_ARCHIVE_OUTPUT_DIRECTORY variables now support
target-dependent generator expressions.

Properties¶

The <LANG>_CLANG_TIDY target property and the associated
CMAKE_<LANG>_CLANG_TIDY variable learned to support
the OBJC and OBJCXX languages.

The EXPORT_COMPILE_COMMANDS target property was added
for the associated CMAKE_EXPORT_COMPILE_COMMANDS variable
to allow for configuration of exporting compile commands per target.

The GENERATED source-file property is now visible
from any directory scope, regardless of the scope in which it is set.
See policy CMP0118.

The UNITY_BUILD_UNIQUE_ID target property
was added to support generation of an identifier that is
unique per source file in unity builds.  It can help to
resolve duplicate symbol problems with anonymous namespaces.

The WIN32_EXECUTABLE target property now works with Clang
on Windows.

The XCODE_EMBED_FRAMEWORKS target property
was added to tell the Xcode generator to embed frameworks.
Aspects of the embedding can be customized with the
XCODE_EMBED_FRAMEWORKS_PATH,
XCODE_EMBED_FRAMEWORKS_CODE_SIGN_ON_COPY, and
XCODE_EMBED_FRAMEWORKS_REMOVE_HEADERS_ON_COPY target properties.

Modules¶

The ExternalData module ExternalData_Add_Target()
function gained a SHOW_PROGRESS <bool> option for controlling whether
or not to show progress output during the build.

The ExternalProject module ExternalProject_Add() function
gained a CONFIGURE_HANDLED_BY_BUILD option.  This can be used to make
subsequent runs of the configure step be triggered by the build step when
an external project dependency rebuilds instead of always re-running the
configure step in such cases.

The FindBoost module gained a Boost_NO_WARN_NEW_VERSIONS
option to silence the warning about unknown dependencies for new
Boost versions.

The FindCUDAToolkit module gained support for finding CUDA
toolkits when nvcc is a symbolic link,
for example due to a ccache or colornvcc wrapper script.

The FindGDAL module has been improved to document and mark as
advanced its cache variables. There is a new FindGDAL_SKIP_GDAL_CONFIG
variable which may be used to skip over the gdal-config-based search.
Users may also set GDAL_ADDITIONAL_LIBRARY_VERSIONS to add additional
versions to the library name search strategy.

The FindIntl module now provides an imported target.

The FindOpenSSL module learned to support a version range.

The FindPython3, FindPython2 and FindPython
modules gained options controlling how unversioned interpreter names are
searched.

The UseJava module add_jar() command's
GENERATE_NATIVE_HEADERS feature gained options to export the
generated target.

The UseSWIG module gained the capability, for
Makefile and Ninja
generators, to use the swig tool to generate implicit dependencies.

Autogen¶

The AUTOMOC feature now works with per-config sources.

CTest¶

ctest(1) gained a --test-dir
option to specify the directory in which to look for tests.

CPack¶

CPack gained the CPACK_THREADS variable to
control the number of threads used for parallelized operations,
such as compressing the installer package.

The CPack DEB Generator learned a new
CPACK_DEBIAN_PACKAGE_SHLIBDEPS_PRIVATE_DIRS
variable to specify additional search directories for
resolving private library dependencies when using
dpkg-shlibdeps.

The CPack IFW Generator gained a new
CPACK_IFW_PACKAGE_WIZARD_SHOW_PAGE_LIST variable to
control visibility of the widget listing installer pages on the left side
of the wizard. This feature available only since QtIFW 4.0.

The CPack NSIS Generator gained new
CPACK_NSIS_BRANDING_TEXT and
CPACK_NSIS_BRANDING_TEXT_TRIM_POSITION variables to change
the text at the bottom of the install window and change its trim position

The CPack NSIS Generator now correctly handles Unicode
characters.  If you want to have a CPACK_RESOURCE_FILE_LICENSE
with UTF-8 characters, it needs to be encoded in UTF-8 BOM.

The CPack NuGet Generator gained options:

CPACK_NUGET_PACKAGE_ICON and
CPACK_NUGET_<compName>_PACKAGE_ICON
allow package icons to be specified by local files.

CPACK_NUGET_PACKAGE_LICENSE_EXPRESSION and
CPACK_NUGET_<compName>_PACKAGE_LICENSE_EXPRESSION add
support for specifying licenses recognized by the
Software Package Data Exchange (SPDX).

CPACK_NUGET_PACKAGE_LICENSE_FILE_NAME and
CPACK_NUGET_<compName>_PACKAGE_LICENSE_FILE_NAME allow
licenses to be specified by local files.

CPACK_NUGET_PACKAGE_LANGUAGE and
CPACK_NUGET_<compName>_PACKAGE_LANGUAGE allow the locale
for a package to be specified, for example en_CA.

Deprecated and Removed Features¶

The cmake-server(7) mode has been removed.
Clients should use the cmake-file-api(7) instead.

The WriteCompilerDetectionHeader module has been deprecated
via policy CMP0120.  Projects should be ported away from it.

The TestBigEndian module has been deprecated in favor
of the CMAKE_<LANG>_BYTE_ORDER variable.

The AddFileDependencies module is deprecated.
Port projects to use set_property() directly.

The CPack NuGet Generator deprecated some variables to reflect
changes in the NuGet specification:

CPACK_NUGET_PACKAGE_ICONURL and
CPACK_NUGET_<compName>_PACKAGE_ICONURL have been deprecated;
replace with a reference to a local icon file.

CPACK_NUGET_PACKAGE_LICENSEURL and
CPACK_NUGET_<compName>_PACKAGE_LICENSEURL have been deprecated;
replace with a reference to the project's license file or SPDX
license expression.

Other Changes¶

When running cmake(1) to Generate a Project Buildsystem,
unknown command-line arguments starting with a hyphen (-) are now
rejected with an error.  Previously they were silently ignored.

Source file extensions must now be explicit.
See policy CMP0115 for details.

The LANGUAGE source file property now forces compilation
as the specified language.  See policy CMP0119.

On AIX, installation of XCOFF executables and shared libraries
no longer requires relinking to change the runtime search path
from the build-tree RPATH to the install-tree RPATH.  CMake now
edits the XCOFF binaries directly during installation, as has
long been done on ELF platforms.

With MSVC-like compilers the value of
CMAKE_CXX_FLAGS no longer contains
the /GR flag for runtime type information by default.
See policy CMP0117.

Ninja generators now transform the DEPFILE generated by an
add_custom_command(). See policy CMP0116 for details.

The precompiled Linux binaries provided on
cmake.org have changed their naming pattern
to cmake-$ver-linux-$arch, where $arch is either x86_64 or
aarch64.

The precompiled Windows binaries provided on
cmake.org have changed their naming pattern
to cmake-$ver-windows-$arch, where $arch is either x86_64 or
i386.

Updates¶

Changes made since CMake 3.20.0 include the following.

3.20.1¶

The FindIntl module in CMake 3.20.0 added checks
Intl_HAVE_GETTEXT_BUILTIN, Intl_HAVE_DCGETTEXT_BUILTIN,
and Intl_IS_BUILTIN, but they were not implemented correctly.
These have been removed and replaced with a single Intl_IS_BUILT_IN
check, whose name is consistent with the FindIconv module.

The -rpath linker flag is now specified as supported on all Apple
platforms, not just macOS.  The install_name_dir used for
iOS, tvOS and watchOS should now default to @rpath instead of using
a full absolute path and failing at runtime when the library or framework
is embedded in an application bundle (see XCODE_EMBED_<type>).

3.20.2¶

The Intel Classic 2021 compiler version numbers are now detected correctly
as having major version 2021.  CMake 3.20.1 and below were not aware of a
change to the identification macro version scheme made by Intel starting
in version 2021, and detected the version as 20.2.

The Intel oneAPI Fortran compiler is now identified as IntelLLVM.
The oneAPI 2021.1 Fortran compiler is missing an identification macro,
so CMake 3.20.1 and below identified it as Intel.  CMake now has
a special case to recognize oneAPI 2021.1 Fortran as IntelLLVM.
The oneAPI 2021.2 Fortran compiler defines the proper identification
macro and so is identified as IntelLLVM by all CMake 3.20 versions.

3.20.3, 3.20.4, 3.20.5, 3.20.6¶

These versions made no changes to documented features or interfaces.
Some implementation updates were made to support ecosystem changes
and/or fix regressions.

Table of Contents

CMake 3.20 Release Notes

New Features

Presets

Generators

Languages

Compilers

Platforms

File-Based API

Commands

Variables

Properties

Modules

Autogen

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.20.1

3.20.2

3.20.3, 3.20.4, 3.20.5, 3.20.6

Previous topic

CMake 3.21 Release Notes

Next topic

CMake 3.19 Release Notes

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 Release Notes »

CMake 3.20 Release Notes

        © 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>CMake 3.21 Release Notes — 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="CMake 3.20 Release Notes" href="3.20.html" />
    <link rel="prev" title="CMake 3.22 Release Notes" href="3.22.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.21 Release Notes

CMake 3.21 Release Notes¶

Contents

CMake 3.21 Release Notes

New Features

Presets

Generators

Languages

Command-Line

Compilers

Platforms

File-Based API

Commands

Variables

Properties

Modules

Generator Expressions

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.21.1

3.21.2

3.21.3

3.21.4

3.21.5, 3.21.6, 3.21.7

Changes made since CMake 3.20 include the following.

New Features¶

Presets¶

cmake-presets(7) gained support for specifying the install prefix
in a configure preset.

cmake-presets(7) gained support for conditional enabling of presets.

cmake-presets(7) gained support for a ${hostSystemName} macro.

cmake-presets(7) gained support for omitting the generator and
binaryDir fields.

Generators¶

The Visual Studio 17 2022 generator was added.

The Makefile Generators and the Ninja generator
learned to add linker launcher tools along with the linker for C,
CXX, OBJC, and OBJCXX languages.
See the CMAKE_<LANG>_LINKER_LAUNCHER variable
and <LANG>_LINKER_LAUNCHER target property for details.

Languages¶

CMake learned to support HIP as a first-class language that can be
enabled via the project() and enable_language() commands.

C_STANDARD, OBJC_STANDARD, and the
Compile Features functionality gained
support for C17 and C23.

Source file extensions .ixx and .cppm are now treated as C++.

Command-Line¶

cmake(1) gained the --install-prefix
command-line option to specify the location of the install prefix.

cmake(1) gained the --toolchain
command-line option to specify a toolchain file.

cmake(1) -E capabilities output,
for some generators, may now contain a supportedPlatforms field listing
platforms known to be supported in CMAKE_GENERATOR_PLATFORM.

Messages printed to a terminal now may be colored by message type.

Compilers¶

The Fujitsu compiler is now supported using compiler id Fujitsu
in traditional (Trad) mode, and compiler id FujitsuClang
in Clang mode.

Platforms¶

CMake now supports the MSYS runtime environment, much like CYGWIN.

File-Based API¶

The cmake-file-api(7) "codemodel" version 2 version field
has been updated to 2.3.

The cmake-file-api(7) "codemodel" version 2 gained a
new "directory" object containing directory-level information.
This includes a list of installers generated by the install()
command.

Commands¶

The add_custom_command() command DEPFILE option:

may now use
generator expressions,

is now supported by Visual Studio Generators for VS 2012
and above, and

is now supported by the Xcode generator.

The add_custom_command(TARGET) command
(for Build Events)
gained support for resolving target-dependent generator expressions.

The build_command() command gained a PARALLEL_LEVEL option.

The file(COPY_FILE) command was added to copy a single file.

The file(GET_RUNTIME_DEPENDENCIES) command gained new
POST_INCLUDE_FILES and POST_EXCLUDE_FILES arguments.

The file(REAL_PATH) command gained the option EXPAND_TILDE to
replace any leading tilde with the path to the user's home directory.

The file(RENAME) command learned to optionally capture
failure in a result variable.  It also gained a NO_REPLACE
option to fail if the destination exists.

The install() command gained a new IMPORTED_RUNTIME_ARTIFACTS
mode, which can be used to install the runtime artifacts of imported targets.

The install() command gained a new RUNTIME_DEPENDENCY_SET mode,
which can be used to install runtime dependencies using
file(GET_RUNTIME_DEPENDENCIES).

The install(TARGETS) command gained new RUNTIME_DEPENDENCIES
and RUNTIME_DEPENDENCY_SET arguments, which can be used to install
runtime dependencies using file(GET_RUNTIME_DEPENDENCIES).

The install(SCRIPT|CODE) command
supports a new option ALL_COMPONENTS which allows
the corresponding code to run for every component of
a per component installation.

The project() command now sets variables
PROJECT_IS_TOP_LEVEL and <PROJECT-NAME>_IS_TOP_LEVEL
to indicate whether it was called in a top-level CMakeLists.txt file.

Variables¶

The CMAKE_TOOLCHAIN_FILE environment variable was added to
provide a default value for the CMAKE_TOOLCHAIN_FILE variable.

Properties¶

The IMPORTED_TARGETS directory property was added to
get a list of Imported Targets created in the current
directory.

The XCODE_EMBED_APP_EXTENSIONS target property
was added to tell the Xcode generator to embed app extensions
such as iMessage sticker packs.
Aspects of the embedding can be customized with the
XCODE_EMBED_APP_EXTENSIONS_PATH,
XCODE_EMBED_APP_EXTENSIONS_CODE_SIGN_ON_COPY and
XCODE_EMBED_APP_EXTENSIONS_REMOVE_HEADERS_ON_COPY
properties.

Modules¶

The FindBLAS and FindLAPACK modules learned to support
the serial Fujitsu_SSL2 and parallel Fujitsu_SSL2BLAMP libraries.

The FindDevIL module now provides imported targets.

The FindIconv module now has version support.

The FindIntl module now has version support.

The FindMPI module learned to support Fujitsu and
FujitsuClang in both host and cross compiling modes.

The FindMsys module was added to find MSYS installations.
Like FindCygwin, it is used automatically by some other
find modules to locate UNIX-style tools on Windows.

The FindOpenMP module learned to support Fujitsu and
FujitsuClang.

The FindVulkan module gained imported targets
Vulkan::Headers and Vulkan::glslangValidator.

The UseJava module command add_jar gained a RESOURCES
option to allow explicit naming of resources with non-optional namespace.

The UseSWIG module use now standard library naming conventions
for the CSharp language. See policy CMP0122.

The UseSWIG module now supports using the swig tool to
generate implicit dependencies with the Xcode generator.

Generator Expressions¶

A new TARGET_RUNTIME_DLLS generator expression was added.

CTest¶

ctest(1) gained documentation for its ability to capture
Additional Test Measurements.

ctest(1) learned to recognize files attached to a test at run time.
Previously it was only possible to attach files to tests at configure time
by using the ATTACHED_FILES or
ATTACHED_FILES_ON_FAIL test properties.
See Additional Test Measurements for more information.

ctest(1) gained a --output-junit
option to write test results to a JUnit XML file.

The ctest_build() command gained a PARALLEL_LEVEL option.

CPack¶

The CPack DragNDrop Generator gained option
CPACK_DMG_FILESYSTEM to control the .dmg filesystem.

The CPack IFW Generator now supports hyphens in names
given to cpack_ifw_configure_component() or
cpack_ifw_configure_component_group() as DEPENDS or
DEPENDENCIES arguments.  This requires QtIFW 3.1 or later.

The CPack NSIS Generator gained a new
CPACK_NSIS_EXECUTABLE variable to specify the makensis
executable to use instead of the default one.

The CPACK_CUSTOM_INSTALL_VARIABLES variable was added to set
variables in cmake_install.cmake script invocations made by CPack.

Deprecated and Removed Features¶

Undocumented CMAKE_SYSTEM_NAME version-stripping behavior has
been removed entirely. If it is set by a -D flag or by a
toolchain file, it is left unaltered,
even if it still contains a version number.
Similar CMAKE_HOST_SYSTEM_NAME version-stripping behavior,
also undocumented, has been moved earlier, before project() or
enable_language() is called.

ARMClang cpu/arch compile and link flags are no longer added
automatically based on the CMAKE_SYSTEM_PROCESSOR
variable or the undocumented CMAKE_SYSTEM_ARCH variable.
They must be specified explicitly.  See policy CMP0123.

Other Changes¶

The find_file(), find_path(), find_program(),
and find_library() commands handle cache variables in the same way
regardless how they are defined. See policy CMP0125 for details.

The find_file(), find_path(), find_program(),
and find_library() commands gained the option NO_CACHE to store
find result in normal variable.

The foreach() command now isolates loop variables in the loop scope.
See policy CMP0124 for details.

The list() command's GET, INSERT, SUBLIST, and
REMOVE_AT subcommands now error with invalid (i.e., non-integer) values
are given as any of their index arguments based on the setting of policy
CMP0121.

The set(CACHE) command no longer removes a normal variable
of the same name, if any. See policy CMP0126.

target_link_libraries() calls referencing object libraries
via the TARGET_OBJECTS generator expression now place the
object files before all libraries on the link line, regardless of
their specified order.  See documentation on
Linking Object Libraries via $<TARGET_OBJECTS> for details.

The Ninja Generators now pass source files and include directories
to the compiler using absolute paths.  This makes diagnostic messages and
debug symbols more consistent, and matches the Makefile Generators.

The NMake Makefiles generator now encodes the generated
makefiles as UTF-8 with a BOM when using nmake from VS 9 or above.

The Visual Studio Generators for VS 2010 and above now place
per-source preprocessor definitions after target-wide preprocssor
definitions.  This makes VS consistent with the Ninja Generators
and the Makefile Generators.

The precompiled binaries provided on
cmake.org now support
liblzma multi-threading.  See the CPACK_THREADS and
CPACK_ARCHIVE_THREADS variables.

Updates¶

Changes made since CMake 3.21.0 include the following.

3.21.1¶

The Visual Studio 17 2022 generator is now based on
"Visual Studio 2022 Preview 2".  Previously it was based on "Preview 1.1".

3.21.2¶

CUDA targets with CUDA_SEPARABLE_COMPILATION enabled are now
correctly generated in non-root directories.

The Visual Studio 17 2022 generator is now based on
"Visual Studio 2022 Preview 3.1".  Previously it was based on "Preview 2".

3.21.3¶

The Visual Studio 17 2022 generator is now based on
"Visual Studio 2022 Preview 4".  Previously it was based on "Preview 3.1".

The AMD ROCm Platform hipcc compiler was identified by CMake 3.21.0
through 3.21.2 as a distinct compiler with id ROCMClang.  This has
been removed because it caused regressions.  Instead:

hipcc may no longer be used as a HIP compiler because it
interferes with flags CMake needs to pass to Clang.  Use Clang directly.

hipcc may once again be used as a CXX compiler, and is treated as
whatever compiler it selects underneath, as CMake 3.20 and below did.

3.21.4¶

The Visual Studio 17 2022 generator is now based on the
"Visual Studio 2022" release candidates.  Previously it was based on
preview versions.

3.21.5, 3.21.6, 3.21.7¶

These versions made no changes to documented features or interfaces.
Some implementation updates were made to support ecosystem changes
and/or fix regressions.

Table of Contents

CMake 3.21 Release Notes

New Features

Presets

Generators

Languages

Command-Line

Compilers

Platforms

File-Based API

Commands

Variables

Properties

Modules

Generator Expressions

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.21.1

3.21.2

3.21.3

3.21.4

3.21.5, 3.21.6, 3.21.7

Previous topic

CMake 3.22 Release Notes

Next topic

CMake 3.20 Release Notes

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 Release Notes »

CMake 3.21 Release Notes

        © 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>CMake 3.22 Release Notes — 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="CMake 3.21 Release Notes" href="3.21.html" />
    <link rel="prev" title="CMake 3.23 Release Notes" href="3.23.html" />

Navigation

          index

          next |

          previous |

    CMake »

    3.29.0-rc3 Documentation »

CMake Release Notes »

CMake 3.22 Release Notes

CMake 3.22 Release Notes¶

Contents

CMake 3.22 Release Notes

New Features

Commands

Variables

Properties

Modules

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.22.1

3.22.2

3.22.3

3.22.4, 3.22.5, 3.22.6

Changes made since CMake 3.21 include the following.

New Features¶

Commands¶

The cmake_host_system_information() command can now query
OS identification variables from the /etc/os-release file.

The string(TIMESTAMP) command now supports the %V
specifier for ISO 8601 week numbers.

Variables¶

The CMAKE_BUILD_TYPE environment variable was added to
provide a default value for the CMAKE_BUILD_TYPE variable.

The CMAKE_CONFIGURATION_TYPES environment variable was added to
provide a default value for the CMAKE_CONFIGURATION_TYPES
variable.

The CMAKE_INSTALL_MODE environment variable was added to
tell install() rules (implemented by file(INSTALL))
to install symbolic links instead of copying of files.

The CMAKE_<LANG>_LINK_WHAT_YOU_USE_FLAG and
CMAKE_LINK_WHAT_YOU_USE_CHECK variables were added to
control the linker flag and check used by the
LINK_WHAT_YOU_USE target property.

The CMAKE_REQUIRE_FIND_PACKAGE_<PackageName> variable
was added to turn a non-REQUIRED find_package() call into
a REQUIRED one.

Properties¶

The <LANG>_EXTENSIONS target property is now initialized to
CMAKE_<LANG>_EXTENSIONS_DEFAULT, detected from the compiler.
See CMP0128.

The VS_SETTINGS source file property is now supported for
all source file types.  Previously it worked only for non-built sources.

Modules¶

The CMakeDependentOption module cmake_dependent_option()
macro now supports full Condition Syntax.
See policy CMP0127.

The FetchContent module now passes through the
CMAKE_TLS_VERIFY, CMAKE_TLS_CAINFO,
CMAKE_NETRC and CMAKE_NETRC_FILE variables (when
defined) to the underlying ExternalProject sub-build.
Previously, those variables were silently ignored by FetchContent.

The FindBLAS and FindLAPACK modules gained
a BLA_SIZEOF_INTEGER option to find a BLAS/LAPACK whose ABI
uses a specific integer size.

The FindJasper module now provides an imported target.

The FindMatlab module now provides imported targets.

The FindPkgConfig module gained a PKG_CONFIG_ARGN
variable to specify arguments to pkg-config calls.

The GoogleTest module gtest_discover_tests()
function gained a TEST_FILTER option to filter tests using
--gtest_filter during test discovery.

The UseSWIG module, for Visual Studio Generators,
can now use the swig tool to generate implicit dependencies.

CTest¶

ctest(1) learned to recognize labels attached to a test at run time.
Previously it was only possible to attach labels to tests at configure time
by using the LABELS test property.
See Additional Test Measurements for more information.

ctest(1) learned to be able to modify the environment for a test
through the ENVIRONMENT_MODIFICATION property. This is allows
for updates to environment variables based on the environment present at
test time.

The ctest_memcheck() command now also generates a
DynamicAnalysis-Test.xml file which may be used to submit test
results to CDash.

CPack¶

The CPack DEB Generator gained the
option to set CPACK_DEBIAN_COMPRESSION_TYPE to zstd,
which enables Zstandard compression for deb packages.

The CPack NSIS Generator gained a new
CPACK_NSIS_IGNORE_LICENSE_PAGE variable to suppress
the license page in the installer.

The CPack RPM Generator gained the
CPACK_RPM_REQUIRES_EXCLUDE_FROM option to avoid scanning
specific paths for dependencies.

Deprecated and Removed Features¶

The Visual Studio 10 2010 generator is now deprecated
and will be removed in a future version of CMake.

Other Changes¶

The Compile Features functionality now
correctly disables or enables compiler extensions when no standard level is
specified and avoids unnecessarily adding language standard flags if the
requested settings match the compiler's defaults. See CMP0128.

The Compile Features functionality
now ignores features for languages that are not enabled.

The Ninja Generators now implement the edit_cache target
using ccmake(1) if available.

The Ninja and NMake Makefiles generators
now use the MSVC -external:I flag for system includes.
This became available as of VS 16.10 (toolchain version 14.29.30037).

The CPack NSIS Generator now requires NSIS 3.03 or later.

Updates¶

Changes made since CMake 3.22.0 include the following.

3.22.1¶

This version made no changes to documented features or interfaces.
Some implementation updates were made to support ecosystem changes
and/or fix regressions.

3.22.2¶

The OLD behavior of CMP0128 was fixed to add flags even when
the specified standard matches the compiler default.

3.22.3¶

The while() command again ignores errors in condition evaluation
as CMake 3.21 and below did.  This bug was fixed in 3.22.0, but exposed
errors in existing projects.  The fix has been reverted to restore
compatibility.  The fix may be restored in a future version of CMake
via a policy.

3.22.4, 3.22.5, 3.22.6¶

These versions made no changes to documented features or interfaces.
Some implementation updates were made to support ecosystem changes
and/or fix regressions.

Table of Contents

CMake 3.22 Release Notes

New Features

Commands

Variables

Properties

Modules

CTest

CPack

Deprecated and Removed Features

Other Changes

Updates

3.22.1

3.22.2

3.22.3

3.22.4, 3.22.5, 3.22.6

Previous topic

CMake 3.23 Release Notes

Next topic

CMake 3.21 Release Notes

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 Release Notes »

CMake 3.22 Release Notes

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