R
R
Ruslan Leviev2011-05-06 19:11:53
linux
Ruslan Leviev, 2011-05-06 19:11:53

Compiling PHP with PCRE extension?

There is a server based on Ubuntu 9.10. There are PHP 5.3.6 sorts. Task: Compile PHP with PCRE (I know you can install PHP via apt-get install, that's not the question).
Among the ./configure options for PHP is this:

--with-pcre-regex=DIR   Include Perl Compatible Regular Expressions support.
                          DIR is the PCRE install prefix [BUNDLED]

On the server, I already installed PCRE via the command:
apt-get install libpcre3 libpcre3-dev
As a result, the console responds to the whereis pcre command:
pcre: /usr/include/pcre.h /usr/share/man/man3/pcre.3.gz

Now it remains to specify "PCRE install prefix" when compiling PHP . What should I specify as this value in this case? Or should I still download the PCRE sources and specify the path to the sources as this value?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Maxim, 2011-05-06
@ruskar

in php 5 pcre is included in the sorts, php is built with pcre by default, no separate flags need to be specified for configure.

D
Dmitry, 2011-05-07
@mephisto

To answer a more general question:
This is usually /usr or /usr/local, depending on the OS.
For FreeBSD, /usr/local will be typical, for Debian - /usr
. this is a folder against which you can write /lib to get the libs folder, and/or /include to get the headers folder.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question