Install Apache 2.4.41 from source

I dealt with Apache for the first time in my graduation work at a vocational school, so I will write a memorandum It's the first time I've touched even Ubuntu, so it seems that there are many missing points.

OS Ubuntu18.04LTS

Reference article

https://www7390uo.sakura.ne.jp/wordpress/archives/467 https://bty.sakura.ne.jp/wp/archives/149 https://www.skyarch.net/blog/?p=9543

Things necessary

  1. GCC (C compiler) 2.pcre-8.39 3.apr-1.7.0 4.apr-util-1.6.1 5.httpd-2.4.41

Install GCC

With the apt command $ apt-get install build-essential

Compile and install

Download the above to / usr / local / src and unzip

When downloading $ wget (url)

Decompression $ tar zxvf (file name)

After unzipping, enter each directory

$ ./configure


 $ make || make install```

 I will continue to execute.

# Attention 1
 I was told that there was not enough library called expat.h
 [Here](https://github.com/libexpat/libexpat/releases/download/R_2_2_7/expat-2.2.7.tar.gz)
 Download from. You should be able to install this one.
# Note 2
 Optional when running apr-util ./configure


#### **`$ ./configure --with-apr=/usr/local/apr`**

I'll attach

Note 3

httpd-2.4.41 ./configure is also optional

$./configure --with-pcre=/usr/local/src/pcre-8.39/pcre-config --with-apr=/usr/local/src/apr-1.7.0 --with-apr-util=/usr/local/src/apr-util-1.6.1



 I'll attach
# Note 4
 After installation, when I tried to start it, I got a message saying that I should pass the library path, so

```$ export ld_library_path="/usr/local/lib"```

 Now you can do it.


Recommended Posts

Install Apache 2.4.41 from source
Install Apache Maven (from source)
Install python from source
Install ansible from source code
Install Python from source with Ansible
Compile and install Git from source.
Install from conda-forge
Install Apache Zookeeper
Install Apache Zeppelin
Install Apache ActiveMQ
Install PostgreSQL from source code on CentOS
Install the latest version of Apache httpd 2.4 from source on Cent OS 8
Build PostgreSQL from source
Install vim7.3 (+ python2.4) from source (compatible with Gundo.vim)
Install pyenv from Homebrew, install Python from pyenv
pip install prevents proxy from installing
Flow from source code to creating executable
How to install Apache (httpd) on CentOS7
How to install Apache (httpd) on CentOS8