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

Upgrading CMake

The built-in CMake software of the system cannot meet the MySQL compilation requirements. Upgrade CMake to 3.4.3 or later. The following describes how to upgrade CMake to 3.5.2.

  1. Download the CMake 3.5.2 package.

    URL: https://cmake.org/files/v3.5/cmake-3.5.2.tar.gz

  2. Upload the package to the /home directory on the server and decompress it.
    1
    2
    cd /home
    tar -zxvf cmake-3.5.2.tar.gz
    

  3. Go to the directory where the source code package is decompressed.
    1
    cd cmake-3.5.2
    
  4. Upgrade CMake.
    1
    ./bootstrap
    

    1
    make -j96
    

    In the command, -j96 can make full use of the multi-core feature of the CPUs to accelerate the compilation. The number following -j indicates the number of CPU cores. You can run the cat /proc/cpuinfo | grep processor | wc -l command to query the number of CPU cores. The value specified must be less than or equal to the actual number of CPU cores.

    1
    make install
    

  5. Check whether the CMake version is 3.5.2.
    1
    /usr/local/bin/cmake --version