install and compile particular apache in ubuntu

Due to testing purpose, I need a specific Apache version. So I bring up a ubuntu docker and play around with it.

In my case, I need Apache 2.4.23 version.

Archive version you can access to https://archive.apache.org/dist/httpd/

Just in case, if your linux does not have wget, you can install via apt-get install wget

Follow the below script to compile your apache version

cd ~
wget https://archive.apache.org/dist/httpd/httpd-2.4.23.tar.gz
tar -zxf httpd-2.4.23.tar.gz

wget http://www-eu.apache.org/dist//apr/apr-1.6.2.tar.gz
wget http://www-eu.apache.org/dist//apr/apr-util-1.6.0.tar.gz
tar -zxf apr-1.6.2.tar.gz
tar -zxf apr-util-1.6.0.tar.gz

cd httpd-2.4.23/srclib/
cp ~/apr-1.6.2 ./apr
cp ~/apr-util-1.6.0 ./apr-util

apt-get install build-essential

apt-get install libpcre3 libpcre3-dev libexpat1-dev 

./configure

 

For install detail, you can read from here.

http://httpd.apache.org/docs/2.4/install.html

Once you have run the above command, you should able to make and make install

That’s all!

 

Leave a Reply

Your email address will not be published. Required fields are marked *