% cd ./apache-1.3 % env CC=gcc CFLAGS="-O2 -Wall" > ./configure --enable-shared=max --enable-module=most > --with-layout=Apache --prefix=/usr/local/web/apache > --with-port=80 Configuring for Apache, Version 1.3.13-dev + using installation path layout: Apache (config.layout) Creating Makefile Creating Configuration.apaci in src [more configuration output] % make [lots of compilation output] % /usr/local/web/apache/bin/apachectl start % make install [lots of output describing file placement]
|
If you didn’t encounter any errors, you should now have a
working Apache installation in the location that matches the
assumptions described earlier.
It’s been built to work with dynamic modules rather than
static ones for maximum flexibility. The next step is to
start the server.
[Re]Building Apache on Windows
Unfortunately, this is a pretty esoteric area. Almost every flavour of
Unix in the world comes with the tools necessary to turn source code into
something you can run; but the same is not true of Windows. All development
packages on the Windows platforms are add-ons, and there are a few
possibilities. When the Apache developers began working on the Windows
version of Apache, they decided to standardise on a single add-on
development tool: Visual Studio C++ version 5.0 from Microsoft.
So if you don’t have a Windows development package, you can’t rebuild
the Apache software. If you have a different one than Visual Studio,
how to get it to work with the Apache sources is a problem you’ll
have to solve yourself.
If, however, you have Visual C++ on your Windows box, then you
can rebuild the Apache Web server from source either from a command
line in a DOS window, such as:
C:>cd "Program FilesApache GroupApachesrc" C:Program FilesApache GroupAPACHEsrc>nmake -f Makefile.nt target
The target can be one of the following:
installr
- Build a fully-functional
Apache.exe
executable. installd
- Same as
installr
, except that the executable
is built for use with a debugger. _cleanr
- Clean up the directory tree in preparation for doing a
installr
build. _cleand
- Clean up the directory tree in preparation for doing a
installd
build.