]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
The diagnosis of the location of ndbm.h was broken for mod_rewrite and
authorVictor J. Orlikowski <orlikowski@apache.org>
Wed, 21 Mar 2001 03:09:45 +0000 (03:09 +0000)
committerVictor J. Orlikowski <orlikowski@apache.org>
Wed, 21 Mar 2001 03:09:45 +0000 (03:09 +0000)
mod_auth_dbm on some systems using glibc 2.2 (i.e. SuSE 7.1).

PR: 6929

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@88554 13f79535-47bb-0310-9956-ffa450edef68

src/helpers/find-dbm-lib
src/modules/standard/mod_auth_dbm.c
src/modules/standard/mod_rewrite.h

index ac82b396e56db959b614e325cdcad839f4271adb..4ec265b326c46c4fa3d641e0e2c53b08f16f79ee 100644 (file)
@@ -17,8 +17,12 @@ if [ "x$found_dbm" = "x" ]; then
                    DBM_LIB="-ldbm"
                elif ./helpers/TestCompile lib ndbm dbm_open; then
                    DBM_LIB="-lndbm"
+                   if ./helpers/TestCompile lib db1 dbm_open; then
+                       # Red Hat needs this; ndbm.h lives in db1
+                       CFLAGS="$CFLAGS -I/usr/include/db1"
+                   fi
                elif ./helpers/TestCompile lib db1 dbm_open; then
-                   # For Red Hat 7
+                   # For Red Hat 7, if not handled by the ndbm case above
                    DBM_LIB="-ldb1"
                    CFLAGS="$CFLAGS -I/usr/include/db1"
                fi
index 0bca9d2c8ac9037227af8663ee32bb6e4036b251..0545e600743b717aa5aad9f0c41bd1bde6719ecb 100644 (file)
@@ -80,9 +80,6 @@
 #define dbm_open sdbm_open
 #define dbm_fetch sdbm_fetch
 #define dbm_close sdbm_close
-#elif defined(__GLIBC__) && defined(__GLIBC_MINOR__) \
-    && __GLIBC__ >= 2 && __GLIBC_MINOR__ >= 1
-#include <db1/ndbm.h>
 #else
 #include <ndbm.h>
 #endif
index 88b98de12ee6c295e74d3352284f86a44eb94479..f5804ff41d3842e9a23cfc9599d99e208b56c830 100644 (file)
      * so we also need to know the file extension
      */
 #ifndef NO_DBM_REWRITEMAP
-#if defined(__GLIBC__) && defined(__GLIBC_MINOR__) \
-    && __GLIBC__ >= 2 && __GLIBC_MINOR__ >= 1
-#include <db1/ndbm.h>
-#else
 #include <ndbm.h>
-#endif
 #if defined(DBM_SUFFIX)
 #define NDBM_FILE_SUFFIX DBM_SUFFIX
 #elif defined(__FreeBSD__) || (defined(DB_LOCK) && defined(DB_SHMEM))