Thanks to a silly decision in the design of the latest gdbm, one finds that when trying to compile the stock Apache webserver source code on Slackware Linux 10 or above, the Apache configure fails to find gdbm. This isn't that much of a problem unless you use the popular mod_rewrite which relies on dbm, and thus can't now be built. e.g.
./configure \ --prefix=/usr/local/apache \ --enable-module=rewrite Configuring for Apache, Version 1.3.33 + using installation path layout: Apache (config.layout) Creating Makefile Creating Configuration.apaci in src Creating Makefile in src + configured for Linux platform + setting C compiler to gcc + setting C pre-processor to gcc -E + using "tr [a-z] [A-Z]" to uppercase + checking for system header files + adding selected modules o rewrite_module uses ConfigStart/End disabling DBM support for mod_rewrite (perhaps you need to add -ldbm, -lndbm or -lgdbm to EXTRA_LIBS) + using system Expat + checking sizeof various data types + doing sanity check on compiler and options Creating Makefile in src/support Creating Makefile in src/regex Creating Makefile in src/os/unix Creating Makefile in src/ap Creating Makefile in src/main Creating Makefile in src/modules/standardThe Solution
- Download the appropriate apache.dbm.diff.gz for your version of Slackware. In the 10.0 tree, it is in /patches/source/apache while in 10.1 it is in /source/n/apache.
- Untar your apache source, e.g. tar -xvzf apache_1.3.33.tar.gz
- cd apache_1.3.33
- gunzip ../apache.dbm.diff.gz
- patch -p1 < ../apache.dbm.diff
patching file src/modules/standard/mod_rewrite.h patching file src/modules/standard/mod_auth_dbm.c patching file src/helpers/find-dbm-libIf so, you're all set, and upon compiling Apache it will now find DBM.
o rewrite_module uses ConfigStart/End + using -ldb for DBM support enabling DBM support for mod_rewriteKelv