]> git.sur5r.net Git - openldap/blobdiff - build/openldap.m4
Merge remote-tracking branch 'origin/mdb.master'
[openldap] / build / openldap.m4
index 2f72bb2ff5fb3dff30be339694c5c228c6c5ff52..caf8fc2aa6642b3d2ffe02f56dd0a343d4be32f5 100644 (file)
@@ -2,7 +2,7 @@ dnl OpenLDAP Autoconf Macros
 dnl $OpenLDAP$
 dnl This work is part of OpenLDAP Software <http://www.openldap.org/>.
 dnl
-dnl Copyright 1998-2012 The OpenLDAP Foundation.
+dnl Copyright 1998-2014 The OpenLDAP Foundation.
 dnl All rights reserved.
 dnl
 dnl Redistribution and use in source and binary forms, with or without
@@ -547,12 +547,18 @@ AC_DEFUN([OL_BDB_COMPAT],
 #ifndef DB_VERSION_MINOR
 #      define DB_VERSION_MINOR 0
 #endif
+#ifndef DB_VERSION_PATCH
+#      define DB_VERSION_PATCH 0
+#endif
 
-#define DB_VERSION_MM  ((DB_VERSION_MAJOR<<8)|DB_VERSION_MINOR)
+#define DB_VERSION_FULL        ((DB_VERSION_MAJOR<<16)|(DB_VERSION_MINOR<<8)|DB_VERSION_PATCH)
 
-/* require 4.4 or later */
-#if DB_VERSION_MM >= 0x0404
+/* require 4.4 or later, but less than 6.0.20 */
+#if DB_VERSION_FULL >= 0x040400 && DB_VERSION_FULL < 0x060014
        __db_version_compat
+#endif
+#if DB_VERSION_FULL >= 0x060014
+#error "BerkeleyDB 6.0.20+ license is incompatible with LDAP"
 #endif
        ], [ol_cv_bdb_compat=yes], [ol_cv_bdb_compat=no])])
 ])