<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=CompilingApache</id>
	<title>CompilingApache - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=CompilingApache"/>
	<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=CompilingApache&amp;action=history"/>
	<updated>2026-08-21T21:46:47Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.1</generator>
	<entry>
		<id>https://rt-wiki.bestpractical.com/index.php?title=CompilingApache&amp;diff=547&amp;oldid=prev</id>
		<title>Admin: 2 revisions imported</title>
		<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=CompilingApache&amp;diff=547&amp;oldid=prev"/>
		<updated>2016-04-06T20:03:26Z</updated>

		<summary type="html">&lt;p&gt;2 revisions imported&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= Introduction =&lt;br /&gt;
&lt;br /&gt;
These days &amp;#039;&amp;#039;&amp;#039;people usually don&amp;#039;t compile apache&amp;#039;&amp;#039;&amp;#039;, so below are historical notes.&lt;br /&gt;
&lt;br /&gt;
= Compiling Apache 1.x with mod_perl =&lt;br /&gt;
&lt;br /&gt;
The mod_perl1 guide can be found at: http://perl.apache.org/docs/1.0/guide/&lt;br /&gt;
&lt;br /&gt;
The following is an excerpt, which should work for most people. Download the source tarballs for apache and for mod_perl, and then:&lt;br /&gt;
&lt;br /&gt;
 % tar xzvf apache_x.x.x.tar.gz&lt;br /&gt;
 % tar xzvf mod_perl-x.xx.tar.gz&lt;br /&gt;
 % cd mod_perl-x.xx&lt;br /&gt;
 % perl Makefile.PL \&lt;br /&gt;
 %    APACHE_SRC=../apache_x.x.x/src \&lt;br /&gt;
 %    USE_APACI=1 \&lt;br /&gt;
 %    DO_HTTPD=1 \&lt;br /&gt;
 %    EVERYTHING=1&lt;br /&gt;
 % make &amp;amp;amp;&amp;amp;amp; make test &amp;amp;amp;&amp;amp;amp; make install&lt;br /&gt;
 % cd ../apache_x.x.x&lt;br /&gt;
 % make install&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
This builds Apache statically with mod_perl, installs Apache under the default /usr/local/apache tree and mod_perl into the site_perl hierarchy of your existing Perl installation.&lt;br /&gt;
&lt;br /&gt;
Do not omit the EVERYTHING=1 parameter.&lt;br /&gt;
&lt;br /&gt;
== Another variant from RuslanZakirov ==&lt;br /&gt;
&lt;br /&gt;
I use this variant for ages and I don&amp;#039;t have any problems, like seg faults or mod_perl1/mod_php/mod_ssl/libexpat compatibilities. This method allow compile other third party modules that support APACI (mod_php for example, but you &amp;#039;&amp;#039;&amp;#039;shouldn&amp;#039;t&amp;#039;&amp;#039;&amp;#039; compile mod_php as DSO if mod_perl is not a DSO module).&lt;br /&gt;
&lt;br /&gt;
This variant as well allows you to execute apache&amp;#039;s &amp;lt;code&amp;gt;./configure&amp;lt;/code&amp;gt; script and change default properties.&lt;br /&gt;
&lt;br /&gt;
* Get sources&lt;br /&gt;
&lt;br /&gt;
 % tar -xzvf apache_1.3.xx.tar.gz&lt;br /&gt;
 % tar -xzvf mod_perl-1.xx.tar.gz&lt;br /&gt;
 % cd mod_perl-1.xx&lt;br /&gt;
&lt;br /&gt;
* Configure mod_perl and say it use APACI and don&amp;#039;t build httpd&lt;br /&gt;
&lt;br /&gt;
 % perl Makefile.PL \&lt;br /&gt;
 %    APACHE_SRC=../apache_1.3.xx/src \&lt;br /&gt;
 %    USE_APACI=1 \&lt;br /&gt;
 %    NO_HTTPD=1 \&lt;br /&gt;
 %    PREP_HTTPD=1 \&lt;br /&gt;
 %    EVERYTHING=1&lt;br /&gt;
&lt;br /&gt;
* this would move source to &amp;lt;code&amp;gt;apache_1.3.xx/src&amp;lt;/code&amp;gt; and prepare it for apache compile process&lt;br /&gt;
&lt;br /&gt;
 % make&lt;br /&gt;
&lt;br /&gt;
* here you can prepare other third party modules, but be aware some modules require &amp;lt;code&amp;gt;make install&amp;lt;/code&amp;gt; too, because they don&amp;#039;t move required files into &amp;lt;code&amp;gt;apache_1.3.xx/src&amp;lt;/code&amp;gt; dir when you run &amp;lt;code&amp;gt;make&amp;lt;/code&amp;gt;. Such crappy module is mod_php :)&lt;br /&gt;
&lt;br /&gt;
 % cd other modules dir and prepare it&lt;br /&gt;
 % ...&lt;br /&gt;
&lt;br /&gt;
* when you prepared all required modules, go to apache source dir&lt;br /&gt;
&lt;br /&gt;
 % cd ../apache_x.x.x&lt;br /&gt;
&lt;br /&gt;
* now you should configure apache and activate modules.&lt;br /&gt;
&lt;br /&gt;
 % ./configure \&lt;br /&gt;
&lt;br /&gt;
* I use default apache prefix (apache layout) because I don&amp;#039;t want to mix it with distro&amp;#039;s server, but you can change it&lt;br /&gt;
&lt;br /&gt;
 %   --prefix=/usr/local/apache \&lt;br /&gt;
&lt;br /&gt;
* you should activate mod_perl and other mods&lt;br /&gt;
&lt;br /&gt;
 %   --activate-module=src/modules/perl/libperl.a \&lt;br /&gt;
&lt;br /&gt;
* now small trick for those who has libexpat in system and wish to use any perl XML module which depends on libxml. In most cases people have libexpat.&lt;br /&gt;
&lt;br /&gt;
 %   --disable-rule=EXPAT \&lt;br /&gt;
&lt;br /&gt;
* now all other configure options if you wish&lt;br /&gt;
&lt;br /&gt;
 %   ...&lt;br /&gt;
&lt;br /&gt;
* compile apache&lt;br /&gt;
&lt;br /&gt;
 % make&lt;br /&gt;
&lt;br /&gt;
* return back to mod_perl, because you wish to run tests against this new build. you should do it before you&amp;#039;ll install apache or mod_perl and overwrite your current well-running server with new, but broken(may be)&lt;br /&gt;
&lt;br /&gt;
 % cd ../mod_perl-1.xx&lt;br /&gt;
 % make test&lt;br /&gt;
&lt;br /&gt;
* now you can install it if all tests are ok&lt;br /&gt;
&lt;br /&gt;
 % make install&lt;br /&gt;
 % cd ../apache_1.3.xx&lt;br /&gt;
 % make install&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Edit default httpd.conf and enjoy your new Apache+mod_perl+what_ever_you_want build.&lt;br /&gt;
&lt;br /&gt;
== Compiling Apache with Mod Perl statically, but allow other modules as DSO ==&lt;br /&gt;
&lt;br /&gt;
If you wish to compile mod_perl with apache statically, but want to have apache open to use dynamic modules later, then add &amp;lt;code&amp;gt;--enable-module=so&amp;lt;/code&amp;gt; option when run configure script of apache:&lt;br /&gt;
&lt;br /&gt;
 % ./configure \&lt;br /&gt;
 %   --prefix=/usr/local/apache \&lt;br /&gt;
 %   --activate-module=src/modules/perl/libperl.a \&lt;br /&gt;
 %   --disable-rule=EXPAT \&lt;br /&gt;
 %   --enable-module=so \&lt;br /&gt;
 %   ...&lt;br /&gt;
&lt;br /&gt;
= See also =&lt;br /&gt;
&lt;br /&gt;
See also: notes about mod_perl in [[CompilingPerl]] and in [[ManualRequirements]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>