Install the latest version of redis-6.0.9, solve the error when make

Today, let's record the latest version 6.0.9 of redis installed on centos7.
If you have any friends who can't install it, you can check my previous blog.
https://blog.csdn.net/hello_cmy/article/details/105729135.

make error

Install according to the above blog, when you go to step 4, you will get an error.
Insert picture description here

The error message is as follows:
Insert picture description here

The reason for the error here is that the gcc version is too low, and the gcc version needs to be upgraded.

solve

Under the path of step 4: enter the following command:

yum -y install centos-release-scl

yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++ devtoolset-9-binutils

After execution, you will see the following Complete!
Insert picture description here
and then execute the following command:

scl enable devtoolset-9 bash
echo "source /opt/rh/devtoolset-9/enable" >> /etc/profile
gcc -v

Successful execution, you can see the gcc version.
Insert picture description here
After that, the make operation will be no problem.

For the next steps, please see https://blog.csdn.net/hello_cmy/article/details/105729135.

Guess you like

Origin blog.csdn.net/hello_cmy/article/details/111477373