Open-source software tool for managing the build process of software!

Cmake

Cmake

  -  32.7 MB  -  Open Source
  • Latest Version

    Cmake 4.0.0 (64-bit) LATEST

  • Review by

    Daniel Leblanc

  • Operating System

    Windows 7 64 / Windows 8 64 / Windows 10 64 / Windows 11

  • User Rating

    Click to vote
  • Author / Product

    Kitware, Inc. / External Link

  • Filename

    cmake-4.0.0-windows-x86_64.msi

CMake is an open-source, cross-platform family of tools designed to build, test and package software.

The app is used to control the software compilation process using simple platform and compiler independent configuration files, and generate native makefiles and workspaces that can be used in the compiler environment of your choice.

The suite of the tools was created by Kitware in response to the need for a powerful, cross-platform build environment for open-source projects such as ITK and VTK.

CMake 64 bit is an extensible, open-source system that manages the build process in an operating system and in a compiler-independent manner. Unlike many cross-platform systems, It is designed to be used in conjunction with the native build environment.

Simple configuration files placed in each source directory (called CMakeLists.txt files) are used to generate standard build files (e.g., makefiles on Unix and projects/workspaces in Windows MSVC) which are used in the usual way.

It can generate a native build environment that will compile source code, create libraries, generate wrappers, and build executables in arbitrary combinations.

It supports in-place and out-of-place builds, and can, therefore, support multiple builds from a single source tree. It also supports static and dynamic library builds.

Another nice feature of the app is that it generates a cache file that is designed to be used with a graphical editor. For example, when CMake runs, it locates files, libraries, and executables, and may encounter optional build directives. This information is gathered into the cache, which may be changed by the user prior to the generation of the native build files.

CMake is designed to support complex directory hierarchies and applications dependent on several libraries. For example, It supports projects consisting of multiple toolkits (i.e., libraries), where each toolkit might contain several directories, and the application depends on the toolkits plus additional code.

It can also handle situations where executables must be built in order to generate code that is then compiled and linked into a final application. Because the app is open source and has a simple, extensible design, It can be extended as necessary to support new features.

Features and Highlights
  • Supports complex, large build environments. It has been proven in several large projects.
  • Generates native build files (e.g., makefiles on Unix; workspaces/projects on MS Visual C++). Therefore standard tools can be used on any platform/compiler configuration.
  • Has powerful commands include the ability to locate include files, libraries, executables; include external CMake files that encapsulate standard functionality; interfaces to testing systems; supports recursive directory traversal with variable inheritance; can run external programs; supports conditional builds; supports regular expression expansion; and so on.
  • Supports in-place and out-of-place builds. Multiple compilation trees are possible from a single source tree.
  • It can be easily extended to add new features.
  • It operates with a cache designed to be interfaced with a graphical editor. The cache provides optional interaction to conditionally control the build process.
How to Use
  • Prepare Source Code – Ensure your project has a CMakeLists.txt file in the root directory.
  • Create a Build Directory – Run mkdir build and navigate to it using cd build.
  • Generate Build Files – Execute cmake .. inside the build directory to generate project files.
  • Select a Generator (Optional) – Use cmake -G "Generator Name" .. to specify a build system (e.g., Ninja, MinGW Makefiles).
  • Build the Project – Run cmake --build . to compile the software.
  • Run Executable – Find the generated binary in the build directory and execute it.
  • Install the Software (Optional) – Use cmake --install . to install it on your system.
  • Clean Build Files – Use rm -rf build (Linux/macOS) or rmdir /s /q build (Windows) to remove build files.
  • Debug and Configure – Modify CMakeLists.txt or use ccmake/cmake-gui to tweak settings.
Alternatives

If you are looking for Cmake alternatives, we recommend you to download Apache Maven or Gradle.

PROS
  • Cross-Platform Support
  • Powerful Build Configuration
  • Wide Language Support
  • Integration with IDEs
  • Extensive Community and Documentation
