CentOS installation Apache2.4 hint APR not found solution

Source: Internet
Author: User

There is no problem when installing the apache2.2.22 version, you can use the command to compile the installation directly.

However, in the Apache 2.4.12 version, when the./configure is configured,

Tips

Configure:error:APR not found. Please read the documentation.

(Configuration error: APR not found, please read related documents)

Description Apr not installed.

1. Download the required packages:

wget http://archive.apache.org/dist/apr/apr-1.4.5.tar.gz

wget http://archive.apache.org/dist/apr/apr-util-1.3.12.tar.gz

wget Http://jaist.dl.sourceforge.net/project/pcre/pcre/8.10/pcre-8.10.zip

The steps are as follows:

A: Solve Apr not found problem >>>>>>

[Email protected] test]# TAR-ZXF apr-1.4.5.tar.gz
[Email protected] test]# CD apr-1.4.5
[Email protected] apr-1.4.5]#/configure--PREFIX=/USR/LOCAL/APR
[[email protected] apr-1.4.5]# make && make install


B: Solve apr-util not found problem >>>>

[Email protected] test]# TAR-ZXF apr-util-1.3.12.tar.gz
[Email protected] test]# CD apr-util-1.3.12
[Email protected] apr-util-1.3.12]#/configure--prefix=/usr/local/apr-util--with-apr=/usr/local/apr
[[email protected] apr-util-1.3.12]# make && make install

C: Solve pcre problem >>>>>>>>>

[[email protected] test] #unzip-o pcre-8.10.zip
[[email protected] test] #cd pcre-8.10
[Email protected] pcre-8.10]#./configure--prefix=/usr/local/pcre
[[email protected] pcre-8.10] #make && make install (may appear g++: Command not Found,centos execution

YUM-Y Update gcc yum-y install gcc+ gcc-c++, after installation, perform the previous step./configure ... )


2. When you finally compile Apache, add:

--WITH-APR=/USR/LOCAL/APR \

--with-apr-util=/usr/local/apr-util/\

--with-pcre=/usr/local/pcre

./configure--prefix=/usr/local/apache2.4--with-apr=/usr/local/apr--with-apr-util=/usr/local/apr-util-- With-pcre=/usr/local/pcre


Successful compilation completed ~

CentOS Installation Apache2.4 tips for the APR not found workaround

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.