Nginx安装报错:
checking for PCRE library ... not found
checking for PCRE library in /usr/local/ ... not foundchecking for PCRE library in /usr/include/pcre/ ... not found
checking for PCRE library in /usr/pkg/ ... not found
checking for PCRE library in /opt/local/ ... not found
./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module by using --without-http_rewrite_module
option, or install the PCRE library into the system, or build the PCRE library
statically from the source with nginx by using --with-pcre=<path> option.
原因是PCRE包没有安装。
下载prce包:
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.32.tar.gz
安装nginx所需要的pcre-devel库,是为了是Nginx支持http Rewrite模块。
[root@xsunt94-pc ~]# tar zxf pcre-8.32.tar.gz
[root@xsunt94-pc ~]# cd pcre-8.32
[root@xsunt94-pc pcre-8.32]# ./configure
[root@xsunt94-pc pcre-8.32]# make && make install