From a51405df170301d85208efe3042708e88f5cdf69 Mon Sep 17 00:00:00 2001 From: liuchengyu Date: Fri, 5 Jan 2024 19:09:06 +0800 Subject: [PATCH] fix: gcc version must be greater than or equal to 9 (#2275) --- README.md | 8 ++++---- README_CN.md | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 532b85efb6..faef42c412 100644 --- a/README.md +++ b/README.md @@ -115,7 +115,7 @@ Users can directly download the latest binary version package from [releases](ht * #### 2.2 Required Library Software - * gcc g++ supporting C++17 (version >= 7) + * gcc g++ supporting C++17 (version >= 9) * make * cmake (version >= 3.18) * autoconf @@ -138,12 +138,12 @@ Users can directly download the latest binary version package from [releases](ht * 2.3.3. Execute compilation - > If the machine's gcc version is less than 7, especially on CentOS6 or CentOS7, you need to upgrade the gcc version first. Execute the following commands: + > If the machine's gcc version is less than 9, especially on CentOS6 or CentOS7, you need to upgrade the gcc version first. Execute the following commands: > > ```bash > sudo yum -y install centos-release-scl - > sudo yum -y install devtoolset-7-gcc devtoolset-7-gcc-c++ - > scl enable devtoolset-7 bash + > sudo yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++ + > scl enable devtoolset-9 bash > ``` For the initial compilation, it is recommended to use the build script build.sh, which checks if the required software is available on the local machine. diff --git a/README_CN.md b/README_CN.md index 5dfbe62c69..d027571e84 100644 --- a/README_CN.md +++ b/README_CN.md @@ -109,7 +109,7 @@ Pika 力求在完全兼容 Redis 协议、 继承 Redis 便捷运维设计的前 * #### 2.2 依赖的库软件 - * gcc g++ 支持C++17 (version>=7) + * gcc g++ 支持C++17 (version>=9) * make * cmake(version>=3.18) * autoconf @@ -132,12 +132,12 @@ Pika 力求在完全兼容 Redis 协议、 继承 Redis 便捷运维设计的前 * 2.3.3. 执行编译 - > 如果在 CentOS6、CentOS7 等 gcc 版本小于 7 的机器上,需要先升级 gcc 版本,执行如下命令: + > 如果在 CentOS6、CentOS7 等 gcc 版本小于 9 的机器上,需要先升级 gcc 版本,执行如下命令: > > ```bash > sudo yum -y install centos-release-scl - > sudo yum -y install devtoolset-7-gcc devtoolset-7-gcc-c++ - > scl enable devtoolset-7 bash + > sudo yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++ + > scl enable devtoolset-9 bash > ``` 第一次编译时,建议使用构建脚本 `build.sh`,该脚本会检查本机上是否有编译所需的软件。