1
0
mirror of synced 2024-12-22 12:40:00 +01:00

chore: add 3.26

This commit is contained in:
Henry Schreiner 2023-03-15 00:35:08 +00:00
parent 9e7144e85d
commit 9bb1bc7e9f
13 changed files with 40 additions and 46 deletions

View File

@ -1,5 +1,5 @@
[bumpversion] [bumpversion]
current_version = 3.25.0 current_version = 3.26.0
[bumpversion:file:.gitlab-ci.yml] [bumpversion:file:.gitlab-ci.yml]
search = cmake-{current_version}-linux search = cmake-{current_version}-linux

View File

@ -5,7 +5,7 @@ test_code:
- apt-get update && apt-get install -y make cmake libboost-dev git - apt-get update && apt-get install -y make cmake libboost-dev git
# We will install latest CMake, even though Ubuntu has a recent one # We will install latest CMake, even though Ubuntu has a recent one
- mkdir -p $HOME/.local - mkdir -p $HOME/.local
- curl -s "https://cmake.org/files/v3.25/cmake-3.25.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C $HOME/.local - curl -s "https://cmake.org/files/v3.26/cmake-3.26.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C $HOME/.local
- export PATH=$HOME/.local/bin:$PATH - export PATH=$HOME/.local/bin:$PATH
script: script:
- cmake -S examples -B build - cmake -S examples -B build

View File

@ -7,7 +7,7 @@ Certainly there are no shortage of problems when building.
But I think that, in 2022, we have a very good solution to quite a few of those problems. But I think that, in 2022, we have a very good solution to quite a few of those problems.
It's CMake. Not CMake 2.8 though; that was released before C++11 even existed! It's CMake. Not CMake 2.8 though; that was released before C++11 even existed!
Nor the horrible examples out there for CMake (even those posted on KitWare's own tutorials list). Nor the horrible examples out there for CMake (even those posted on KitWare's own tutorials list).
I'm talking about Modern CMake. CMake 3.4+, maybe even CMake 3.25+! I'm talking about Modern CMake. CMake 3.4+, maybe even CMake 3.26+!
It's clean, powerful, and elegant, so you can spend most of your time coding, not adding lines to an unreadable, unmaintainable Make (Or CMake 2) file. It's clean, powerful, and elegant, so you can spend most of your time coding, not adding lines to an unreadable, unmaintainable Make (Or CMake 2) file.
And CMake 3.11+ is supposed to be significantly faster, as well! And CMake 3.11+ is supposed to be significantly faster, as well!

View File

@ -34,7 +34,7 @@ Windows users, who also usually have a very recent version of CMake.
This is what new projects should do: This is what new projects should do:
```cmake ```cmake
cmake_minimum_required(VERSION 3.7...3.25) cmake_minimum_required(VERSION 3.7...3.26)
if(${CMAKE_VERSION} VERSION_LESS 3.12) if(${CMAKE_VERSION} VERSION_LESS 3.12)
cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}) cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
@ -54,10 +54,10 @@ you will want to do this instead:
```cmake ```cmake
cmake_minimum_required(VERSION 3.7) cmake_minimum_required(VERSION 3.7)
if(${CMAKE_VERSION} VERSION_LESS 3.25) if(${CMAKE_VERSION} VERSION_LESS 3.26)
cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}) cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
else() else()
cmake_policy(VERSION 3.25) cmake_policy(VERSION 3.26)
endif() endif()
``` ```

View File

