Skip to main content

[Solved] Nginx - error: HTTP rewrite module requires the PCRE library

Nginx $ ./configure: error: the HTTP rewrite module requires the PCRE library. While trying to install Nginx server using the source distribution, "./configure" command failed on CentOS 6.7 with below error message. It complains that PCRE library is not available on the system.

./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.

Solution

You can install this library either via command line or GUI.

Resolve via Command line

yum install pcre-devel

Resolve via GUI

Go to "System" -> "Administration" -> "Add/Remove Software" as shown below.

Then search for "pcre-devel", select "Development files for pcre" and install by clicking "Apply" as shown below.
After that, you can rerun the "./configure" command to continue installing Nginx 1.12.1 server.
Hope this helps.

Related Articles

Comments

Popular posts from this blog

Web Services with Apache Axis 1.4 Tutorial: server and client sides

Java Sorting: Comparator vs Comparable Tutorial

Creative Commons License Digizol by Kamal Mettananda is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License .
URL of this page must be supplied in attribution
© 2004-2017