若未安装GCC,后续安装Nginx时会报如下错误:
./configure: error: C compiler cc isnot found
若未安装GCC-C++,后续安装PCRE库时会报如下错误:
configure: error: You need a C++ compiler for C++ support.
PCRE library
[root@jdu4e00u53f7 centos]# wget https://ftp.pcre.org/pub/pcre/pcre-8.41.tar.gz
[root@jdu4e00u53f7 centos]# tar -zxf pcre-8.41.tar.gz
[root@jdu4e00u53f7 centos]# cd pcre-8.41
[root@jdu4e00u53f7 pcre-8.41]# ./configure
[root@jdu4e00u53f7 pcre-8.41]# make
[root@jdu4e00u53f7 pcre-8.41]# make install
可在 [https://ftp.pcre.org/pub/pcre/](https://ftp.pcre.org/pub/pcre/) 查看最新版本。
若未安装PCRE库,后续安装Nginx时会报以下错误:
./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module byusing--without-http_rewrite_module
option, or install the PCRE library intothesystem, or build the PCRE library
statically fromthe source with nginx byusing--with-pcre=<path> option.
ZLIB Library
[root@jdu4e00u53f7 centos]# wget http://www.zlib.net/zlib-1.2.11.tar.gz
[root@jdu4e00u53f7 centos]# tar -zxf zlib-1.2.11.tar.gz
[root@jdu4e00u53f7 centos]# cd zlib-1.2.11
[root@jdu4e00u53f7 zlib-1.2.11]# ./configure
[root@jdu4e00u53f7 zlib-1.2.11]# make
[root@jdu4e00u53f7 zlib-1.2.11]# make install
可在 [http://www.zlib.net/](http://www.zlib.net/) 查看最新版本。
若未安装ZLIB库,后续安装Nginx时会报以下错误:
./configure: error: the HTTP gzip module requires the zlib library.
You can either disable the module byusing--without-http_gzip_module
option, or install the zlib library intothesystem, or build the zlib library
statically fromthe source with nginx byusing--with-zlib=<path> option.
Nginx
[root@jdu4e00u53f7 centos]# wget http://nginx.org/download/nginx-1.13.4.tar.gz
[root@jdu4e00u53f7 centos]# tar -zxf nginx-1.13.4.tar.gz
[root@jdu4e00u53f7 centos]# cd nginx-1.13.4
[root@jdu4e00u53f7 nginx-1.13.4]# ./configure
[root@jdu4e00u53f7 nginx-1.13.4]# make
[root@jdu4e00u53f7 nginx-1.13.4]# make install
GCC & GCC-C++[root@jdu4e00u53f7 ~]# yum install gcc[root@jdu4e00u53f7 ~]# yum install gcc-c++若未安装GCC,后续安装Nginx时会报如下错误:./configure: error: C compiler cc is not found若未安装GCC-C++,后续安装PCRE库时会报如下错误:conf