I believe that you will encounter some problems when installing nginx. I encountered a problem during the experiment, that is, running
./Configure -- prefix =/usr/local/ngix -- conf-Path =/etc/ngix. conf,
./Configure: Error:The HTTP gzip module requires the zlib library.
You can either disable the module by using-without-http_gzip_module
Option, or install the zlib library into the system, or build the zlib
Library
Statically from the source with nginx by using-with-zlib = <path> Option
The red part shows you that zlib is missing, so you have to install zlib. I directly reported an error in the result of Yum install zlib. Why? devel contains a common package, only the header file is more than the normal package. If the dynamic link library is used, both packages are available. If you need to use this library during compilation, you need to install the devel of this library because the header file is required.
Yum install-y zlib-devel
Then the execution succeeds./configure -- prefix =/usr/local/ngix -- conf-Path =/etc/ngix. conf
Then you can complete the operation.
This article is from the "Linux" blog, please be sure to keep this source http://clarence.blog.51cto.com/8161461/1440225
A problem encountered during nginx Installation