Setup CMake
Set up a specific version of a CMake compiler and add it to the PATH.
This action will also set-up any dependencies required by CMake.
In most workflows, this is used as an auxiliary action for the CMake Workflow action, which already calls this action if necessary.
Input Parameters
Parameter |
Description |
Default |
|
Version range or exact version of CMake to use, using SemVer’s version range syntax. Reads from By default, it uses any version available in the environment. |
|
|
The target architecture (x86, x64). By default, this value is inferred. |
|
|
File containing the CMake version to use in a cmake_minimum_required command. Example: A CMakeLists.txt file containing a call to cmake_minimum_required.". |
|
|
Path to the cmake executable. The action attempts to find cmake at this path first. |
|
|
The cmake executable. We attempt to find cmake at this path first. This option is available for backwards compatibility and has priority over |
|
|
Used to specify whether the CMake installation should be cached in the case CMake needs to be downloaded. As binaries are provided for all versions of CMake, this option is deprecated and will be removed in a future release. |
|
|
By default, when CMake is not available, this action will install the minimum version in the version spec. This ensures the code respects its contract in terms of what minimum CMake version is supported. Set this option if you want the action to check for the latest available version that satisfies the version spec instead. |
|
|
Set this option if you want the action to update environment variables. |
|
|
Trace commands executed by the workflow. |
|
Outputs
Output |
Description |
|
The absolute path to the CMake executable. |
|
The absolute path to the CMake directory. |
|
The installed CMake version. Useful when given a version range as input. |
|
The installed CMake version major. Useful when given a version range as input. |
|
The installed CMake version minor. Useful when given a version range as input. |
|
The installed CMake version patch. Useful when given a version range as input. |
|
A boolean value to indicate a cache entry was found |
|
Whether CMake supports the -B <path-to-build> syntax |
|
Whether CMake supports the -j <threads> syntax |
|
Whether CMake supports the --target with multiple targets |
|
Whether CMake supports the cmake --install |