You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by ro...@apache.org on 2006/11/09 16:50:42 UTC

svn commit: r472954 - in /apr/apr-util/branches/0.9.x: CHANGES build/dbm.m4

Author: rooneg
Date: Thu Nov  9 07:50:42 2006
New Revision: 472954

URL: http://svn.apache.org/viewvc?view=rev&rev=472954
Log:
Merge r472635 from trunk to the 0.9.x branch.

Add support for Berkeley DB 4.5 to our configure scripts.

Modified:
    apr/apr-util/branches/0.9.x/CHANGES
    apr/apr-util/branches/0.9.x/build/dbm.m4

Modified: apr/apr-util/branches/0.9.x/CHANGES
URL: http://svn.apache.org/viewvc/apr/apr-util/branches/0.9.x/CHANGES?view=diff&rev=472954&r1=472953&r2=472954
==============================================================================
--- apr/apr-util/branches/0.9.x/CHANGES (original)
+++ apr/apr-util/branches/0.9.x/CHANGES Thu Nov  9 07:50:42 2006
@@ -1,5 +1,8 @@
 Changes with APR-util 0.9.13
 
+  *) Add support for Berkeley DB 4.5 to the configure scripts.
+     [Garrett Rooney]
+
   *) Provide folding in autogenerated .manifest files for Win32 builders
      using VisualStudio 2005  [William Rowe]
 

Modified: apr/apr-util/branches/0.9.x/build/dbm.m4
URL: http://svn.apache.org/viewvc/apr/apr-util/branches/0.9.x/build/dbm.m4?view=diff&rev=472954&r1=472953&r2=472954
==============================================================================
--- apr/apr-util/branches/0.9.x/build/dbm.m4 (original)
+++ apr/apr-util/branches/0.9.x/build/dbm.m4 Thu Nov  9 07:50:42 2006
@@ -448,7 +448,25 @@
     apu_db_version=4
   fi
 ])
-
+dnl
+dnl APU_CHECK_DB45: is DB4.5 present?
+dnl
+dnl if present: sets apu_db_header, apu_db_lib, and apu_db_version
+dnl
+AC_DEFUN([APU_CHECK_DB45], [
+  places=$1
+  if test -z "$places"; then
+    places="std /usr/local/BerkeleyDB.4.5 /boot/home/config"
+  fi
+  APU_CHECK_BERKELEY_DB("4", "5", "-1",
+    "$places",
+    "db45/db.h db4/db.h db.h",
+    "db-4.5 db4-4.5 db45 db4 db"
+  )
+  if test "$apu_have_db" = "1"; then
+    apu_db_version=4
+  fi
+])
 
 AC_DEFUN(APU_CHECK_DB, [
   requested=$1
@@ -515,6 +533,12 @@
       AC_MSG_ERROR(Berkeley db4 not found)
     fi
     ;;
+  db45)
+    APU_CHECK_DB44("$check_places")
+    if test "$apu_db_version" != "4"; then
+      AC_MSG_ERROR(Berkeley db4 not found)
+    fi
+    ;;
   default)
     APU_CHECK_DB_ALL("$check_places")
     ;;
@@ -527,23 +551,26 @@
 AC_DEFUN(APU_CHECK_DB_ALL, [
   all_places=$1
  
-  APU_CHECK_DB44("$all_places")
+  APU_CHECK_DB45("$all_places")
   if test "$apu_db_version" != "4"; then
-    APU_CHECK_DB43("$all_places")
+    APU_CHECK_DB44("$all_places")
     if test "$apu_db_version" != "4"; then
-      APU_CHECK_DB42("$all_places")
+      APU_CHECK_DB43("$all_places")
       if test "$apu_db_version" != "4"; then
-        APU_CHECK_DB41("$all_places")
+        APU_CHECK_DB42("$all_places")
         if test "$apu_db_version" != "4"; then
-          APU_CHECK_DB4("$all_places")
+          APU_CHECK_DB41("$all_places")
           if test "$apu_db_version" != "4"; then
-            APU_CHECK_DB3("$all_places")
-            if test "$apu_db_version" != "3"; then
-              APU_CHECK_DB2("$all_places")
-              if test "$apu_db_version" != "2"; then
-                APU_CHECK_DB1("$all_places")
-                if test "$apu_db_version" != "1"; then
-                  APU_CHECK_DB185("$all_places")
+            APU_CHECK_DB4("$all_places")
+            if test "$apu_db_version" != "4"; then
+              APU_CHECK_DB3("$all_places")
+              if test "$apu_db_version" != "3"; then
+                APU_CHECK_DB2("$all_places")
+                if test "$apu_db_version" != "2"; then
+                  APU_CHECK_DB1("$all_places")
+                  if test "$apu_db_version" != "1"; then
+                    APU_CHECK_DB185("$all_places")
+                  fi
                 fi
               fi
             fi
@@ -580,11 +607,11 @@
 
   AC_ARG_WITH(dbm, [
     --with-dbm=DBM          choose the DBM type to use.
-      DBM={sdbm,gdbm,ndbm,db,db1,db185,db2,db3,db4,db41,db42,db43,db44}
+      DBM={sdbm,gdbm,ndbm,db,db1,db185,db2,db3,db4,db41,db42,db43,db44,db45}
   ], [
     if test "$withval" = "yes"; then
       AC_MSG_ERROR([--with-dbm needs to specify a DBM type to use.
-        One of: sdbm, gdbm, ndbm, db, db1, db185, db2, db3, db4, db41, db42, db43, db44])
+        One of: sdbm, gdbm, ndbm, db, db1, db185, db2, db3, db4, db41, db42, db43, db44, db45])
     fi
     requested="$withval"
   ], [
@@ -770,6 +797,10 @@
       apu_use_db=1
       apu_default_dbm=db4
       ;;
+    db45)
+      apu_use_db=1
+      apu_default_dbm=db4
+      ;;
     default)
       dnl ### use more sophisticated DBMs for the default?
       apu_default_dbm="sdbm (default)"
@@ -777,7 +808,7 @@
       ;;
     *)
       AC_MSG_ERROR([--with-dbm=$look_for is an unknown DBM type.
-        Use one of: sdbm, gdbm, ndbm, db, db1, db185, db2, db3, db4, db41, db42, db43, db44])
+        Use one of: sdbm, gdbm, ndbm, db, db1, db185, db2, db3, db4, db41, db42, db43, db44 db45])
       ;;
   esac