CONS
  • Complex Syntax
  • Difficult Debugging
  • Lack of Standardization
  • Dependency Management Challenges


  • Cmake 4.0.0 (64-bit) Screenshots

    The images below have been resized. Click on them to view the screenshots in full size.

    Cmake 4.0.0 (64-bit) Screenshot 1
  • Cmake 4.0.0 (64-bit) Screenshot 2
  • Cmake 4.0.0 (64-bit) Screenshot 3

What's new in this version:

New Features:
File-Based API:
- The cmake-file-api(7) "codemodel" version 2 version field has been updated to 2.8
- The cmake-file-api(7) "codemodel" version 2 "target" object gained a new debugger field

Command-Line:
- The cmake --link-no-warning-as-error option was added to suppress the effects of the LINK_WARNING_AS_ERROR target property and CMAKE_LINK_WARNING_AS_ERROR variable
- The cmake --project-file option was added to specify an alternate filename for CMakeLists.txt files. This is intended for temporary use by developers during an incremental transition and not for publication of a final product. CMake will always emit a warning when the project file is anything other than CMakeLists.txt.

Commands:
- The target_link_libraries() command now supports the LINKER: prefix

Variables:
- The AIX and CMAKE_HOST_AIX variables are now set to true when the target or host system is AIX, respectively

Linker flag variables learned to support the LINKER: prefix:
- CMAKE_EXE_LINKER_FLAGS
- CMAKE_EXE_LINKER_FLAGS_<CONFIG>
- CMAKE_SHARED_LINKER_FLAGS
- CMAKE_SHARED_LINKER_FLAGS_<CONFIG>
- CMAKE_MODULE_LINKER_FLAGS
- CMAKE_MODULE_LINKER_FLAGS_<CONFIG>
- The CMAKE_EXECUTE_PROCESS_COMMAND_ERROR_IS_FATAL variable was added to specify the execute_process() command's default COMMAND_ERROR_IS_FATAL behavior
- The CMAKE_<LANG>_LINK_MODE and CMAKE_<LANG>_DEVICE_LINK_MODE variables were added to provide information on how the link step is done
- The CMAKE_LINK_WARNING_AS_ERROR variable and corresponding LINK_WARNING_AS_ERROR target property were added to link using a linker-specific flag to treat warnings as errors
- The CMAKE_MSVC_RUNTIME_CHECKS variable and MSVC_RUNTIME_CHECKS target property were introduced to select runtime checks for compilers targeting the MSVC ABI. See policy CMP0184
- The CMAKE_POLICY_VERSION_MINIMUM variable was added to help packagers and end users try to configure existing projects that have not been updated to work with supported CMake versions. The CMAKE_POLICY_VERSION_MINIMUM environment variable was added to initialize it.
- The CMAKE_XCODE_SCHEME_LLDB_INIT_FILE variable and corresponding XCODE_SCHEME_LLDB_INIT_FILE target property were added to tell the Xcode generator what to put in the scheme's "LLDB Init File" setting.
- The CMAKE_XCODE_SCHEME_TEST_CONFIGURATION variable and corresponding XCODE_SCHEME_TEST_CONFIGURATION target property were added to tell the Xcode generator what to put in the scheme's "Build Configuration" setting for the test action.

Properties:
- The DEBUGGER_WORKING_DIRECTORY target property and corresponding CMAKE_DEBUGGER_WORKING_DIRECTORY variable were added to tell generators what debugger working directory should be set for targets
- The STATIC_LIBRARY_OPTIONS target property now supports an ARCHIVER: prefix to pass options to the archiver through the compiler driver in a portable way
- The Swift_MODULE_DIRECTORY target property now supports generator expressions
- The VS_CUSTOM_COMMAND_DISABLE_PARALLEL_BUILD source file property was added to tell Visual Studio Generators not to run a custom command in parallel
- The VS_SOLUTION_ITEMS directory property was added to tell Visual Studio Generators to attach files directly to the Solution (.sln)

