我要评分
获取效率
正确性
完整性
易理解

Installing CMake

To ensure that the CMake version used for compilation meets the Milvus requirements, it is advised to install CMake 3.26 or later.

CMake is an open source, cross-platform tool for building systems and managing the software build process. It streamlines the software configuration, build, and installation in different OSs and compiler environments. CMake does not directly compile code. Instead, it generates platform-specific build files such as Makefile files, Visual Studio project files, and Xcode projects. These files can be used to compile source code.

  1. Download the CMake source package.
    1
    wget https://cmake.org/files/v3.27/cmake-3.27.9.tar.gz --no-check-certificate
    
  2. Decompress the CMake source package.
    1
    tar -zxf cmake-3.27.9.tar.gz
    
  3. Compile and install CMake.
    1
    2
    3
    4
    cd cmake-3.27.9
    ./configure --prefix=/usr/local/cmake
    make -j96
    make -j96 install
    
  4. Set environment variables for CMake to take effect.
    1
    2
    echo "export PATH=/usr/local/cmake/bin:$PATH" >> ~/.bashrc
    source ~/.bashrc
    
  5. Check the CMake version.
    1
    cmake --version
    

    The installation is successful if the following information is displayed:

    1
    2
    cmake version 3.27.9
    CMake suite maintained and supported by Kitware (kitware.com/cmake).