diff --git a/build/openldap.m4 b/build/openldap.m4
index 273a61c74ff767a5275b60d63230f2f8cf5a0e77..daa0ebf6b8068e1d32d60e78ce5364dccbd0414c 100644
--- a/build/openldap.m4
+++ b/build/openldap.m4
@@ -691,8 +691,8 @@ AC_DEFUN([OL_BDB_COMPAT],
 #	define DB_VERSION_MINOR 0
 #endif
 
-/* require 4.2 or later */
-#if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 2)
+/* require 4.2 or later, but exclude 4.3 */
+#if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 2) && (DB_VERSION_MINOR !=3)
 	__db_version_compat
 #endif
 	], [ol_cv_bdb_compat=yes], [ol_cv_bdb_compat=no])])