Senthil Kumaran
Senthil Kumaran

Reputation: 56951

How to compile apache/httpd on Linux?

I am trying to compile https://github.com/apache/httpd on Linux.

  1. It does not have ./configure script in the repo.
  2. It does not have ./autoconf script in the repo.
  3. Nor does it have a Makefile (default) for make.

I couldn't information in the README or INSTALL file in the repo to compile from source.

How do I compile https://github.com/apache/httpd on Linux?

Upvotes: 1

Views: 726

Answers (2)

Example person
Example person

Reputation: 3346

First:

./buildconf

As Senthil Kumaran answered his question, you can add --with-apr=/path/to/apr --with-apr-util=/path/to/apr-util

Then do the rest.

See https://httpd.apache.org/docs/2.4/programs/configure.html

A little tutorial to do the rest:

Usually needs libssl, libnghttp2, libexpat, libpcre, apr, apr-util

./configure --prefix=/path/to/install/apache --enable-mpms-shared=all --enable-mods-shared=reallyall

Then:

make && make install

From next time, to use the same configuration:

make clean && ./config.nice && make && make install

Upvotes: 1

Senthil Kumaran
Senthil Kumaran

Reputation: 56951

I was running into an error, APR not installed when I tried ./buildconf

The following steps worked.

  1. Download apr source from Apache website
  2. Download apr-util source from Apache website.

./buildconf --with-apr=/home/senthil/Downloads/apr-1.7.0/ --with-apr-util=/home/senthil/Downloads/apr-util-1.6.1

./configure

make

Upvotes: 0

Related Questions