Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have been trying to get a Passenger and Nginx setup to work with php files but I am having problems with the PCRE regular expressions library. Install all went fine so I'm assuming it found the libraries at that point but now when I include a regex for PHP files in my nginx.conf file, I get the following error when trying to start the server:

nginx: [emerg] using regex "\.php$" requires PCRE library in /home/dev/nginx/conf/nginx.conf:59

I have installed packages with

apt-get install libpcre3 libpcre3-dev

and have installed PCRE 8.21 in usr/local/lib but nothing seems to be working. Is there a simple way to set the path to the library with Nginx or another solution? All problems relating to this seem to prevent Nginx from installing in the first place but succeed once the libraries are installed.

Would really appreciate any help!


share|improve this question

The problem occurs because pcre was not installed on your system before you compiled nginx. Now that you have it the proper libraries, you should be able to recompile the nginx and run with no pcre related errors.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .