You want to build the Apache web server yourself from the sources directly (see Recipe 1.4), but don't know how to obtain them.
There are a number of ways to obtain the sources. You can access the latest version in close to real-time by using CVS, the tool used by the Apache developers for source control, you can download a release tarball, or you can install a source package prepared by a distributor, among others.
From a prepackaged tarball, download the tarball from http://httpd.apache.org/dist/, and then:
% tar xzvf apache_1.3.27.tar.gz
If your version of tar doesn't support the z option for processing zipped archives, use this command instead:
% gunzip -c < apache_1.3.27.tar.gz | tar xvf -
From the very latest up-to-the-minute Apache 1.3 source repository (not guaranteed to be completely functional), use:
% cvs -d :pserver:anoncvs@CVS.Apache.Org:/home/cvspublic login Password: anoncvs % cvs -d :pserver:anoncvs@CVS.Apache.Org:/home/cvspublic checkout apache-1.3
You can fetch a particular release version instead of the bleeding edge code if you know the name the developers gave it. For example, this will pull the sources of the 1.3.27 release, which is expected to be stable, unlike the up-to-the-minute version:
% cvs -d :pserver:anoncvs@CVS.Apache.Org:/home/cvspublic checkout -r APACHE_1_3_27 apache-1.3
From the very latest up-to-the-minute Apache 2.0 source repository (not guaranteed to be completely functional), use:
% cvs -d :pserver:anoncvs@CVS.Apache.Org:/home/cvspublic login Password: anoncvs % cvs -d :pserver:anoncvs@CVS.Apache.Org:/home/cvspublic checkout -r APACHE_2_0_BRANCH httpd-2.0 % cd httpd-2.0/srclib % cvs checkout apr apr-util
As with the method for the 1.3 version of the server, you can fetch a particular release of the 2.0 code if you know the name assigned to it in CVS.
You can find the names of the tags used in the source tree by visiting either http://cvs.apache.org/viewcvs.cgi/apache-1.3/ or http://cvs.apache.org/viewcvs.cgi/httpd-2.0/ and pulling down the Show files using tag list at the bottom of the page.
No matter how you install the source, the directory tree will be ready for configuration and building. Once the source is in place, you should be able to move directly to building the package (see Recipe 1.4).
If you chose to install the sources using the CVS method, you can keep your sources up-to-date by simply executing the following command from the top level of the source directory:
% cvs update -Pd
This will update or fetch any files that have been changed or added by the developers since the last time you downloaded or updated.
If you update to the latest version of the sources, you're getting whatever the developers are currently working on, which may be only partially finished. If you want reliability, stick with the released versions, which have been extensively tested.