Modules:
- The ExternalData module gained a ExternalData_HTTPHEADERS variable to specify HTTP headers
- The ExternalProject module's ExternalProject_Add() command gained an INSTALL_JOB_SERVER_AWARE option to enable integration of the GNU Make job server when using an explicit INSTALL_COMMAND with Makefile Generators.
- The FeatureSummary module add_feature_info() command now supports full Condition Syntax. See policy CMP0183.
- The FindBISON module bison_target() command gained an OPTIONS option to specify Bison command-line options
- The FindCURL module now provides a CURL_VERSION result variable to match upstream cURL's CMake package
- The FindFLEX module flex_target() command gained an OPTIONS option to specify Flex command-line options
- The FindPatch module now supports running in cmake -P script mode by skipping the creation of the imported target
- The FindProtobuf module protobuf_generate() command gained a PROTOC_EXE option to specify a custom protoc executable
- The FindPython, FindPython2, and FindPython3 modules gained the possibility to do multiple calls in the same directory by using, respectively, the variables Python_ARTIFACTS_PREFIX, Python2_ARTIFACTS_PREFIX, and Python3_ARTIFACTS_PREFIX.
- The FindRuby module learned to find rbenv-provided installations.

Generator Expressions:
- The $<PATH> generator expression gained the NATIVE_PATH operation to convert a CMake path into a native one.

CTest:
- The ctest --interactive-debug-mode option on Windows now enables Windows Error Reporting by default in test processes, allowing them to creating debug popup windows and core dumps. This restores behavior previously removed by CMake 3.11 after updates to libuv made it possible.

CPack:
- The CPack Archive Generator learned to generated .tar packages without compression
- The CPack Archive Generator now honors the CPACK_ARCHIVE_FILE_NAME variable for all packages. Previously, this variable worked only for component-based packages.

Deprecated and Removed Features:
- Compatibility with versions of CMake older than 3.5 has been removed. Calls to cmake_minimum_required() or cmake_policy() that set the policy version to an older value now issue an error. Note that calls to those commands can still support older versions of CMake by using their VERSION arguments' <min>...<max> syntax. This requires only the <min> version of CMake, but when running a newer version, sets policies up to the <max> version.
- The Visual Studio 14 2015 and Visual Studio 15 2017 generators no longer support specifying a platform as part of the generator name. See Visual Studio Platform Selection.
- The CMAKE_<LANG>_USING_LINKER_MODE variable is no longer used to determine the type of the contents of the CMAKE_<LANG>_USING_LINKER_<TYPE> variable. The CMAKE_<LANG>_LINK_MODE variable, set by CMake, is used instead.
- The FindGDAL module is now deprecated in favor of upstream GDAL's official CMake package configuration file. Port projects to the latter by calling find_package(GDAL CONFIG). For further details, see GDAL's documentation on CMake integration.
- The FindRuby module no longer provides variables with the upper-case RUBY_ prefix. See policy CMP0185.
- CTest's undocumented declarative scripting mode has been removed. This mode used to be triggered by a ctest -S script which did not call any CTest Commands unless CTEST_RUN_CURRENT_SCRIPT was explicitly set to OFF.
- The ctest_run_script() command may no longer be called without any arguments.

Other Changes:
- Builds targeting macOS no longer choose any SDK or pass an -isysroot flag to the compiler by default. Instead, compilers are expected to choose a default macOS SDK on their own. In order to use a compiler that does not do this, users must now specify -DCMAKE_OSX_SYSROOT=macosx when configuring their build.
- On AIX, SHARED library targets now produce a shared library archive by default. See policy CMP0182.
- The cmake --preset command no longer outputs a summary of the preset's CMake cache and environment variables by default. That summary is now only shown when the message log level is set to VERBOSE, DEBUG, or TRACE via the cmake --log-level option or the CMAKE_MESSAGE_LOG_LEVEL cache variable.
- Precompiled SunOS sparc64 and x86_64 binaries are now provided on cmake.org.