rse 98/03/29 04:27:38
Modified: . STATUS CHANGES
src CHANGES .cvsignore
htdocs/manual new_features_1_3.html upgrading_to_1_3.html
Added: . .cvsignore README.configure INSTALL configure
Makefile.tmpl
src/helpers fmn.sh install.sh mkdir.sh mkshadow.sh ppl.sh
Removed: . Makefile
src/helpers InstallApache
Log:
Ok, its time to replace the bogus {Makefile,src/install/InstallApache} stuff
with the new Apache Autoconf-style Interface (APACI) while adjusting some
documentation and CVS files for it.
APACI was already tested by me under the following platforms:
FreeBSD 2.1.5-RELEASE [en1] +DSO
FreeBSD 2.2.2-RELEASE [taz] +DSO
FreeBSD 2.2.5-RELEASE [en4] +DSO
Solaris 2.5.1 [sunti5] +DSO
Solaris 2.6 [en5] +DSO
SunOS 4.1.3 [sunbi1] +DSO
Linux 2.0.33 / Deb131 [gw1] +DSO
Linux 2.0.33 / RH4.1 [rcs41] +DSO
DEC OSF/1 4.0 [rcs12] +DSO
IRIX 6.2 [sgihalle14] -
HPUX 10.20 [rcs31] -
AIX 4.2 [rcs7] -
with the test procedure command
$ ./configure --prefix=/tmp/apache --enable-module=most
[--enable-shared=max]
$ make
$ make install
$ vi /tmp/apache/etc/httpd.conf
[edit Port 80->8000]
$ /tmp/apache/sbin/apachectl start
$ lynx -source http://localhost:8000/
$ /tmp/apache/sbin/apachectl stop
We should test more in the next days before 1.3b6 will go out. Let us hope
that our users now really honor my hacking and the groups decision effort for
APACI. Puuhhhhhhh.... ;-)
Revision Changes Path
1.235 +1 -175 apache-1.3/STATUS
Index: STATUS
===================================================================
RCS file: /export/home/cvs/apache-1.3/STATUS,v
retrieving revision 1.234
retrieving revision 1.235
diff -u -r1.234 -r1.235
--- STATUS 1998/03/29 10:10:05 1.234
+++ STATUS 1998/03/29 12:27:26 1.235
@@ -125,6 +125,7 @@
* Jim's fix for IRIX which needs the -n32 flag iff using 'cc', PR#1901
* Jim's add of the SCO_SV port. PR#1962
* Dean's floating point ap_snprintf code wasn't threadsafe.
+ * Ralf's add of the new Apache Autoconf-style Interface (APACI)
Available Patches:
@@ -132,181 +133,6 @@
nature of usage of the name "Apache" in derived products
Status: Ken +1, Paul +1, Ben +1, Jim +1, Randy +1, Roy +1,
Chuck +1, MarkC +1, Ralf +1, Sameer +1, Martin +1, Dean +1
-
- * Ralf's
- Apache 1.3 Autoconf-*style* Interface (APACI)
- ftp://ftp.apache.org/apache/dist/contrib/apaci/
-
- What stuff does APACI contain?
- README Documentation with Examples (step 1)
- INSTALL Reference of Installation Options (step 2)
- configure The Autoconf-style configure script (step 3)
- Makefile.tmpl The Makefile controlling anything (step 4)
- aux/fmn.sh Auxilliary script: find module name
- aux/install.sh Auxilliary script: install program
- aux/mkdir.sh Auxilliary script: mkdir program
- aux/mkshadow.sh Auxilliary script: --shadow support
- aux/ppl.sh Auxilliary script: --help support
-
- Background:
- Currently Apache 1.3 has no real and flexible batch-configuration
- procedure and no real out-of-the-box installation procedure although
- the users expect one. At least the installation procedure is
required.
- For Apache 2.0 we already want something similar to this, but this is
- too far away. Apache 1.3 will be out for a long time until Apache 2.0
- is available and thus we should provide such a installation
procedure.
-
- Idee:
- To fill this gap for Apache 1.3 APACI was written from scratch. The
- goal it addresses is an Autoconf-style(!) but _NOT_ Autoconf-based
- batch interface for out-of-the-box configuring, building and
- installing Apache 1.3 by providing a frontend(!) and _NOT_ a
- replacement to the (more proprietary) src/Configure+src/Configuration
- stuff while replacing the totally out-of-date and bogus
- apache-1.3/Makefile+apache-1.3/src/helpers/InstallApache files.
-
- In short for the impatient:
- $ cd apache-1.3
- $ ./configure --prefix=PREFIX
- $ make
- $ make install
- $ PREFIX/sbin/apachectl start <<<<====== IMPORTANT!
-
- Hints:
- 1. Because APACI uses a frontend which is named "configure" and
- supports the Autoconf-style options (especially --prefix, etc.)
we
- provide an interface the users expect and already know for years
- from the many GNU software packages. The fact that our APACI
stuff
- is not really Autoconf-based(!) is not important here and totally
- hidden from the user.
- 2. The "make install" _really_ out-of-the-box installs Apache 1.3
- without any user intervention. It does not only install Apache
- with a GNU-conforming (and thus not filesystem disturbing)
- installation layout. It additionally creates initial config
files,
- including corresponding LoadModule lines for the built shared
- objects, etc. And it installs not only the core, it installs the
- shared objects files, the support programs, the manpages, the
- initial document root, etc. pp.
- 3. Because APACI also adjusts the paths in the support scripts and
- programs the user is able to _IMMEDIATELY_ fire up Apache after
- "make install" by just running "PREFIX/sbin/apachectl start".
- THIS IS VERY IMPORTANT, because it gives the first success event
- to the user. For a really good package the should love this is
- important.
-
- The features APACI actually provides in detail (summary):
- - runs 100% in batch
- - can control _any_ options of src/Configuration.tmpl file,
including
- rules, shared object support, etc.
- - provides additional support for suEXEC, on-the-fly adding of
- modules, mod_perl, etc.
- - builds _and_ installs Apache out-of-the-box
- - user can _immediately_ run Apache the first time after "make
- install". Important for the first success even of the user!!
- - is as portable as src/Configure (no shell functions, etc.)
- - is well documented (README, INSTALL files plus comments)
- - supports both GNU-conforming installation layout and proprietary
- Apache installation layout (--compat)
- - no license conflicts because written from scratch
-
- Now for the inclusion of APACI you should remember:
- - The inclusion of APACI does _not_ change _anything_.
- - We can only gain from providing such an interface because our
- current top-level Makefile and src/helpers/InstallApache stuff is
- nothing more than a bad joke.
- - It only has one disadvantage for us: we are late in the release
- cycle and perhaps it causes a few new PRs in the future. But the
- advantage of having it should be more important. Because APACI
- is not what we developers want, it is what the users want!
- Don't forget this, please.
-
- We have two obvious ways for APACI to be comitted (each with its own
- advantage and disadvantage):
-
- CV1: The recommended-way commit:
-
- README apache-1.3/README.configure
- INSTALL apache-1.3/INSTALL
- configure apache-1.3/configure
- Makefile.tmpl apache-1.3/Makefile.tmpl
- aux/fmn.sh ==> apache-1.3/src/helpers/fmn.sh
- aux/install.sh apache-1.3/src/helpers/install.sh
- aux/mkdir.sh apache-1.3/src/helpers/mkdir.sh
- aux/mkshadow.sh apache-1.3/src/helpers/mkshadow.sh
- aux/ppl.sh apache-1.3/src/helpers/ppl.sh
-
- Advantages: - the user finds APACI easily because it stays
- where it is expected to stay: in the top-level
- - we show that its the official all-in-one interface
- for Joe Avarage and just have to add some hints to
- the INSTALL and README files on how to do a
- custom build the old way in src/.
- - the "make" process looks clear and obvious by
- displaying "==> src/xxxx" etc.
- Disadvantages: - we bristle the source tree a little bit
- with the APACI files
-
- CV2: The closed-area commit:
-
- README apache-1.3/apaci/README
- INSTALL apache-1.3/apaci/INSTALL
- configure apache-1.3/apaci/configure
- Makefile.tmpl apache-1.3/apaci/Makefile.tmpl
- aux/fmn.sh ==> apache-1.3/apaci/aux/fmn.sh
- aux/install.sh apache-1.3/apaci/aux/install.sh
- aux/mkdir.sh apache-1.3/apaci/aux/mkdir.sh
- aux/mkshadow.sh apache-1.3/apaci/aux/mkshadow.sh
- aux/ppl.sh apache-1.3/apaci/aux/ppl.sh
-
- Advantages: - we no not bristle the source tree with APACI files
- - we mark APACI as an alternative/official interface
- Disadvantages: - the user doesn't find APACI easily because
- "configure" is _ALWAYS_ searched at the top-level by
- the user.
- - the user is confused and thinks APACI is totally
- inofficial and thus doesn't use it (acceptance!)
- - the "make" process looks a little bit ugly because
- it then displays "==> ../src/xxxx" etc..
-
- To now give a fair voting, either try APACI out by grabbing the
- distribution from ftp://ftp.apache.org/apache/dist/contrib/apaci/ or at
- least reading the examples in
- ftp://ftp.apache.org/apache/dist/contrib/apaci/README. You have time,
- don't hurry.
-
- PLEASE DO NOT QUICKLY VETO IT NOW JUST BECAUSE IT'S SUCH LATE IN THE
- RELEASE CYCLE. Please be really fair and decide if it is worth or not
- worth adding it by weighting on the advantages and disadvantages.
-
- Votes for including APACI (in general):
- Ralf +1, Dean +1, Roy +1, Paul +1, Martin +1, Jim +1, Chuck +0,
- Randy +0
-
- Votes for commit variants:
- CV1: Ralf +1, Dean +1, Roy +1, Paul +1, Martin +1 Jim +1, Chuck +0,
- Randy +0
- CV2: Ralf +0
-
- Notes:
- Randy: Given the amount of work that Ralf has clearly done on this,
- I would not veto it. However, I don't think this is something
- that should go in for 1.3.0 general and I don't feel that the
- current system is lacking enough that it needs replacing.
- We're asking for trouble.
- Chuck: What the heck. We're not releasing soon anymore. Let users
- get used to it if there's time.
- Jim: [the +1] iff we remove the "present" top-level build
- capability AND we clearly document the changes. Also,
- I agree with Randy that the amount of work that Ralf
- put into it kind of forces our hand... I don't want
- this to start a precedent and it _was_ one of the
- major discussion points on the "Ideas get discussed"
- first issue with c-t-r...
- Ralf: Sure, top-level Makefile+src/helpers/InstallApache is removed
- and the current top-level README file is extended by
- documenting APACI and the manual build-only approach with
- src/Configure. Just comitting APACI files will not be done.
- The existing README has to be adjusted. I'll do this.
In progress:
1.17 +12 -0 apache-1.3/CHANGES
Index: CHANGES
===================================================================
RCS file: /export/home/cvs/apache-1.3/CHANGES,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- CHANGES 1998/01/13 23:10:52 1.16
+++ CHANGES 1998/03/29 12:27:27 1.17
@@ -120,3 +120,15 @@
of serving either "binary-ASCII" or EBCDIC coded HTML text
documents. See the file README.EBCDIC in the src directory;
it also explains which modules still need porting (most are ready).
+
+ *) Apache Autoconf-style Interface (APACI)
+ Until Apache 1.3 there was no real out-of-the-box batch-capable build
+ and installation procedure for the complete Apache package. This is
now
+ provided by a top-level "configure" script and a corresponding
+ top-level "Makefile.tmpl" file. The goal is to provide a GNU
+ Autoconf-style frontend which is capable to both drive the old
+ src/Configure stuff in batch and additionally installs the package
+ with a GNU-conforming directory layout. Any options from the old
+ configuration scheme are available plus a lot of new options for
+ flexibly customizing Apache.
+
1.1 apache-1.3/.cvsignore
Index: .cvsignore
===================================================================
Makefile
1.1 apache-1.3/README.configure
Index: README.configure
===================================================================
A P A C H E C O N F I G U R A T I O N
Apache 1.3 Autoconf-style Interface (APACI)
===========================================
APACI is an Autoconf-style interface for the Unix side of the Apache 1.3
HTTP server source distribution. It is actually not GNU Autoconf-based, i.e.
the GNU Autoconf package itself is not used. Instead APACI just provides a
similar batch configuration interface and a corresponding out-of-the-box
build and installation procedure.
The basic goal is to provide the following commonly known and expected
procedure for out-of-the-box building and installing a package like Apache:
$ gunzip <apache-1.3.0.tar.gz | tar xvf -
$ ./configure --prefix=PREFIX [...]
$ make
$ make install
After these steps Apache 1.3 is completely installed under PREFIX and
already initially configured, so you can immediately fire it up the first
time via
$ PREFIX/sbin/apachectl start
to get your first success event with the Apache HTTP server without having
to fiddle around with various options for a long time. On the other hand
APACI provides a lot of options to adjust the build and installation process
for flexibly customizing your Apache installation. So, APACI provides both:
Out-of-the-box building and installation for the impatient and powerful
custom configuration for the experts.
Detailed Description
====================
For a detailed description of all available APACI options please read the
file INSTALL or at least run the command
$ ./configure --help
for a compact one-page summary of the possibilities you have. Additionally
you can let you be motivated by the following examples.
Examples
========
In the following typical or even interesting variants of the available
configuration steps are shown to give you an impression what APACI is good
for and what APACI can do for you to be able to install Apache without much
pain.
Standard installation
---------------------
The standard installation is done via
$ ./configure --prefix=/path/to/apache
$ make
$ make install
This builds Apache 1.3 with the standard set of enabled modules
(automatically determined from src/Configuration.tmpl) with a GNU-conforming
subdirectory layout under /path/to/apache. For using the old Apache 1.2
subdirectory layout additionally use the --compat option:
$ ./configure --compat --prefix=/path/to/apache
$ make
$ make install
If you are not sure which directory layout you want, you can use the
--layout option. It displays the directory layout which would be used but
immediately exits without configuring anything. Examples:
$ ./configure --layout
$ ./configure --prefix=/path/to/apache --layout
$ ./configure --compat --prefix=/path/to/apache --layout
Additionally if some of the shown paths still don't fit for your particular
situation, you can use the --bindir, --sbindir, --libexecdir, --mandir,
--sysconfdir, --datadir and --localstatedir options to adjust the layout as
required. Always check with --layout the resulting directory layout which
would be used for installation.
suEXEC support
--------------
The suEXEC feature of Apache provides a mechanism to run CGI and SSI
programs under the user and group id of the owner of the program. It is
neither installed nor configured per default for Apache 1.3, but APACI
supports it with additional options:
$ ./configure --prefix=/path/to/apache \
--enable-suexec \
--suexec-caller=www \
--suexec-userdir=.www
$ make
$ make install
This automatically builds and installs Apache 1.3 with suEXEC support for
the caller uid "www" and the user's homedir subdirs ".www". The access
paths for the suexec program are automatically adjusted and the suexec
program is installed, so Apache can find it on startup.
Building multiple platforms in parallel
---------------------------------------
When you want to compile Apache for multiple platforms in parallel it is
useful to share the source tree (usually via NFS, AFS or DFS) but build the
object files in separated subtrees. This can be accomplished by letting
APACI create a source shadow tree and build there:
$ ./configure --shadow --prefix=/path/to/apache
$ make
$ make install
Then APACI first determines the GNU platform triple, creates a shadow tree
in src.<gnu-triple> plus corresponding Makefile.<gnu-triple> and then
performs the complete build process with this shadow tree.
Dynamic Shared Object (DSO) support
-----------------------------------
Apache 1.3 supports building modules as shared objects on all major
platforms like FreeBSD, Linux, SunOS, Solaris, IRIX, OSF/1 and UnixWare.
APACI has a nice way of enabling the building of these shared objects and
automatically installing them:
$ ./configure --prefix=/path/to/apache \
--enable-module=rewrite \
--enable-shared=rewrite
$ make
$ make install
This builds and installs Apache with the default configuration except that
it adds the mod_rewrite module and automatically builds and installs it as a
shared object, so it is optionally available for loading under runtime. To
make your live even more easy APACI additionally inserts a corresponding
(but out-commented) `LoadModule' line in the httpd.conf file in the
installation phase. Just uncomment this line and you have mod_rewrite
available.
APACI also supports a variant of the --enable-shared option:
$ ./configure --prefix=/path/to/apache \
--enable-shared=max
$ make
$ make install
This enables shared object building for the maximum of modules, i.e. all
enabled modules (--enable-module or the default set) except for mod_so
itself (the bootstrapping module for shared object support). So, to build a
full-powered Apache with maximum flexibility by building and installing most
of the modules, you can use:
$ ./configure --prefix=/path/to/apache \
--enable-modules=most \
--enable-shared=max
$ make
$ make install
This first enables most of the modules (all modules except some problematic
ones like mod_auth_db which needs third party libraries not available on
every platform or mod_log_agent and mod_log_referer which are deprecated)
and then enables shared object support for all of them. This way you get all
these modules installed and you then can configure under runtime (via the
`LoadModule') directives which ones are actually used. Especially a very
useful for vendor package maintainers to provide a flexible Apache package.
On-the-fly added additional/private module
------------------------------------------
For Apache there are a lot of modules flying around on the net which solve
particular problems. For a good reference see the Apache Module Registory at
http://www.covalent.net/module_registry/ and the Apache Group's contribution
directory at http://www.apache.org/dist/contrib/modules/. These modules
usually come in a file named mod_foo.c. APACI supports adding these sources
on-the-fly to the build process:
$ ./configure --prefix=/path/to/apache \
--add-module=/path/to/mod_foo.c
$ make
$ make install
This automatically copies mod_foo.c to src/modules/extra/, activates it in
the configuration and builds Apache with it. A very useful way is to combine
this with the shared object support:
$ ./configure --prefix=/path/to/apache \
--add-module=/path/to/mod_foo.c \
--enable-shared=foo
$ make
$ make install
This builds and installs Apache with the default set of modules, but
additionally builds mod_foo as a shared object and adds a `LoadModule' line
to the httpd.conf file, so later you can enable this mod_foo under runtime.
Apache and mod_perl
-------------------
The Apache/Perl integration project (http://perl.apache.org/) from Doug
MacEachern <[EMAIL PROTECTED]> is a very powerful approach to integrate
a Perl 5 interpreter into the Apache HTTP server both for running Perl
programs and for programming Apache modules in Perl. The distribution
mod_perl-1.XX.tar.gz can be found on http://perl.apache.org/src/. Here is
how you can install Apache with mod_perl:
$ cd mod_perl-1.XX
$ perl Makefile.PL
ReadLine support enabled
Configure mod_perl with ../apache-1.3/src ? [y] y
Shall I build httpd in ../apache-1.3/src for you? [y] y
:
$ cd ../apache-1.3
$ LIBS='`perl $(SRCDIR)/modules/perl/ldopts`' \
./configure --prefix=/path/to/apache \
--activate-module=src/modules/perl/libperl.a
$ make
$ make install
This automatically builds and installs Apache 1.3 with mod_perl. After
additionally installing the Perl side of mod_perl via
$ cd ../mod_perl-1.XX
$ perl Makefile.PL NO_HTTPD=1
$ make all install
you can fire up Apache with mod_perl enabled.
Apache and PHP
--------------
The PHP language (http://www.php.net/) from Rasmus Lerdorf <[EMAIL
PROTECTED]>
is a very impressive scripting language which can be directly integrated
into the Apache HTTP server for powerful HTML scripting. The distribution
php-3.0RC.tar.gz can be found on http://www.php.net/download-php.php3. Here
is how you can install Apache with PHP:
$ cd php-3.0RC
$ ./configure --with-apache=../apache-1.3
$ make
$ make install
$ cd ../apache-1.3
$ ./configure --prefix=/path/to/apache \
--activate-module=src/modules/extra/mod_php3.c
$ make
$ make install
1.1 apache-1.3/INSTALL
Index: INSTALL
===================================================================
A P A C H E I N S T A L L A T I O N
Installing the Apache 1.3 HTTP server manually
==============================================
If you really want to build and install Apache 1.3 manually, you can still
use the Apache 1.2 way by following the instructions in the file src/INSTALL
as in the past. Nothing has changes there. So when you are already familiar
with this procedure or really need a very special custom configuration go
for it.
On the other hand you should remember that the new Apache 1.3 Autoconf-style
Interface (APACI) already is a user-friendly frontend to the old scripts (it
actually uses them internally). And because APACI provides all usually
needed functionality the user wants to specify, there is no longer real need
to do so. Especially when it comes to the installation process: only APACI
provides an out-of-the-box way of installing the _complete_ Apache package.
See the file README.configure for an overview of APACI and the following
description for detailed information about how to use APACI.
Installing the Apache 1.3 HTTP server with APACI
================================================
1. Overview for the impatient
--------------------------
$ ./configure --prefix=PREFIX
$ make
$ make install
$ PREFIX/sbin/apachectl start
2. Requirements
------------
The following requirements exist for building Apache:
o Disk Space:
Make sure you have approximately 12 MB of temporary free disk space
available. After installation Apache occupies approximately 3 MB of
disk space (the actual required disk space depends on the amount of
compiled in third party modules, etc).
o ANSI-C Compiler:
Make sure you have an ANSI-C compiler installed. The GNU C compiler
(GCC) from the Free Software Foundation (FSF) is recommended. If you
don't have GCC then at least make sure your vendors compiler is ANSI
compliant. You can find the homepage of GNU at
http://www.gnu.ai.mit.edu/ and the GCC distribution under
http://www.gnu.ai.mit.edu/order/ftp.html .
o Perl 5 Interpreter (OPTIONAL):
For some of the support scripts like `apachectl' (which are written in
Perl) the Perl 5 interpreter is required. If no such interpreter is
found by APACI's `configure' script this is no harm. You still can
build and install Apache 1.3. Only those support scripts cannot be
used. If you have multiple Perl interpreters installed (perhaps a Perl
4 from the vendor and a Perl 5 from your own), then it is recommended
to use the --with-perl option (see below) to make sure the correct one
is selected by APACI.
3. Configuring the source tree
---------------------------
The next step is to configure the Apache source tree for your particular
system/platform and personal requirements. The most important setup here
is the location prefix where Apache is to be installed later, because
Apache has to be configured for this location to work correctly.
$ [CC=...] [CFLAGS_SHLIB=...]
[OPTIM=...] [LDFLAGS_SHLIB=...]
[CFLAGS=...] [LDFLAGS_SHLIB_EXPORT=...]
[INCLUDES=...]
[LDFLAGS=...] [RANLIB=...]
[LIBS=...]
./configure [--quiet] [--prefix=DIR] [--enable-rule=NAME]
[--verbose] [--exec-prefix=PREFIX] [--disable-rule=NAME]
[--shadow] [--bindir=EPREFIX] [--add-module=FILE]
[--help] [--sbindir=DIR] [--activate-module=FILE]
[--layout] [--libexecdir=DIR] [--enable-module=NAME]
[--mandir=DIR] [--disable-module=NAME]
[--sysconfdir=DIR] [--enable-shared=NAME]
[--datadir=DIR] [--disable-shared=NAME]
[--localstatedir=DIR]
[--compat] [--with-perl=FILE]
[--enable-suexec]
[--suexec-caller=UID]
[--suexec-userdir=DIR]
Use the CC, OPTIM, CFLAGS, INCLUDES, LDFLAGS, LIBS, CFLAGS_SHLIB,
LDFLAGS_SHLIB, LDFLAGS_SHLIB_EXPORT and RANLIB environment variables to
override the corresponding default entries in the src/Configuration.tmpl
file (see there for more information about their usage).
Use the --prefix=PREFIX and --exec-prefix=EPREFIX options to configure
Apache to use a particular installation prefix. The default is
PREFIX=/usr/local and EPREFIX=PREFIX.
Use the --bindir=DIR, --sbindir=DIR, --libexecdir=DIR, --mandir=DIR,
--sysconfdir=DIR, --datadir=DIR and --localstatedir=DIR option to change
the paths for particular subdirectories of the installation tree. Defaults
are bindir=EPREFIX/bin, sbindir=EPREFIX/sbin, libexecdir=EPREFIX/libexec,
mandir=PREFIX/man, sysconfdir=PREFIX/etc, datadir=PREFIX/share and
localstatedir=PREFIX/var.
Use the --compat option to install Apache into a installation tree which
has a similar layout than the one used with Apache 1.2.
Use the --layout option to check the final installation path layout while
fiddling with the options above.
Use the --enable-rule=NAME and --disable-rule=NAME options to enable or
disable a particular Rule from the Apache src/Configuration.tmpl file. The
defaults (yes=enabled, no=disabled) can either be seen when running
`./configure --help' or manually looked up in the src/Configuration.tmpl
file.
Use the --add-module=FILE option to copy a module source file to the
Apache src/modules/extra/ directory and on-the-fly add an entry for it in
the configuration file. FILE has to be a valid path to a C source file
outside the Apache source tree, for instance /path/to/mod_foo.c. The added
module this is way is automatically activated and enabled. Use this option
to automatically include a simple third-party module to the Apache build
process.
Use the --activate-module=FILE option to on-the-fly add an entry for an
existing module source file in the configuration file. FILE has to be a
valid path under src/modules/ of the Apache source tree, i.e. it already
has to be copied to this location before. The module is automatically
enabled. Use this option to automatically include a complex third-party
module to the Apache build process where, for instance a module like
mod_perl or mod_php3 consisting of more than one file which are created by
a third-party configuration scheme.
Use the --enable-module=NAME and --disable-module=NAME options to enable
or disable a particular already distributed module from the Apache
src/Configuration.tmpl file. The defaults (yes=enabled, no=disabled) can
be seen when running `./configure --help'. There are two special NAME
variants: "all" for enabling or disabling all modules and "most" for
enabling or disabling only these modules which are useable on all
platforms (currently this is "all" minus the "auth_db", "log_agent",
"log_referer", "example" and "so" module).
Use the --enable-shared=NAME and --disable-shared=NAME options to enable
or disable the shared object support for a particular module from the
Apache src/Configuration.tmpl file. The defaults (yes=enabled,
no=disabled) can be seen when running `./configure --help'. There are two
special NAME variants: "max" for enabling or disabling all modules except
the bootstrapping "so" module and "remain" for enabling or disabling only
these modules which are still not enabled. ATTENTION: Shared object
support is not available on all platforms. See the src/Configuration.tmpl
file for the definitive list of supported platforms.
Use the --with-perl=FILE option to select a particular Perl interpreter
executable to be used with Apache. Per default APACI tries to find it
automatically. But if multiple Perl instances exist on your system you
have to select the correct one manually.
Use the --enable-suexec option to enable the suEXEC feature by building
and installing the "suexec" support program. Use --suexec-caller=UID to
set the allowed caller user id and --suexec-userdir=DIR to set the user
subdirectory for this feature.
Use the --shadow option to let APACI create a shadow source tree of the
sources for building. This is useful when you want to build for different
platforms in parallel (usually through a NFS, AFS or DFS mounted
filesystem).
Use the --quiet option to disable all configuration verbose messages.
Use the --verbose option to enable additional verbose messages.
4. Building the package
--------------------
Now you can build the various parts which form the Apache package by
simply running the command
$ make
Please be patient here, this takes approximately 2 minutes to complete
under a Pentium-166/FreeBSD-2.1 system, dependend on the amount of modules
you have enabled.
5. Installing the package
----------------------
Now its time to install the package under the configured installation
PREFIX (see --prefix above) by running:
$ make install
For the paranoid hackers under us: The above command really installs under
prefix _only_, i.e. no other stuff from your system is touched. Even if
you upgrade an existing installation your configuration files in
PREFIX/etc/ are preserved.
6. Testing the package
-------------------
Now you can fire up your Apache HTTP server by immediately running
$ PREFIX/sbin/apachectl start
and then you should be able to request your first document via URL
http://localhost/. Then stop the server again by running:
$ PREFIX/sbin/apachectl stop
7. Customizing the package
-----------------------
Finally you can customize your Apache HTTP server by editing the
configuration files under PREFIX/etc/.
$ vi PREFIX/etc/httpd.conf
$ vi PREFIX/etc/access.conf
$ vi PREFIX/etc/srm.conf
Have a look at the Apache manual under http://localhost/manual/ or
http://www.apache.org/docs/ for a complete reference of available
configuration directives.
Thanks for running Apache.
The Apache Group
www.apache.org
1.1 apache-1.3/configure
Index: configure
===================================================================
#!/bin/sh
## ====================================================================
## Copyright (c) 1998 The Apache Group. All rights reserved.
##
## Redistribution and use in source and binary forms, with or without
## modification, are permitted provided that the following conditions
## are met:
##
## 1. Redistributions of source code must retain the above copyright
## notice, this list of conditions and the following disclaimer.
##
## 2. Redistributions in binary form must reproduce the above copyright
## notice, this list of conditions and the following disclaimer in
## the documentation and/or other materials provided with the
## distribution.
##
## 3. All advertising materials mentioning features or use of this
## software must display the following acknowledgment:
## "This product includes software developed by the Apache Group
## for use in the Apache HTTP server project (http://www.apache.org/)."
##
## 4. The names "Apache Server" and "Apache Group" must not be used to
## endorse or promote products derived from this software without
## prior written permission. For written permission, please contact
## [EMAIL PROTECTED]
##
## 5. Redistributions of any form whatsoever must retain the following
## acknowledgment:
## "This product includes software developed by the Apache Group
## for use in the Apache HTTP server project (http://www.apache.org/)."
##
## THIS SOFTWARE IS PROVIDED BY THE APACHE GROUP ``AS IS'' AND ANY
## EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
## IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
## PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE APACHE GROUP OR
## ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
## NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
## LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
## HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
## STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
## ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
## OF THE POSSIBILITY OF SUCH DAMAGE.
## ====================================================================
##
## This software consists of voluntary contributions made by many
## individuals on behalf of the Apache Group and was originally based
## on public domain software written at the National Center for
## Supercomputing Applications, University of Illinois, Urbana-Champaign.
## For more information on the Apache Group and the Apache HTTP server
## project, please see <http://www.apache.org/>.
##
##
## configure -- Apache Autoconf-style Interface (APACI)
##
## Written by Ralf S. Engelschall <[EMAIL PROTECTED]>
##
##
## the paths to the Apache source tree
##
root=.
src=src
mkf=Makefile
aux=src/helpers
##
## pre-determine runtime modes
##
quiet=no
verbose=no
case "$*" in
--help|*--help|*--help* ) quiet=yes ;;
--quiet|*--quiet|*--quiet* ) quiet=yes ;;
--verbose|*--verbose|*--verbose*|-v|*-v|*-v* ) verbose=yes ;;
* ) ;;
esac
##
## display version information
##
if [ ".$quiet" = .no ]; then
APV=`cat $src/include/httpd.h |\
grep "#define SERVER_BASEVERSION" |\
sed -e 's/^[^"]*"//' -e 's/".*$//' -e 's/^Apache\///'`
echo "Configuring for Apache, Version $APV"
fi
##
## important hint for the first-time users
##
if [ $# -eq 0 ]; then
echo " + Warning: Configuring Apache with default settings."
echo " + This is probably not what you really want."
echo " + Please read the README.configure and INSTALL files"
echo " + first or at least run '$0 --help' for"
echo " + a compact summary of available options."
fi
##
## determine optional Perl interpreter
##
PERL=no-perl-on-this-system
IFS=:
for dir in $PATH; do
for exe in perl5 perl miniperl; do
if test -f "$dir/$exe"; then
if test -x "$dir/$exe"; then
PERL="$dir/$exe"
fi
fi
done
done
PERL="`echo $PERL | sed -e 's://:/:'`"
##
## determine default parameters
##
# default paths
prefix='/usr/local'
exec_prefix='$prefix'
bindir='$exec_prefix/bin'
sbindir='$exec_prefix/sbin'
libexecdir='$exec_prefix/libexec'
mandir='$prefix/man'
sysconfdir='$prefix/etc'
datadir='$prefix/share'
localstatedir='$prefix/var'
localstatesubdir_run='run'
localstatesubdir_logs='logs'
# check and debug
layout=0
# suexec defaults
suexec=0
suexec_caller=www
suexec_userdir=public_html
# determine rules
rules=""
rulelist=""
IFS='
'
for rule in `grep '^Rule' $src/Configuration.tmpl`; do
rule=`echo "$rule" | sed -e 's/^Rule[ ]*//'`
name=`echo "$rule" | sed -e 's/=.*$//'`
namelow=`echo "$name" | tr "A-Z" "a-z"`
arg=`echo "$rule" | sed -e 's/^.*=//'`
eval "rule_$namelow=$arg"
rules="$rules:$namelow"
rulelist="$rulelist:$name=$arg"
done
# determine modules
rm -f $src/Configuration.apaci 2>/dev/null
modules=""
modulelist=""
IFS='
'
for module in `egrep '^[# ]*(Add|Shared)Module' $src/Configuration.tmpl`; do
add=yes
share=no
if [ ".`echo $module | grep '^#'`" != . ]; then
add=no
fi
if [ ".`echo $module | grep 'SharedModule'`" != . ]; then
share=yes
fi
module=`echo "$module" |\
sed -e 's%^.*/\(.*\)$%\1%' \
-e 's/\.[oa]$//' \
-e 's/^mod_//' \
-e 's/^lib//'`
eval "module_$module=$add"
eval "shared_$module=$share"
modules="${modules}:$module"
modulelist="${modulelist}:$module=$add"
if [ ".$share" = .yes ]; then
modulelist="${modulelist}*"
fi
done
##
## parse argument line options
##
apc_prev=""
IFS='
'
for apc_option
do
# if previous option needs an argument, assign it.
if [ ".$apc_prev" != . ]; then
eval "$apc_prev=\$apc_option"
apc_prev=""
continue
fi
# split out arguments
case "$apc_option" in
-*=*) apc_optarg=`echo "$apc_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
*) apc_optarg= ;;
esac
# accept only the most important GNU Autoconf-style options
case "$apc_option" in
--quiet | --silent)
quiet=yes
;;
--verbose | -v)
verbose=yes
;;
--shadow)
# determine GNU platform triple
gnutriple=`$src/helpers/GuessOS | awk '{ printf("%s",$1); }' |
sed -e 's:/:-:g'`
# create Makefile wrapper
if [ .$quiet = .no ]; then
echo " + creating Makefile (shadow wrapper)"
fi
echo "##" > Makefile
echo "## Apache Makefile (shadow wrapper)" >> Makefile
echo "##" >> Makefile
echo "" >> Makefile
echo "GNUTRIPLE=\`$src/helpers/GuessOS | awk '{
printf(\"%s\",\$\$1); }' | sed -e 's:/:-:g'\`" >> Makefile
echo "" >> Makefile
echo "all build install clean distclean:" >> Makefile
echo " @\$(MAKE) -f Makefile.\$(GNUTRIPLE) \$(MFLAGS) \$@" >>
Makefile
echo "" >> Makefile
# set shadow paths
shadowmkf="Makefile.$gnutriple"
shadowsrc="src.$gnutriple"
# (re)create shadow tree
if [ .$quiet = .no ]; then
echo " + create shadow tree ($shadowsrc)"
fi
rm -rf $shadowsrc
mkdir $shadowsrc
$aux/mkshadow.sh $src $shadowsrc
# delegate us to the shadow paths
mkf=$shadowmkf
src=$shadowsrc
;;
--help | -h | -help )
echo "Usage: configure [options]"
echo "Options: [defaults in brackets after descriptions]"
echo "General options:"
echo " --quiet, --silent do not print messages"
echo " --verbose, -v print even more messages"
echo " --shadow switch to a shadow tree for
building"
echo ""
echo "Stand-alone options:"
echo " --help, -h print this message"
echo " --layout print installation layout (check
and debug)"
echo ""
echo "Installation layout options:"
echo " --prefix=PREFIX install architecture-independent
files in PREFIX"
echo " --exec-prefix=EPREFIX install architecture-dependent
files in EPREFIX"
echo " --bindir=DIR install user executables in DIR
[EPREFIX/bin]"
echo " --sbindir=DIR install sysadmin executables in DIR
[EPREFIX/sbin]"
echo " --libexecdir=DIR install program executables in DIR
[EPREFIX/libexec]"
echo " --mandir=DIR install manual pages in DIR
[PREFIX/man]"
echo " --sysconfdir=DIR install configuration files in DIR
[PREFIX/etc]"
echo " --datadir=DIR install read-only data files in
DIR [PREFIX/share]"
echo " --localstatedir=DIR install modifiable data files in
DIR [PREFIX/var]"
echo " --compat install with old Apache 1.2
installation paths"
echo ""
echo "Configuration options:"
echo " --enable-rule=NAME enable a particular Rule named
'NAME'"
echo " --disable-rule=NAME disable a particular Rule named
'NAME'"
$aux/ppl.sh $rulelist
echo " --add-module=FILE on-the-fly copy & activate a
third-party Module source"
echo " --activate-module=FILE on-the-fly activate existing
third-party Module source"
echo " --enable-module=NAME enable a particular Module named
'NAME'"
echo " --disable-module=NAME disable a particular Module named
'NAME'"
$aux/ppl.sh $modulelist
echo " --enable-shared=NAME enable build of Module named
'NAME' as a shared object"
echo " --disable-shared=NAME disable build of Module named
'NAME' as a shared object"
echo " --with-perl=FILE set the path to the optional Perl
interpreter to use"
echo ""
echo "suEXEC options:"
echo " --enable-suexec enable the suEXEC feature"
echo " --suexec-caller=NAME set the suEXEC username of the
allowed caller [$suexec_caller]"
echo " --suexec-userdir=DIR set the suEXEC user subdirectory
[$suexec_userdir]"
echo ""
exit 0
;;
--layout)
layout=1
;;
--prefix=*)
prefix="$apc_optarg"
;;
--exec-prefix=*)
exec_prefix="$apc_optarg"
;;
--bindir=*)
bindir="$apc_optarg"
;;
--sbindir=*)
sbindir="$apc_optarg"
;;
--libexecdir=*)
libexecdir="$apc_optarg"
;;
--mandir=*)
mandir="$apc_optarg"
;;
--sysconfdir=*)
sysconfdir="$apc_optarg"
;;
--datadir=*)
datadir="$apc_optarg"
;;
--localstatedir=*)
localstatedir="$apc_optarg"
;;
--compat)
prefix='/usr/local/apache'
exec_prefix='$prefix'
bindir='$exec_prefix/bin'
sbindir='$exec_prefix/bin'
libexecdir='$exec_prefix/bin'
mandir='$prefix/man'
sysconfdir='$prefix/conf'
datadir='$prefix'
localstatedir='$prefix'
localstatesubdir_run='logs'
localstatesubdir_logs='logs'
;;
--add-module=*)
file="$apc_optarg"
case $file in
*.c ) ;;
* ) echo "configure:Error: Module source $file is not a C
source file";
exit 1
;;
esac
if [ ! -f $file ]; then
echo "configure:Error: Module source $file not found"
exit 1
fi
modfilec=`echo $file | sed -e 's;^.*/;;'`
modfileo=`echo $file | sed -e 's;^.*/;;' -e 's;\.c$;.o;'`
if [ ".$file" != ".$src/modules/extra/$modfilec" ]; then
cp $file $src/modules/extra/$modfilec
fi
echo "" >>$src/Configuration.apaci
echo "## On-the-fly added module" >>$src/Configuration.apaci
echo "## (configure --add-module=$file)"
>>$src/Configuration.apaci
echo "AddModule modules/extra/$modfileo"
>>$src/Configuration.apaci
module=`echo "$modfileo" |\
sed -e 's%^.*/\(.*\)$%\1%' \
-e 's/\.[^.]*$//' \
-e 's/^mod_//' \
-e 's/^lib//'`
eval "module_$module=yes"
eval "shared_$module=no"
modules="${modules}:$module"
modulelist="${modulelist}:$module=yes"
if [ ".$quiet" = .no ]; then
echo " + on-the-fly added and activated $module module
(modules/extra/$modfileo)"
fi
;;
--activate-module=*)
file="$apc_optarg"
case $file in
src/modules/* ) ;;
*) echo "configure:Error: Module source already has to stay
below src/modules/ to be activated"
exit 1
;;
esac
modfile=`echo $file | sed -e 's;^src/;;'`
echo "" >>$src/Configuration.apaci
echo "## On-the-fly activated module" >>$src/Configuration.apaci
echo "## (configure --activate-module=$file)"
>>$src/Configuration.apaci
echo "AddModule $modfile" >>$src/Configuration.apaci
module=`echo "$modfile" |\
sed -e 's%^.*/\(.*\)$%\1%' \
-e 's/\.[^.]*$//' \
-e 's/^mod_//' \
-e 's/^lib//'`
eval "module_$module=yes"
eval "shared_$module=no"
modules="${modules}:$module"
modulelist="${modulelist}:$module=yes"
if [ ".$quiet" = .no ]; then
echo " + activated $module module ($modfile)"
fi
;;
--enable-*)
apc_feature=`echo $apc_option | sed -e 's/-*enable-//' -e
's/=.*//'`
apc_feature=`echo $apc_feature | sed 's/-/_/g'`
case "$apc_option" in
*=*) ;;
*) apc_optarg=yes ;;
esac
case "$apc_feature" in
rule )
apc_optarg=`echo "$apc_optarg" | tr "A-Z" "a-z"`
apc_optarg_real=`echo "$apc_optarg" | tr "a-z" "A-Z"`
eval "exists=\$rule_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such rule named
'${apc_optarg_real}'"
exit 1
fi
eval "rule_${apc_optarg}=yes"
;;
module )
case $apc_optarg in
all )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "module_${module}=yes"
done
;;
most )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "module_${module}=yes"
done
module_auth_db=no # not all platforms have -ldb
module_log_agent=no # deprecated
module_log_referer=no # deprecated
module_example=no # only for developers
module_so=no # not all platforms have
dlopen()
;;
* )
eval "exists=\$module_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such module named
'${apc_optarg}'"
exit 1
fi
eval "module_${apc_optarg}=yes"
;;
esac
;;
shared )
case $apc_optarg in
max )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "shared_${module}=yes"
done
shared_so=no # because of bootstrapping
;;
remain )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "add=\$module_${module}"
if [ ".$add" = .no ]; then
eval "module_${module}=yes"
eval "shared_${module}=yes"
fi
done
shared_so=no
;;
* )
eval "exists=\$module_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such module named
'${apc_optarg}'"
exit 1
fi
eval "shared_${apc_optarg}=yes"
;;
esac
;;
suexec )
if [ ".`id | grep root`" = . ]; then
echo "configure:Error: suEXEC support needs root
priviledges for installation"
exit 1
fi
suexec=1
;;
esac
;;
--disable-*)
apc_feature=`echo $apc_option | sed -e 's/-*disable-//' -e
's/=.*//'`
apc_feature=`echo $apc_feature| sed 's/-/_/g'`
case "$apc_option" in
*=*) ;;
*) apc_optarg=yes ;;
esac
case "$apc_feature" in
rule )
apc_optarg=`echo "$apc_optarg" | tr "A-Z" "a-z"`
apc_optarg_real=`echo "$apc_optarg" | tr "a-z" "A-Z"`
eval "exists=\$rule_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such rule named
'${apc_optarg_real}'"
exit 1
fi
eval "rule_${apc_optarg}=no"
;;
module )
case $apc_optarg in
all )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "module_${module}=no"
done
;;
* )
eval "exists=\$module_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such module named
'${apc_optarg}'"
exit 1
fi
eval "module_${apc_optarg}=no"
;;
esac
;;
shared )
case $apc_optarg in
all )
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`;
do
eval "shared_${module}=no"
done
;;
* )
eval "exists=\$module_${apc_optarg}"
if [ ".$exists" = . ]; then
echo "configure:Error: No such module named
'${apc_optarg}'"
exit 1
fi
eval "shared_${apc_optarg}=no"
;;
esac
;;
esac
;;
--with-perl=*)
PERL="$apc_optarg"
;;
--suexec-caller=*)
suexec_caller="$apc_optarg"
;;
--suexec-userdir=*)
suexec_userdir="$apc_optarg"
;;
* )
echo "configure:Error: invalid option '$apc_option'"
exit 1
;;
esac
done
if [ ".$apc_prev" != . ]; then
echo "configure:Error: missing argument to --`echo $apc_prev | sed
's/_/-/g'`" 1>&2
exit 1
fi
##
## a few warnings
##
if [ ".$PERL" = .no-perl-on-this-system ]; then
if [ .$quiet = .no ]; then
echo " + Warning: no Perl interpreter available for support scripts."
echo " + Perhaps you have to select one with --with-perl=FILE."
fi
fi
##
## expand path variables
##
IFS=' '
for var in exec_prefix bindir sbindir \
libexecdir mandir sysconfdir datadir localstatedir; do
eval "val=\$$var";
eval "$var=\"$val$subdir\""
case $var in
sysconfdir|datadir|localstatedir )
eval "val=\$$var"
case $val in
*apache | *apache* ) ;;
* ) eval "$var=\$$var/apache" ;;
esac
;;
esac
done
##
## determine the compile-time defaults for the config files
## under sysconfdir where Apache supports prefix-relative paths
## for maximum flexibility (e.g. to use the -d option with -f)
##
localstatedir_compile=`echo $localstatedir | sed -e "s:^$prefix/*::" -e
's:\(.\)$:\1/:'`
sysconfdir_compile=`echo $sysconfdir | sed -e "s:^$prefix/*::" -e
's:\(.\)$:\1/:'`
##
## check and debug
##
if [ ".$layout" = .1 ]; then
echo ""
echo "Installation paths:"
echo " prefix: $prefix"
echo " exec_prefix: $exec_prefix"
echo " bindir: $bindir"
echo " sbindir: $sbindir"
echo " libexecdir: $libexecdir"
echo " mandir: $mandir"
echo " sysconfdir: $sysconfdir"
echo " datadir: $datadir"
echo " localstatedir: $localstatedir"
echo ""
echo "Compilation paths:"
echo " HTTPD_ROOT: $prefix"
echo " SUEXEC_BIN: $sbindir/suexec"
echo " DEFAULT_PIDLOG:
${localstatedir_compile}${localstatesubdir_run}/httpd.pid"
echo " DEFAULT_SCOREBOARD:
${localstatedir_compile}${localstatesubdir_run}/httpd.scoreboard"
echo " DEFAULT_LOCKFILE:
${localstatedir_compile}${localstatesubdir_run}/httpd.lock"
echo " DEFAULT_XFERLOG:
${localstatedir_compile}${localstatesubdir_logs}/access_log"
echo " DEFAULT_ERRORLOG:
${localstatedir_compile}${localstatesubdir_logs}/error_log"
echo " TYPES_CONFIG_FILE: ${sysconfdir_compile}mime.types"
echo " SERVER_CONFIG_FILE: ${sysconfdir_compile}httpd.conf"
echo " ACCESS_CONFIG_FILE: ${sysconfdir_compile}access.conf"
echo " RESOURCE_CONFIG_FILE: ${sysconfdir_compile}srm.conf"
echo ""
exit 0
fi
##
## create Makefile from Makefile.tmpl
##
if [ .$quiet = .no ]; then
echo "Creating $mkf"
fi
sed <Makefile.tmpl >$mkf \
-e "[EMAIL PROTECTED]@%$PERL%g" \
-e "[EMAIL PROTECTED]@%$root%g" \
-e "[EMAIL PROTECTED]@%$src%g" \
-e "[EMAIL PROTECTED]@%$mkf%g" \
-e "[EMAIL PROTECTED]@%$aux%g" \
-e "[EMAIL PROTECTED]@%$prefix%g" \
-e "[EMAIL PROTECTED]@%$exec_prefix%g" \
-e "[EMAIL PROTECTED]@%$bindir%g" \
-e "[EMAIL PROTECTED]@%$sbindir%g" \
-e "[EMAIL PROTECTED]@%$libexecdir%g" \
-e "[EMAIL PROTECTED]@%$mandir%g" \
-e "[EMAIL PROTECTED]@%$sysconfdir%g" \
-e "[EMAIL PROTECTED]@%$datadir%g" \
-e "[EMAIL PROTECTED]@%$localstatedir%g" \
-e "[EMAIL PROTECTED]@%$localstatesubdir_run%g" \
-e "[EMAIL PROTECTED]@%$localstatesubdir_logs%g" \
-e "[EMAIL PROTECTED]@%$suexec%g" \
-e "[EMAIL PROTECTED]@%$suexec_caller%g" \
-e "[EMAIL PROTECTED]@%$suexec_userdir%g"
##
## override default paths in $src/include/httpd.h
## via command line arguments for the compiler
## supplied by a little shell script named $src/apaci
##
echo "#!/bin/sh" >$src/apaci
echo "## USED AS A COMMAND LINE EXPANDER TO OVERRIDE PATHS" >>$src/apaci
echo "## WITHOUT DISTURBING THE KNOWN MAKE BUILD PROCESS DISPLAY" >>$src/apaci
echo "echo '-DHTTPD_ROOT=\"$prefix\"'" >>$src/apaci
echo "echo '-DSUEXEC_BIN=\"$sbindir/suexec\"'" >>$src/apaci
echo "echo
'-DDEFAULT_PIDLOG=\"${localstatedir_compile}${localstatesubdir_run}/httpd.pid\"'"
>>$src/apaci
echo "echo
'-DDEFAULT_SCOREBOARD=\"${localstatedir_compile}${localstatesubdir_run}/httpd.scoreboard\"'"
>>$src/apaci
echo "echo
'-DDEFAULT_LOCKFILE=\"${localstatedir_compile}${localstatesubdir_run}/httpd.lock\"'"
>>$src/apaci
echo "echo
'-DDEFAULT_XFERLOG=\"${localstatedir_compile}${localstatesubdir_logs}/access_log\"'"
>>$src/apaci
echo "echo
'-DDEFAULT_ERRORLOG=\"${localstatedir_compile}${localstatesubdir_logs}/error_log\"'"
>>$src/apaci
echo "echo '-DTYPES_CONFIG_FILE=\"${sysconfdir_compile}mime.types\"'"
>>$src/apaci
echo "echo '-DSERVER_CONFIG_FILE=\"${sysconfdir_compile}httpd.conf\"'"
>>$src/apaci
echo "echo '-DACCESS_CONFIG_FILE=\"${sysconfdir_compile}access.conf\"'"
>>$src/apaci
echo "echo '-DRESOURCE_CONFIG_FILE=\"${sysconfdir_compile}srm.conf\"'"
>>$src/apaci
chmod a+x $src/apaci
CFLAGS="$CFLAGS \\\`\$(SRCDIR)/apaci\\\`"
##
## create $src/Configuration.apaci file
##
if [ .$quiet = .no ]; then
echo "Creating Configuration.apaci in $src"
fi
rm -f sedsubst 2>/dev/null
touch sedsubst
# generate settings from imported environment variables
IFS=' '
for var in CC OPTIM CFLAGS CFLAGS_SHLIB LDFLAGS LDFLAGS_SHLIB \
LDFLAGS_SHLIB_EXPORT LIBS INCLUDES RANLIB; do
eval "val=\$$var";
if [ ".$val" != . ]; then
case $var in
CFLAGS|LDFLAGS|LIBS|INCLUDES) var="EXTRA_$var" ;;
esac
echo "s%^#*\\($var=\\).*%\\1$val%g" >>sedsubst
eval "$var="
fi
done
# generate rule directives
IFS=:
for rule in `echo "$rules" | sed -e 's/^://'`; do
name="`echo $rule | tr "a-z" "A-Z"`"
eval "val=\$rule_$rule"
echo "s%^\\(Rule $name=\\).*%\\1$val%g" >>sedsubst
if [ $verbose = yes ]; then
echo " + Rule $name=$val"
fi
done
# consistency checks for shared object support
some_shares=0
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`; do
eval "share=\$shared_$module"
if [ $share = yes ]; then
some_shares=1
fi
done
if [ $some_shares = 1 ]; then
if [ $module_so = no ]; then
module_so=yes
if [ .$quiet = .no ]; then
echo " + enabling mod_so for DSO support"
fi
fi
fi
if [ ".$shared_so" = yes ]; then
shared_so=no
echo "++ Module mod_so cannot be made a shared object"
exit 1
fi
# generate module directives
IFS=:
for module in `echo "$modules" | sed -e 's/^://'`; do
eval "add=\$module_$module"
if [ $add = yes ]; then
echo "s%^.*\\(AddModule.*$module\\..*\\)%\\1%g" >>sedsubst
echo "s%^.*\\(SharedModule.*$module\\..*\\)%\\1%g" >>sedsubst
m="yes [static]"
else
echo "s%^.*\\(AddModule.*$module\\..*\\)%# \\1%g" >>sedsubst
echo "s%^.*\\(SharedModule.*$module\\..*\\)%# \\1%g" >>sedsubst
m=no
fi
eval "share=\$shared_$module"
if [ $share = yes ]; then
echo
"s%^\\(.*\\)AddModule\\(.*$module\\.\\)[oa]\\(.*\\)%\\1SharedModule\\2so\\3%g"
>>sedsubst
m="yes [shared]"
fi
if [ $verbose = yes ]; then
echo " + Module $module: $m"
fi
done
# and finally translate the config template according to our situation
if [ -f $src/Configuration.apaci ]; then
(cat $src/Configuration.tmpl;
cat $src/Configuration.apaci ) |\
sed -f sedsubst >$src/Configuration.apaci.tmp
cp $src/Configuration.apaci.tmp $src/Configuration.apaci
rm -f $src/Configuration.apaci.tmp
else
cat $src/Configuration.tmpl | sed -f sedsubst >$src/Configuration.apaci
fi
rm -f sedsubst 2>/dev/null
##
## create all other Makefiles by running the proprietary
## $src/Configure script with our custom Configuration.apaci file
##
if [ .$quiet = .yes ]; then
(cd $src; CFLAGS= ./Configure -file Configuration.apaci >/dev/null);
else
(cd $src; CFLAGS= ./Configure -file Configuration.apaci |\
sed -e '/^Using config file:.*/d' \
-e "s:Makefile in :Makefile in $src\\/:" \
-e "s:Makefile\$:Makefile in $src:")
fi
1.1 apache-1.3/Makefile.tmpl
Index: Makefile.tmpl
===================================================================
## ====================================================================
## Copyright (c) 1998 The Apache Group. All rights reserved.
##
## Redistribution and use in source and binary forms, with or without
## modification, are permitted provided that the following conditions
## are met:
##
## 1. Redistributions of source code must retain the above copyright
## notice, this list of conditions and the following disclaimer.
##
## 2. Redistributions in binary form must reproduce the above copyright
## notice, this list of conditions and the following disclaimer in
## the documentation and/or other materials provided with the
## distribution.
##
## 3. All advertising materials mentioning features or use of this
## software must display the following acknowledgment:
## "This product includes software developed by the Apache Group
## for use in the Apache HTTP server project (http://www.apache.org/)."
##
## 4. The names "Apache Server" and "Apache Group" must not be used to
## endorse or promote products derived from this software without
## prior written permission. For written permission, please contact
## [EMAIL PROTECTED]
##
## 5. Redistributions of any form whatsoever must retain the following
## acknowledgment:
## "This product includes software developed by the Apache Group
## for use in the Apache HTTP server project (http://www.apache.org/)."
##
## THIS SOFTWARE IS PROVIDED BY THE APACHE GROUP ``AS IS'' AND ANY
## EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
## IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
## PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE APACHE GROUP OR
## ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
## NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
## LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
## HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
## STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
## ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
## OF THE POSSIBILITY OF SUCH DAMAGE.
## ====================================================================
##
## This software consists of voluntary contributions made by many
## individuals on behalf of the Apache Group and was originally based
## on public domain software written at the National Center for
## Supercomputing Applications, University of Illinois, Urbana-Champaign.
## For more information on the Apache Group and the Apache HTTP server
## project, please see <http://www.apache.org/>.
##
##
## Makefile -- Apache Autoconf-style Interface (APACI)
## top-level control Makefile for out-of-the-box
## build and installation procedure.
##
## Written by Ralf S. Engelschall <[EMAIL PROTECTED]>
##
## ==================================================================
## Options
## ==================================================================
# safe environment
SHELL = /bin/sh
# paths to the source tree parts
ROOT = @ROOT@
SRC = @SRC@
MKF = @MKF@
AUX = @AUX@
# build tools
CP = cp
MKDIR = $(AUX)/mkdir.sh
INSTALL = $(AUX)/install.sh -c
INSTALL_PROGRAM = $(INSTALL) -s -m 755
INSTALL_SCRIPT = $(INSTALL) -m 755
INSTALL_DATA = $(INSTALL) -m 644
PERL = @PERL@
# installation paths
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
sbindir = @sbindir@
libexecdir = @libexecdir@
mandir = @mandir@
sysconfdir = @sysconfdir@
datadir = @datadir@
localstatedir = @localstatedir@
localstatesubdir_run = @localstatesubdir_run@
localstatesubdir_logs = @localstatesubdir_logs@
# suexec details (optional)
suexec = @suexec@
suexec_caller = @suexec_caller@
suexec_userdir = @suexec_userdir@
# list of shared objects which have to _ALWAYS_ be enabled
# per default in the config file because of the directives used
# in these default files.
so_mods_in_conf = \
config_log_module|\
mime_module|\
negotiation_module|\
autoindex_module|\
dir_module|\
userdir_module|\
access_module|\
setenvif_module
## ==================================================================
## Targets
## ==================================================================
# default target
all: build
## ------------------------------------------------------------------
## Build Target
## ------------------------------------------------------------------
# build the programs
build:
@cd $(SRC); $(MAKE) $(MFLAGS) all 2>&1 | sed -e 's:^\([=<]==[>=]\) :\1
$(SRC)/:'
@echo "===> $(SRC)/support"; \
cd $(SRC)/support; $(MAKE) $(MFLAGS) all; \
if [ ".$(suexec)" = .1 ]; then \
$(MAKE) $(MFLAGS) \
EXTRA_CFLAGS='-DHTTPD_USER=\"$(suexec_caller)\"
-DUSERDIR_SUFFIX=\"$(suexec_userdir)\"' \
suexec; \
fi; \
echo "<=== $(SRC)/support"
@touch $(SRC)/.build.ok
## ------------------------------------------------------------------
## Installation Targets
## ------------------------------------------------------------------
# the install target for installing the complete Apache
# package. This is implemented by running subtargets for the
# separate parts of the installation process.
install:
@if [ ! -f $(SRC)/.build.ok ]; then \
$(MAKE) -f $(MKF) $(MFLAGS) build; \
fi
@$(MAKE) -f $(MKF) $(MFLAGS) \
install-mktree \
install-programs \
install-support \
install-config \
install-docroot
[EMAIL PROTECTED] -f .install.tmp
[EMAIL PROTECTED] -f .install.conf
[EMAIL PROTECTED] [ ".$(QUIET)" != .1 ]; then \
echo "+--------------------------------------------------------+"; \
echo "| You now have successfully built and installed the |"; \
echo "| Apache 1.3 HTTP server. To verify that Apache actually |"; \
echo "| works correctly you can immediately try to fire it up |"; \
echo "| the first time by running: |"; \
echo "| |"; \
echo "| $(sbindir)/apachectl start"; \
echo "| |"; \
echo "| Then you should additionally adjust the configuration |"; \
echo "| files which you can found under the following paths: |"; \
echo "| |"; \
echo "| $(sysconfdir)/{httpd,access,srm}.conf"; \
echo "| |"; \
echo "| Thanks for running Apache. |"; \
echo "| The Apache Group |"; \
echo "| www.apache.org |"; \
echo "+--------------------------------------------------------+"; \
fi
# the non-verbose variant for package maintainers
install-quiet:
@$(MAKE) -f $(MKF) QUIET=1 install
# create the installation tree
install-mktree:
@echo "===> [mktree: Creating Apache installation tree]"
$(MKDIR) $(bindir)
$(MKDIR) $(sbindir)
$(MKDIR) $(mandir)/man1
$(MKDIR) $(mandir)/man8
$(MKDIR) $(sysconfdir)
$(MKDIR) $(datadir)/htdocs
$(MKDIR) $(datadir)/icons
$(MKDIR) $(datadir)/cgi-bin
$(MKDIR) $(localstatedir)/$(localstatesubdir_logs)
$(MKDIR) $(localstatedir)/$(localstatesubdir_run)
$(MKDIR) $(localstatedir)/proxy
@echo "<=== [mktree]"
# install the server program and optionally corresponding
# shared object files.
install-programs:
@echo "===> [programs: Installing Apache httpd program and shared
objects]"
$(INSTALL_PROGRAM) $(SRC)/httpd $(sbindir)/httpd
$(INSTALL_DATA) $(SRC)/support/httpd.8 $(mandir)/man8/httpd.8
[EMAIL PROTECTED] -f .install.conf; touch .install.conf
[EMAIL PROTECTED] [ ".`grep '^[ ]*SharedModule'
$(SRC)/Configuration.apaci`" != . ]; then \
echo "$(MKDIR) $(libexecdir)"; \
$(MKDIR) $(libexecdir); \
for mod in `egrep '^[ ]*SharedModule'
$(SRC)/Configuration.apaci |\
sed -e 's/^[ ]*SharedModule[ ]*//'`; do \
file=`echo $$mod | sed -e 's;^.*/\([^/]*\);\1;'`; \
echo "$(INSTALL_SCRIPT) $(SRC)/$$mod $(libexecdir)/$$file"; \
$(INSTALL_SCRIPT) $(SRC)/$$mod $(libexecdir)/$$file; \
name=`$(AUX)/fmn.sh $(SRC)/$$mod`; \
prefix="#"; case $$name in $(so_mods_in_conf) )
prefix="" ;; esac; \
echo dummy | awk '{ printf("%sLoadModule %-18s %s\n", \
prefix, modname, modpath); }' \
prefix="$$prefix" modname="$$name" \
modpath="$(libexecdir)/$$file" >>.install.conf;
\
done; \
fi
@echo "<=== [programs]"
# install the support programs and scripts
install-support:
@echo "===> [support: Installing Apache support programs and scripts]"
$(INSTALL_PROGRAM) $(SRC)/support/ab $(sbindir)/ab
$(INSTALL_DATA) $(SRC)/support/ab.1 $(mandir)/man1/ab.1
sed -e
's;PIDFILE=.*;PIDFILE=$(localstatedir)/$(localstatesubdir_run)/httpd.pid;' \
-e 's;HTTPD=.*;HTTPD=$(sbindir)/httpd;' \
< $(SRC)/support/apachectl > .install.tmp && \
$(INSTALL_SCRIPT) .install.tmp $(sbindir)/apachectl
$(INSTALL_DATA) $(SRC)/support/apachectl.1 $(mandir)/man1/apachectl.1
$(INSTALL_PROGRAM) $(SRC)/support/htpasswd $(bindir)/htpasswd
$(INSTALL_DATA) $(SRC)/support/htpasswd.1 $(mandir)/man1/htpasswd.1
$(INSTALL_PROGRAM) $(SRC)/support/htdigest $(bindir)/htdigest
$(INSTALL_DATA) $(SRC)/support/htdigest.1 $(mandir)/man1/htdigest.1
sed -e 's;^#!/.*;#!$(PERL);' \
< $(SRC)/support/dbmmanage > .install.tmp && \
$(INSTALL_SCRIPT) .install.tmp $(bindir)/dbmmanage
$(INSTALL_DATA) $(SRC)/support/dbmmanage.1 $(mandir)/man1/dbmmanage.1
$(INSTALL_PROGRAM) $(SRC)/support/logresolve $(sbindir)/logresolve
$(INSTALL_DATA) $(SRC)/support/logresolve.8 $(mandir)/man8/logresolve.8
$(INSTALL_PROGRAM) $(SRC)/support/rotatelogs $(sbindir)/rotatelogs
$(INSTALL_DATA) $(SRC)/support/rotatelogs.8 $(mandir)/man8/rotatelogs.8
@if [ ".$(suexec)" = .1 ]; then \
echo "$(INSTALL_PROGRAM) $(SRC)/support/suexec $(sbindir)/suexec"; \
$(INSTALL_PROGRAM) $(SRC)/support/suexec $(sbindir)/suexec; \
echo "chown root $(sbindir)/suexec"; \
chown root $(sbindir)/suexec; \
echo "chmod 4711 $(sbindir)/suexec"; \
chmod 4711 $(sbindir)/suexec; \
echo "$(INSTALL_DATA) $(SRC)/support/suexec.8
$(mandir)/man8/suexec.8"; \
$(INSTALL_DATA) $(SRC)/support/suexec.8 $(mandir)/man8/suexec.8; \
fi
@echo "<=== [support]"
# create the initial configuration by providing default files
# and initial config files while preserving existing ones.
install-config:
@echo "===> [config: Installing Apache configuration files]"
for conf in httpd.conf access.conf srm.conf; do \
(echo "##"; \
echo "## $$conf -- Apache HTTP server configuration file"; \
echo "##"; \
echo ""; \
cat $(ROOT)/conf/$$conf-dist ) |\
sed -e '/#LoadModule/d' \
-e '/_before_ they are used./r .install.conf' \
-e 's;@@ServerRoot@@/htdocs;$(datadir)/htdocs;' \
-e 's;@@ServerRoot@@/htdocs;$(datadir)/htdocs;' \
-e 's;@@ServerRoot@@/icons;$(datadir)/icons;' \
-e 's;@@ServerRoot@@/cgi-bin;$(datadir)/cgi-bin;' \
-e 's;@@ServerRoot@@/proxy;$(localstatedir)/proxy;' \
-e 's;@@ServerRoot@@;$(prefix);' \
-e
's;logs/accept.lock;$(localstatedir)/$(localstatesubdir_run)/httpd.lock;' \
-e
's;logs/apache_status;$(localstatedir)/$(localstatesubdir_run)/httpd.scoreboard;'
\
-e
's;logs/httpd.pid;$(localstatedir)/$(localstatesubdir_run)/httpd.pid;' \
-e
's;logs/access_log;$(localstatedir)/$(localstatesubdir_logs)/access_log;' \
-e
's;logs/error_log;$(localstatedir)/$(localstatesubdir_logs)/error_log;' \
>.install.tmp && \
$(INSTALL_DATA) .install.tmp $(sysconfdir)/$$conf.default; \
if [ ! -f "$(sysconfdir)/$$conf" ]; then \
$(INSTALL_DATA) .install.tmp $(sysconfdir)/$$conf; \
fi; \
done
$(CP) $(ROOT)/conf/mime.types $(sysconfdir)/mime.types
$(CP) $(ROOT)/conf/magic $(sysconfdir)/magic
@echo "<=== [config]"
# create an initial document root containing the Apache manual,
# icons and distributed CGI scripts.
install-docroot:
@echo "===> [docroot: Installing initial DocumentRoot files]"
-$(CP) -R $(ROOT)/htdocs/* $(datadir)/htdocs/
-$(CP) -R $(ROOT)/icons/* $(datadir)/icons/
-$(CP) -R $(ROOT)/cgi-bin/* $(datadir)/cgi-bin/
@echo "<=== [docroot]"
## ------------------------------------------------------------------
## Cleanup Targets
## ------------------------------------------------------------------
# cleanup the source tree by removing anything which was
# created by the build target
clean:
@cd $(SRC); $(MAKE) $(MFLAGS) clean | sed -e 's:^\([=<]==[>=]\) :\1
$(SRC)/:'
@echo "===> $(SRC)/support"; \
cd $(SRC)/support; $(MAKE) $(MFLAGS) clean; \
if [ ".$(suexec)" = .1 ]; then \
echo "rm -f suexec"; \
rm -f suexec; \
fi; \
echo "<=== $(SRC)/support"
@rm -f $(SRC)/.build.ok
# first cleanup with the clean target and then additionally
# remove anything the "configure" script has created, i.e.
# create a really vanially source tree. When --shadow is used
# we just remove the complete shadow tree.
distclean:
@if [ ".$(SRC)" = .src ]; then \
$(MAKE) -f $(MKF) $(MFLAGS) distclean-std; \
else \
$(MAKE) -f $(MKF) $(MFLAGS) distclean-shadow; \
fi
distclean-std:
@$(MAKE) -f $(MKF) $(MFLAGS) clean
-rm -f $(SRC)/support/Makefile
-rm -f $(SRC)/main/Makefile
-rm -f $(SRC)/ap/Makefile
-rm -f $(SRC)/regex/Makefile
-rm -f $(SRC)/os/unix/Makefile
-rm -f $(SRC)/modules/experimental/Makefile
-rm -f $(SRC)/modules/extra/Makefile
-rm -f $(SRC)/modules/standard/Makefile
-rm -f $(SRC)/modules/proxy/Makefile
-rm -f $(SRC)/modules/Makefile
-rm -f $(SRC)/Makefile
-rm -f $(SRC)/Makefile.config
-rm -f $(SRC)/Configuration.apaci
-rm -f $(SRC)/apaci
-rm -f Makefile
distclean-shadow:
rm -rf $(SRC)
rm -rf $(MKF)
1.747 +11 -0 apache-1.3/src/CHANGES
Index: CHANGES
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/CHANGES,v
retrieving revision 1.746
retrieving revision 1.747
diff -u -r1.746 -r1.747
--- CHANGES 1998/03/29 02:32:35 1.746
+++ CHANGES 1998/03/29 12:27:31 1.747
@@ -1,5 +1,16 @@
Changes with Apache 1.3b6
+ *) Add the new Apache Autoconf-style Interface (APACI) for the top-level of
+ the Apache distribution tree. Until Apache 1.3 there was no real
+ out-of-the-box batch-capable build and installation procedure for the
+ complete Apache package. This is now provided by a top-level "configure"
+ script and a corresponding top-level "Makefile.tmpl" file. The goal is
+ to provide a GNU Autoconf-style frontend which is capable to both drive
+ the old src/Configure stuff in batch and additionally installs the
+ package with a GNU-conforming directory layout. Any options from the old
+ configuration scheme are available plus a lot of new options for
flexibly
+ customizing Apache. [Ralf S. Engelschall]
+
*) The floating point ap_snprintf code wasn't threadsafe.
Had to remove the HAVE_CVT macro in order to do threadsafe
calling of the ?cvt() floating point routines. [Dean Gaudet]
1.12 +2 -0 apache-1.3/src/.cvsignore
Index: .cvsignore
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/.cvsignore,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- .cvsignore 1997/11/13 22:25:45 1.11
+++ .cvsignore 1998/03/29 12:27:32 1.12
@@ -9,9 +9,11 @@
Configuration
Configuration.default
Configuration.lint
+Configuration.apaci
CoreD
CoreR
httpd
Makefile
Makefile.config
modules.c
+apaci
1.1 apache-1.3/src/helpers/fmn.sh
Index: fmn.sh
===================================================================
#!/bin/sh
##
## fmn.sh -- find a modules (structure) name
##
## Extracted from the Configure script by
## Ralf S. Engelschall <[EMAIL PROTECTED]> for use with
## Apache's Autoconf-style Interface (APACI).
##
# input: the modules source file
modfile=$1
# the part from the Configure script
tmpfile=/tmp/fmn.tmp.$$
rm -f $tmpfile
modname=''
ext=`echo $modfile | sed 's/^.*\.//'`
modbase=`echo $modfile | sed 's/\.[^.]*$//'`
if [ x$ext = x$modfile ]; then ext=o; modbase=$modfile; modfile=$modbase.o; fi
if [ x$ext = x ] ; then ext=o; modbase=$modfile; fi
if [ x$ext = xc ] ; then ext=o; fi
if [ -r $modbase.module ] ; then
cat $modbase.module >$tmpfile
else
if [ -f $modbase.c ] ; then
modname=`egrep '^module .*;' $modbase.c | head -1 |\
sed 's/^module.*[ ][ ]*//' | \
sed 's/[ ]*;[ ]*$//'`
if grep "MODULE-DEFINITION-" $modbase.c >/dev/null; then
cat $modbase.c | \
sed '1,/MODULE-DEFINITION-START/d;/MODULE-DEFINITION-END/,$d'
>$tmpfile
fi
fi
fi
if [ -r $tmpfile ] ; then
modname=`grep "Name:" $tmpfile | sed 's/^.*Name:[ ]*//'`
fi
if [ "x$modname" = "x" ] ; then
modname=`echo $modbase | sed 's/^.*\///' | \
sed 's/^mod_//' | sed 's/^lib//' | sed 's/$/_module/'`
fi
rm -f $tmpfile
# output: the name of the module structure symbol
echo "$modname"
1.1 apache-1.3/src/helpers/install.sh
Index: install.sh
===================================================================
#!/bin/sh
##
## install.sh -- install a program, script or datafile
##
## Based on `install-sh' from the X Consortium's X11R5 distribution
## as of 89/12/18 which is freely available.
## Cleaned up for Apache's Autoconf-style Interface (APACI)
## by Ralf S. Engelschall <[EMAIL PROTECTED]>
##
#
# put in absolute paths if you don't have them in your path;
# or use env. vars.
#
mvprog="${MVPROG-mv}"
cpprog="${CPPROG-cp}"
chmodprog="${CHMODPROG-chmod}"
chownprog="${CHOWNPROG-chown}"
chgrpprog="${CHGRPPROG-chgrp}"
stripprog="${STRIPPROG-strip}"
rmprog="${RMPROG-rm}"
#
# parse argument line
#
instcmd="$mvprog"
chmodcmd=""
chowncmd=""
chgrpcmd=""
stripcmd=""
rmcmd="$rmprog -f"
mvcmd="$mvprog"
src=""
dst=""
while [ ".$1" != . ]; do
case $1 in
-c) instcmd="$cpprog"
shift; continue
;;
-m) chmodcmd="$chmodprog $2"
shift; shift; continue
;;
-o) chowncmd="$chownprog $2"
shift; shift; continue
;;
-g) chgrpcmd="$chgrpprog $2"
shift; shift; continue
;;
-s) stripcmd="$stripprog"
shift; continue;;
*) if [ ".$src" = . ]; then
src=$1
else
dst=$1
fi
shift; continue
;;
esac
done
if [ ".$src" = . ]; then
echo "install.sh: no input file specified"
exit 1
fi
if [ ".$dst" = . ]; then
echo "install.sh: no destination specified"
exit 1
fi
#
# If destination is a directory, append the input filename; if
# your system does not like double slashes in filenames, you may
# need to add some logic
#
if [ -d $dst ]; then
dst="$dst/`basename $src`"
fi
# Make a temp file name in the proper directory.
dstdir=`dirname $dst`
dsttmp=$dstdir/#inst.$$#
# Move or copy the file name to the temp name
$instcmd $src $dsttmp
# And set any options; do chmod last to preserve setuid bits
if [ ".$chowncmd" != . ]; then $chowncmd $dsttmp; fi
if [ ".$chgrpcmd" != . ]; then $chgrpcmd $dsttmp; fi
if [ ".$stripcmd" != . ]; then $stripcmd $dsttmp; fi
if [ ".$chmodcmd" != . ]; then $chmodcmd $dsttmp; fi
# Now rename the file to the real destination.
$rmcmd $dst
$mvcmd $dsttmp $dst
exit 0
1.1 apache-1.3/src/helpers/mkdir.sh
Index: mkdir.sh
===================================================================
#!/bin/sh
##
## mkdir.sh -- make directory hierarchy
##
## Based on `mkinstalldirs' from Noah Friedman <[EMAIL PROTECTED]>
## as of 1994-03-25, which was placed in the Public Domain.
## Cleaned up for Apache's Autoconf-style Interface (APACI)
## by Ralf S. Engelschall <[EMAIL PROTECTED]>
##
errstatus=0
for file in ${1+"$@"} ; do
set fnord `echo ":$file" |\
sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
shift
pathcomp=
for d in ${1+"$@"}; do
pathcomp="$pathcomp$d"
case "$pathcomp" in
-* ) pathcomp=./$pathcomp ;;
esac
if test ! -d "$pathcomp"; then
echo "mkdir $pathcomp" 1>&2
mkdir "$pathcomp" || errstatus=$?
fi
pathcomp="$pathcomp/"
done
done
exit $errstatus
1.1 apache-1.3/src/helpers/mkshadow.sh
Index: mkshadow.sh
===================================================================
#!/bin/sh
##
## mkshadow.sh -- create a shadow tree
##
## Written by Ralf S. Engelschall <[EMAIL PROTECTED]>
## for the shadow tree generation option (--shadow) of
## Apache's Autoconf-style Interface (APACI)
##
src=`echo $1 | sed -e 's:/$::'`
dst=`echo $2 | sed -e 's:/$::'`
aux=$3
# create directory tree
DIRS="`cd $src
find . -type d -print |\
sed -e '/\/CVS/d' \
-e '/^\.$/d' \
-e 's/^\.\///'`"
for dir in $DIRS; do
mkdir $dst/$dir
done
# fill directory tree with symlinks to files
FILES="`cd $src
find . -type f -depth -print |\
sed -e '/\.o$/d' \
-e '/\.a$/d' \
-e '/\.so$/d' \
-e '/\.so-o$/d' \
-e '/\.cvsignore$/d' \
-e '/\/CVS/d' \
-e '/\.indent\.pro$/d' \
-e '/Makefile$/d' \
-e '/\/\.#/d' \
-e '/\.orig$/d' \
-e 's/^\.\///'`"
for file in $FILES; do
basename=`echo $file | sed -e 's:^.*/::'`
dir=`echo $file | sed -e 's:[^/]*$::' -e 's:/$::' -e 's:$:/:' -e
's:^/$::'`
from="$src/$file"
to="$dst/$dir$basename"
case $from in
/* ) ;;
* )
if [ ".$dir" != . ]; then
subdir=`echo $dir | sed -e 's:/$::'`
revdir=`$src/helpers/fp2rp $subdir`
from="$revdir/$from"
fi
;;
esac
case $dst in
/* ) ;;
* )
subdir=`echo $dst | sed -e 's:/$::'`
revdir=`$src/helpers/fp2rp $subdir`
from="$revdir/$from"
;;
esac
echo " $to"
ln -s $from $to
done
1.1 apache-1.3/src/helpers/ppl.sh
Index: ppl.sh
===================================================================
#!/bin/sh
##
## ppl.sh -- pretty print a colon-sperarated list by avoiding
## `tr' and `fmt' because these tools are different
## between Unix platforms
##
## Written by Ralf S. Engelschall <[EMAIL PROTECTED]>
## for pretty printing lists in the --help option of
## Apache's Autoconf-style Interface (APACI)
##
list=`
IFS=:
for entry in $*; do
if [ ".$entry" != . ]; then
echo $entry
fi
done |\
sort |\
awk '
BEGIN { list = ""; n = 0; }
{
list = list $1;
n = n + 1;
if (n == 1 || n == 2) {
list = list ":";
}
if (n == 3) {
list = list "\n";
n = 0;
}
}
END { print list; }
'`
IFS='
'
for entry in $list; do
echo $entry |\
awk -F: '
{ printf("%-15s %-15s %-15s\n", $1, $2, $3); }
'
done |\
awk '{
if (length($0) > 48) {
printf("%s\n", substr($0, 0, 47));
} else {
print $0;
}
}' |\
sed -e 's/^/ [/' -e 's/$/]/'
1.51 +11 -0 apache-1.3/htdocs/manual/new_features_1_3.html
Index: new_features_1_3.html
===================================================================
RCS file: /export/home/cvs/apache-1.3/htdocs/manual/new_features_1_3.html,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -r1.50 -r1.51
--- new_features_1_3.html 1998/03/20 07:56:48 1.50
+++ new_features_1_3.html 1998/03/29 12:27:37 1.51
@@ -588,6 +588,17 @@
API routine <CODE>const char *apapi_get_server_built()</CODE>,
which returns a string representing the time the core server was linked.
</LI>
+ <LI><STRONG>Apache Autoconf-style Interface (APACI)</STRONG>
+ <BR>
+ Until Apache 1.3 there was no real out-of-the-box batch-capable build and
+ installation procedure for the complete Apache package. This is now
provided
+ by a top-level <CODE>configure</CODE> script and a corresponding top-level
+ <CODE>Makefile.tmpl</CODE> file. The goal is to provide a GNU
Autoconf-style
+ frontend which is capable to both drive the old <CODE>src/Configure</CODE>
+ stuff in batch and additionally installs the package with a GNU-conforming
+ directory layout. Any options from the old configuration scheme are
+ available plus a lot of new options for flexibly customizing Apache.
+ </LI>
</UL>
<!--#include virtual="footer.html" -->
1.16 +3 -0 apache-1.3/htdocs/manual/upgrading_to_1_3.html
Index: upgrading_to_1_3.html
===================================================================
RCS file: /export/home/cvs/apache-1.3/htdocs/manual/upgrading_to_1_3.html,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- upgrading_to_1_3.html 1998/03/07 03:11:49 1.15
+++ upgrading_to_1_3.html 1998/03/29 12:27:37 1.16
@@ -58,6 +58,9 @@
<LI><CODE>mod_auth_msql</CODE> has been removed from the distribution.
+ <LI>The new Apache Autoconf-style Interface (APACI) was added to
+ the top-level to provide a real out-of-the-box build and installation
+ procedure for the complete Apache package.
</UL>
<H3>Run-Time Configuration Changes</H3>