安装apache 提示APR not found 解决方法

推荐方法,注意版本号。

1.下载apr安装包:

tar zxvf  apr-1.4.6.tar.gz

apr-1.4.6

./configure --prefix=/usr/local/apr

make && make install

2.下载apr-util安装包:

tar zxvf apr-util-1.4.1.tar.gz

cd apr-util-1.4.1

./configure --prefix=/usr/local/apr-util --with-apr=/usr/local/apr/bin/apr-1-config

3.下载pcre安装包:

pcre-8.30.zip

cd pcre-8.30

./configure --prefix=/usr/local/pcre

make && make install

4.安装包:

tar zxvf httpd-2.4.2.tar.gz

cd httpd-2.4.2

./configure --prefix=/usr/local/apache2 ---so --enable-re --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util --with-pcre=/usr/local/pcre/bin/pcre-config

make && make install