@ -4,7 +4,7 @@
Your CMake version should be newer than your compiler. It should be newer than the libraries you are using (especially Boost). New versions work better for everyone. Your CMake version should be newer than your compiler. It should be newer than the libraries you are using (especially Boost). New versions work better for everyone.
{% endhint %} {% endhint %}
If you have a built in copy of CMake, it isn't special or customized for your system. You can easily install a new one instead, either on the system level or the user level. Feel free to instruct your users here if they complain about a CMake requirement being set too high. Especially if they want 3.1+ support. Maybe even if they want 3.25+ support... If you have a built in copy of CMake, it isn't special or customized for your system. You can easily install a new one instead, either on the system level or the user level. Feel free to instruct your users here if they complain about a CMake requirement being set too high. Especially if they want 3.1+ support. Maybe even if they want 3.26+ support...
#### Quick list (more info on each method below) #### Quick list (more info on each method below)
@ -35,14 +35,14 @@ You can [download CMake from KitWare][download]. This is how you will probably g
On Linux, there are several options. Kitware provides a [Debian/Ubuntu apt repository][apt], as well as [snap packages][snap]. There are universal Linux binaries provided, but you'll need to pick an install location. If you already use `~/.local` for user-space packages, the following single line command[^1] will get CMake for you [^2]: On Linux, there are several options. Kitware provides a [Debian/Ubuntu apt repository][apt], as well as [snap packages][snap]. There are universal Linux binaries provided, but you'll need to pick an install location. If you already use `~/.local` for user-space packages, the following single line command[^1] will get CMake for you [^2]:
{% term %} {% term %}
~ $ wget -qO- "https://cmake.org/files/v3.25/cmake-3.25.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C ~/.local ~ $ wget -qO- "https://cmake.org/files/v3.26/cmake-3.26.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C ~/.local
{% endterm %} {% endterm %}
The names changed in 3.20; older releases had names like `cmake-3.19.7-Linux-x86_64.tar.gz`. If you just want a local folder with CMake only: The names changed in 3.20; older releases had names like `cmake-3.19.7-Linux-x86_64.tar.gz`. If you just want a local folder with CMake only:
{% term %} {% term %}
~ $ mkdir -p cmake-3.25 && wget -qO- "https://cmake.org/files/v3.25/cmake-3.25.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C cmake-3.25 ~ $ mkdir -p cmake-3.26 && wget -qO- "https://cmake.org/files/v3.26/cmake-3.26.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C cmake-3.26
~ $ export PATH=`pwd`/cmake-3.25/bin:$PATH ~ $ export PATH=`pwd`/cmake-3.26/bin:$PATH
{% endterm %} {% endterm %}
You'll obviously want to append to the PATH every time you start a new terminal, or add it to your `.bashrc` or to an [LMod][] system. You'll obviously want to append to the PATH every time you start a new terminal, or add it to your `.bashrc` or to an [LMod][] system.
@ -50,7 +50,7 @@ You'll obviously want to append to the PATH every time you start a new terminal,
And, if you want a system install, install to `/usr/local`; this is an excellent choice in a Docker container, for example on GitLab CI. Do not try it on a non-containerized system. And, if you want a system install, install to `/usr/local`; this is an excellent choice in a Docker container, for example on GitLab CI. Do not try it on a non-containerized system.
{% term %} {% term %}
docker $ wget -qO- "https://cmake.org/files/v3.25/cmake-3.25.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C /usr/local docker $ wget -qO- "https://cmake.org/files/v3.26/cmake-3.26.0-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C /usr/local
{% endterm %} {% endterm %}
If you are on a system without wget, replace `wget -qO-` with `curl -s`. If you are on a system without wget, replace `wget -qO-` with `curl -s`.
@ -132,8 +132,8 @@ Just `pip install cmake` on many systems. Add `--user` if you have to (modern pi
| ------------------------------------------------------------------------------------------------------------------------------------ | ------------- | ------------------------------------------------------------ | | ------------------------------------------------------------------------------------------------------------------------------------ | ------------- | ------------------------------------------------------------ |
| [TravisCI Xenial](https://docs.travis-ci.com/user/reference/xenial/#compilers-and-build-toolchain) | 3.12.4 | Mid November 2018 this image became ready for widescale use. | | [TravisCI Xenial](https://docs.travis-ci.com/user/reference/xenial/#compilers-and-build-toolchain) | 3.12.4 | Mid November 2018 this image became ready for widescale use. |
| [TravisCI Bionic](https://docs.travis-ci.com/user/reference/bionic/#compilers-and-build-toolchain) | 3.12.4 | Same as Xenial at the moment. | | [TravisCI Bionic](https://docs.travis-ci.com/user/reference/bionic/#compilers-and-build-toolchain) | 3.12.4 | Same as Xenial at the moment. |
| [Azure DevOps](https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops#use-a-microsoft-hosted-agent) | 3.25.0 | kept up to date | | [Azure DevOps](https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops#use-a-microsoft-hosted-agent) | 3.26.0 | kept up to date |
| [GitHub Actions 20.04](https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md) | 3.25.0 | Same runners as Azure DevOps | | [GitHub Actions 20.04](https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md) | 3.26.0 | Same runners as Azure DevOps |
If you are using GitHub Actions, also see the [jwlawson/actions-setup-cmake](https://github.com/marketplace/actions/actions-setup-cmake) action, which can install your selection of CMake, even in a docker action run. If you are using GitHub Actions, also see the [jwlawson/actions-setup-cmake](https://github.com/marketplace/actions/actions-setup-cmake) action, which can install your selection of CMake, even in a docker action run.

View File

@ -4,7 +4,25 @@ This is an abbreviated version of the CMake changelog with just the highlights f
## [CMake in development][cmake master]: WIP ## [CMake in development][cmake master]: WIP
- FindCUDA fully deprecated, use CUDA language and FindCUDAToolkit
- C++ Modules extensions (`.ccm`, ` .cxxm``, `.c++m`) are treated as C++
## [CMake 3.26][]: Logging & Python
Two important additions for FindPython, PyPy SOABI support & LimitedAPI/StableABI support, really enhance FindPython's use. There are quite
a few nice fixes and new warnings, such as if you reverse the order of `project()` and `cmake_minimium_required()`. Logging has been moved
from `CMakeOutput.log` and `CMakeError.log` to a new `CMakeConfigureLog.yaml` log.
- Initially released [March 14, 2023](https://www.kitware.com/cmake-3-26-0-available-for-download/)
- FindPython generates the correct PyPy SOABI (finally!) - FindPython generates the correct PyPy SOABI (finally!)
- FindPython supports LimitedAPI/StableABI with a new flag.
- CMake has a new YAML log of configure time checks in the output directory (also `message(CONFIGURE_LOG ...)`).
- `ASM_MARMASM` language added for Microsoft ARM assembler.
- `CMAKE_VS_VERSION_BUILD_NUMBER` added for the VS version number.
- `USE_FOLDERS` is on by default
- `"<LANG>_CLANG_TIDY_EXPORT_FIXES_DIR"` for clang-tidy suggested fix output.
- CMake's copy CLI tool supports updates only if different
- `target_compile_options` now come after `target_compile_features` / `CMAKE_<LANG>_STANDARD`
## [CMake 3.25][]: Blocks and SYSTEM ## [CMake 3.25][]: Blocks and SYSTEM
@ -24,7 +42,6 @@ of CMake introduced a few releases ago are now usable in `find_` commands with
- Several improvements to `try_*` commands. - Several improvements to `try_*` commands.
- `SYSTEM` target/directory property and `EXPORT_NO_SYSTEM` added, also for FetchContent. - `SYSTEM` target/directory property and `EXPORT_NO_SYSTEM` added, also for FetchContent.
## [CMake 3.24][]: Package Finder ## [CMake 3.24][]: Package Finder
This is a fantastic release. Package writers are getting integration between This is a fantastic release. Package writers are getting integration between
@ -47,7 +64,6 @@ do this unless you are being build as the main project!).
- Better support for MSVC, XCode, and others. - Better support for MSVC, XCode, and others.
- `LLVMFlang` compiler support. - `LLVMFlang` compiler support.
## [CMake 3.23][]: Header only libraries ## [CMake 3.23][]: Header only libraries
A solid release focused on header only libraries, more user control, CMake A solid release focused on header only libraries, more user control, CMake
@ -73,7 +89,6 @@ couple of compilers were added.
- `IMPORTED_NO_SYSTEM`, a new property to forcibly remove SYSTEM from a target. - `IMPORTED_NO_SYSTEM`, a new property to forcibly remove SYSTEM from a target.
- `FindGTest` now adds a `GMock` target if found. - `FindGTest` now adds a `GMock` target if found.
## [CMake 3.22][]: Handy env vars ## [CMake 3.22][]: Handy env vars
A smaller release with some nice improvements all around focused on supporting A smaller release with some nice improvements all around focused on supporting
@ -92,7 +107,6 @@ information.
- CTest can now modify environment variables - CTest can now modify environment variables
- Some generators now use external (system) markers on includes for MSVC - Some generators now use external (system) markers on includes for MSVC
## [CMake 3.21][] : Colors ## [CMake 3.21][] : Colors
Different message types now have different colors! There's now a nice variable Different message types now have different colors! There's now a nice variable
@ -113,7 +127,6 @@ support. Presets continue to be improved.
- `PROJECT_IS_TOP_LEVEL` and `<PROJECT-NAME>_IS_TOP_LEVEL` finally added - `PROJECT_IS_TOP_LEVEL` and `<PROJECT-NAME>_IS_TOP_LEVEL` finally added
- Caching improvements for the `find_` commands - Caching improvements for the `find_` commands
## [CMake 3.20][] : Docs ## [CMake 3.20][] : Docs
The CMake docs received a major boost in productivity by adding "new in" tags The CMake docs received a major boost in productivity by adding "new in" tags
@ -134,7 +147,6 @@ continue to be improved.
- Several removals, like `cmake-server`, `WriteCompilerDetectionHeader` (if policy set to 3.20+), and a few things that have newer methods now. - Several removals, like `cmake-server`, `WriteCompilerDetectionHeader` (if policy set to 3.20+), and a few things that have newer methods now.
- Source files must include the extension - Source files must include the extension
## [CMake 3.19][] : Presets ## [CMake 3.19][] : Presets
You can now add presets in JSON form, and users will get the preset default. You can now add presets in JSON form, and users will get the preset default.
@ -159,7 +171,6 @@ for permissions. Further support for generator expressions in more places.
- FindPython: `Python*_LINK_OPTIONS` added - FindPython: `Python*_LINK_OPTIONS` added
- `compute-sanitizer` for ctest now supports CUDA for memcheck - `compute-sanitizer` for ctest now supports CUDA for memcheck
## [CMake 3.18][] : CUDA with Clang & CMake macro language ## [CMake 3.18][] : CUDA with Clang & CMake macro language
CUDA now supports Clang (without separable compilation). A new CUDA now supports Clang (without separable compilation). A new
@ -184,7 +195,6 @@ features and papercut fixes are sprinkled throughout, a small selection is below
- New `LINK_LANGUAGE` generator expressions (`DEVICE`/`HOST` versions too) - New `LINK_LANGUAGE` generator expressions (`DEVICE`/`HOST` versions too)
- Source can be a subdirectory for `FetchContent` - Source can be a subdirectory for `FetchContent`
## [CMake 3.17][] : More CUDA ## [CMake 3.17][] : More CUDA
A FindCUDAToolkit was finally added, which allows finding and using the CUDA A FindCUDAToolkit was finally added, which allows finding and using the CUDA
@ -205,7 +215,6 @@ as well, like FindPython. Finally, you can now iterate over multiple lists at a
- Several new environment variables - Several new environment variables
- foreach can now do `ZIP_LISTS` (multiple lists at a time) - foreach can now do `ZIP_LISTS` (multiple lists at a time)
## [CMake 3.16][] : Unity builds ## [CMake 3.16][] : Unity builds
A new unity build mode was added, allowing source files to be merged into a single build file. Support for A new unity build mode was added, allowing source files to be merged into a single build file. Support for
@ -221,7 +230,6 @@ fixes were implemented, especially to newer features, such as to FindPython, Fin
- Generator expressions work in more places, like build and install paths - Generator expressions work in more places, like build and install paths
- Find locations can now be explicitly controlled through new variables - Find locations can now be explicitly controlled through new variables
## [CMake 3.15][] : CLI upgrade ## [CMake 3.15][] : CLI upgrade
This release has many smaller polishing changes, include several of improvements to the CMake command line, such as control over the default generator through environment variables (so now it's easy to change the default generator to Ninja). Multiple targets are supported in `--build` mode, and `--install` mode added. CMake finally supports multiple levels of logging. Generator expressions gained a few handy tools. The still very new FindPython module continues to improve, and FindBoost is now more inline with Boost 1.70's new CONFIG This release has many smaller polishing changes, include several of improvements to the CMake command line, such as control over the default generator through environment variables (so now it's easy to change the default generator to Ninja). Multiple targets are supported in `--build` mode, and `--install` mode added. CMake finally supports multiple levels of logging. Generator expressions gained a few handy tools. The still very new FindPython module continues to improve, and FindBoost is now more inline with Boost 1.70's new CONFIG
@ -238,7 +246,6 @@ module. `export(PACKAGE)` has drastically changed; it now no longer touches `$HO
- Several Ninja improvements, include SWIFT language support - Several Ninja improvements, include SWIFT language support
- Compiler and list improvements to generator expressions - Compiler and list improvements to generator expressions
## [CMake 3.14][] : File utilities (AKA [CMake π](https://blog.kitware.com/kitware-gets-mathematical-with-cmake-π-on-pi-day/)) ## [CMake 3.14][] : File utilities (AKA [CMake π](https://blog.kitware.com/kitware-gets-mathematical-with-cmake-π-on-pi-day/))
This release has lots of small cleanups, including several utilities for files. Generator expressions work in a few more places, and list handling is better with empty variables. This release has lots of small cleanups, including several utilities for files. Generator expressions work in a few more places, and list handling is better with empty variables.
@ -252,7 +259,6 @@ Quite a few more find packages produce targets. The new Visual Studio 16 2019 ge
- `BUILD_RPATH_USE_ORIGIN` and CMake version were added to improve handling of RPath in the build directory. - `BUILD_RPATH_USE_ORIGIN` and CMake version were added to improve handling of RPath in the build directory.
- The CMake server mode is now being replaced with a file API, starting in this release. Will affect IDEs in the long run. - The CMake server mode is now being replaced with a file API, starting in this release. Will affect IDEs in the long run.
## [CMake 3.13][] : Linking control ## [CMake 3.13][] : Linking control
You can now make symbolic links on Windows! Lots of new functions that fill out the You can now make symbolic links on Windows! Lots of new functions that fill out the
@ -272,7 +278,6 @@ of the source directory, for better file separation. And, `target_sources` _fina
- `target_sources` is now relative to the current source directory (CMP0076) - `target_sources` is now relative to the current source directory (CMP0076)
- If you use Xcode, you now can experimentally set schema fields - If you use Xcode, you now can experimentally set schema fields
## [CMake 3.12][] : Version ranges and CONFIGURE_DEPENDS ## [CMake 3.12][] : Version ranges and CONFIGURE_DEPENDS
Very powerful release, containing lots of smaller long-requested features. One of the smaller Very powerful release, containing lots of smaller long-requested features. One of the smaller
@ -296,7 +301,6 @@ shiny new Python find module (2 and 3 versions too), and many more.
- Several new properties and property initializers - Several new properties and property initializers
- CPack finally reads `CMAKE_PROJECT_VERSION` variables - CPack finally reads `CMAKE_PROJECT_VERSION` variables
## [CMake 3.11][] : Faster & IMPORTED INTERFACE ## [CMake 3.11][] : Faster & IMPORTED INTERFACE
This release is [supposed to be][fastercmake] much faster. You can also finally directly add INTERFACE targets This release is [supposed to be][fastercmake] much faster. You can also finally directly add INTERFACE targets
@ -309,7 +313,6 @@ to IMPORTED libraries (the internal `Find*.cmake` scripts should become much cle
- Source file properties have been expanded - Source file properties have been expanded
- `FetchContent` module now allows downloads to happen at configure time (Wow) - `FetchContent` module now allows downloads to happen at configure time (Wow)
## [CMake 3.10][] : CppCheck ## [CMake 3.10][] : CppCheck
CMake now is built with C++11 compilers. Lots of useful improvements help write cleaner code. CMake now is built with C++11 compilers. Lots of useful improvements help write cleaner code.
@ -327,7 +330,6 @@ CMake now is built with C++11 compilers. Lots of useful improvements help write
- Dynamic test discovery for `GoogleTest` - Dynamic test discovery for `GoogleTest`
- `cmake_host_system_information` can access much more information. - `cmake_host_system_information` can access much more information.
## [CMake 3.9][] : IPO ## [CMake 3.9][] : IPO
Lots of fixes to CUDA support went into this release, including `PTX` support and MSVC generators. Interprocedural Optimizations are now supported properly. Lots of fixes to CUDA support went into this release, including `PTX` support and MSVC generators. Interprocedural Optimizations are now supported properly.
@ -342,7 +344,6 @@ Even more modules provide imported targets, including MPI.
- New `GoogleTest` module - New `GoogleTest` module
- `FindDoxygen` drastically improved - `FindDoxygen` drastically improved
## [CMake 3.8][] : C# & CUDA ## [CMake 3.8][] : C# & CUDA
This adds CUDA as a language, as well as `cxx_std_11` as a compiler meta-feature. The new generator expression could be really useful if you can require CMake 3.8+! This adds CUDA as a language, as well as `cxx_std_11` as a compiler meta-feature. The new generator expression could be really useful if you can require CMake 3.8+!
@ -358,7 +359,6 @@ This adds CUDA as a language, as well as `cxx_std_11` as a compiler meta-feature
- `$<IF:cond,true-value,false-value>` added (wow!) - `$<IF:cond,true-value,false-value>` added (wow!)
- `source_group(TREE` added (finally allowing IDEs to reflect the project folder structure!) - `source_group(TREE` added (finally allowing IDEs to reflect the project folder structure!)
## [CMake 3.7][] : Android & CMake Server ## [CMake 3.7][] : Android & CMake Server
You can now cross-compile to Android. Useful new if statement options really help clarify code. And the new server mode was supposed to improve integration with IDEs (but is being replaced by a different system in CMake 3.14+). Support for the VIM editor was also improved. You can now cross-compile to Android. Useful new if statement options really help clarify code. And the new server mode was supposed to improve integration with IDEs (but is being replaced by a different system in CMake 3.14+). Support for the VIM editor was also improved.
@ -372,7 +372,6 @@ You can now cross-compile to Android. Useful new if statement options really hel
- CMake Server added - CMake Server added
- Added `--trace-source="filename"` to monitor certain files only - Added `--trace-source="filename"` to monitor certain files only
## [CMake 3.6][] : Clang-Tidy ## [CMake 3.6][] : Clang-Tidy
This release added Clang-Tidy support, along with more utilities and improvements. It also removed the search of `$PATH` on Unix systems due to problems, instead users should use `$CMAKE_PREFIX_PATH`. This release added Clang-Tidy support, along with more utilities and improvements. It also removed the search of `$PATH` on Unix systems due to problems, instead users should use `$CMAKE_PREFIX_PATH`.
@ -385,7 +384,6 @@ This release added Clang-Tidy support, along with more utilities and improvement
- `*_CLANG_TIDY` property added - `*_CLANG_TIDY` property added
- External projects can now be shallow clones, and other improvements - External projects can now be shallow clones, and other improvements
## [CMake 3.5][] : ARM ## [CMake 3.5][] : ARM
This release expanded CMake to more platforms, and make warnings easier to control from the command line. This release expanded CMake to more platforms, and make warnings easier to control from the command line.
@ -397,7 +395,6 @@ This release expanded CMake to more platforms, and make warnings easier to contr
- ARMCC now supported, better support for iOS - ARMCC now supported, better support for iOS
- XCode backslash fix - XCode backslash fix
## [CMake 3.4][] : Swift & CCache ## [CMake 3.4][] : Swift & CCache
This release adds lots of useful tools, support for the Swift language, and the usual improvements. It also started supporting compiler launchers, like CCache. This release adds lots of useful tools, support for the Swift language, and the usual improvements. It also started supporting compiler launchers, like CCache.
@ -411,7 +408,6 @@ This release adds lots of useful tools, support for the Swift language, and the
- `TARGET_MESSAGES` allow makefiles to print messages after target is completed - `TARGET_MESSAGES` allow makefiles to print messages after target is completed
- Imported targets are beginning to show up in the official `Find*.cmake` files - Imported targets are beginning to show up in the official `Find*.cmake` files
## [CMake 3.3][] : if IN_LIST ## [CMake 3.3][] : if IN_LIST
This is notable for the useful `IN_LIST` option for if, but it also added better library search using `$PATH` (See CMake 3.6), dependencies for INTERFACE libraries, and several other useful improvements. The addition of a `COMPILE_LANGUAGE` generator expression would prove very useful in the future as more languages are added. Makefiles now produce better output in parallel. This is notable for the useful `IN_LIST` option for if, but it also added better library search using `$PATH` (See CMake 3.6), dependencies for INTERFACE libraries, and several other useful improvements. The addition of a `COMPILE_LANGUAGE` generator expression would prove very useful in the future as more languages are added. Makefiles now produce better output in parallel.
@ -421,7 +417,6 @@ This is notable for the useful `IN_LIST` option for if, but it also added better
- `*_INCLUDE_WHAT_YOU_USE` property added - `*_INCLUDE_WHAT_YOU_USE` property added
- `COMPILE_LANGUAGE` generator expression (limited support in some generators) - `COMPILE_LANGUAGE` generator expression (limited support in some generators)
## [CMake 3.2][] : UTF8 ## [CMake 3.2][] : UTF8
This is a smaller release, with mostly small features and fixes. Internal changes, like better Windows and UTF8 support, were the focus. This is a smaller release, with mostly small features and fixes. Internal changes, like better Windows and UTF8 support, were the focus.
@ -430,7 +425,6 @@ This is a smaller release, with mostly small features and fixes. Internal change
- `continue()` inside loops - `continue()` inside loops
- File and directory locks added - File and directory locks added
## [CMake 3.1][] : C++11 and compile features ## [CMake 3.1][] : C++11 and compile features
This is the first release of CMake to support C++11. Combined with fixes to the new features of CMake 3.0, this is currently a common minimum version of CMake for libraries that want to support old CMake builds. This is the first release of CMake to support C++11. Combined with fixes to the new features of CMake 3.0, this is currently a common minimum version of CMake for libraries that want to support old CMake builds.
@ -441,7 +435,6 @@ This is the first release of CMake to support C++11. Combined with fixes to the
- Sources can be added later with `target_sources` - Sources can be added later with `target_sources`
- Better support for generator expressions and INTERFACE targets - Better support for generator expressions and INTERFACE targets
## [CMake 3.0][] : Interface libraries ## [CMake 3.0][] : Interface libraries
There were a ton of additions to this version of CMake, primarily to fill out the target interface. Some bits of needed functionality were missed and implemented in CMake 3.1 instead. There were a ton of additions to this version of CMake, primarily to fill out the target interface. Some bits of needed functionality were missed and implemented in CMake 3.1 instead.
@ -481,5 +474,6 @@ There were a ton of additions to this version of CMake, primarily to fill out th
[cmake 3.23]: https://cmake.org/cmake/help/latest/release/3.23.html [cmake 3.23]: https://cmake.org/cmake/help/latest/release/3.23.html
[cmake 3.24]: https://cmake.org/cmake/help/latest/release/3.24.html [cmake 3.24]: https://cmake.org/cmake/help/latest/release/3.24.html
[cmake 3.25]: https://cmake.org/cmake/help/latest/release/3.25.html [cmake 3.25]: https://cmake.org/cmake/help/latest/release/3.25.html
[cmake 3.26]: https://cmake.org/cmake/help/latest/release/3.26.html
[cmake master]: https://cmake.org/cmake/help/git-master/release/index.html [cmake master]: https://cmake.org/cmake/help/git-master/release/index.html
[fastercmake]: https://blog.kitware.com/improving-cmakes-runtime-performance/ [fastercmake]: https://blog.kitware.com/improving-cmakes-runtime-performance/

View File

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.11...3.25) cmake_minimum_required(VERSION 3.11...3.26)
project(ModernCMakeExamples) project(ModernCMakeExamples)
set(MODERN_CMAKE_BUILD_TESTING ON) set(MODERN_CMAKE_BUILD_TESTING ON)

View File

@ -1,5 +1,5 @@
# Works with 3.14 and tested through 3.25 # Works with 3.14 and tested through 3.26
cmake_minimum_required(VERSION 3.14...3.25) cmake_minimum_required(VERSION 3.14...3.26)
# Project name and a few useful settings. Other commands can pick up the results # Project name and a few useful settings. Other commands can pick up the results
project( project(

View File

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.14...3.25) cmake_minimum_required(VERSION 3.14...3.26)
project(FetchExample LANGUAGES CXX) project(FetchExample LANGUAGES CXX)

View File

@ -2,7 +2,7 @@
## [main] ## [main]
cmake_minimum_required(VERSION 3.4...3.25) cmake_minimum_required(VERSION 3.4...3.26)
project(RootDictExample LANGUAGES CXX) project(RootDictExample LANGUAGES CXX)

View File

@ -1,7 +1,7 @@
# CMake ROOT simple example # CMake ROOT simple example
## [main] ## [main]
cmake_minimum_required(VERSION 3.1...3.25) cmake_minimum_required(VERSION 3.1...3.26)
project(RootSimpleExample LANGUAGES CXX) project(RootSimpleExample LANGUAGES CXX)

View File

@ -1,7 +1,7 @@
# CMake ROOT usefile example # CMake ROOT usefile example
## [main] ## [main]
cmake_minimum_required(VERSION 3.1...3.25) cmake_minimum_required(VERSION 3.1...3.26)
project(RootUseFileExample LANGUAGES CXX) project(RootUseFileExample LANGUAGES CXX)

View File

@ -6,7 +6,7 @@
# You should always specify a range with the newest # You should always specify a range with the newest
# and oldest tested versions of CMake. This will ensure # and oldest tested versions of CMake. This will ensure
# you pick up the best policies. # you pick up the best policies.
cmake_minimum_required(VERSION 3.1...3.25) cmake_minimum_required(VERSION 3.1...3.26)
# This is your project statement. You should always list languages; # This is your project statement. You should always list languages;
# Listing the version is nice here since it sets lots of useful variables # Listing the version is nice here since it sets lots of useful variables