#define BDB_DBENV_HOME LDAP_RUNDIR LDAP_DIRSEP "openldap-bdb"
+#ifdef BDB_SUBDIRS
#define BDB_TMP_SUBDIR LDAP_DIRSEP "tmp"
#define BDB_LG_SUBDIR LDAP_DIRSEP "log"
#define BDB_DATA_SUBDIR LDAP_DIRSEP "data"
+#else
+#define BDB_TMP_SUBDIR BDB_DBENV_HOME
+#define BDB_LG_SUBDIR BDB_DBENV_HOME
+#define BDB_DATA_SUBDIR BDB_DBENV_HOME
+#endif
#define BDB_NEXTID 0
#define BDB_DN2ID 1
bdb->bi_dbenv->set_errpfx( bdb->bi_dbenv, be->be_suffix[0] );
bdb->bi_dbenv->set_errcall( bdb->bi_dbenv, bdb_errcall );
+#ifdef BDB_SUBDIRS
{
char dir[MAXPATHLEN];
size_t len = strlen( bdb->bi_dbenv_home );
return rc;
}
}
+#endif
+
+ Debug( LDAP_DEBUG_TRACE,
+ "bi_back_db_open: dbenv_open(%s)\n",
+ bdb->bi_dbenv_home, 0, 0);
rc = bdb->bi_dbenv->open( bdb->bi_dbenv,
bdb->bi_dbenv_home,
bdb->bi_dbenv_mode );
if( rc != 0 ) {
Debug( LDAP_DEBUG_ANY,
- "bi_back_db_open: dbenv_open(%s) failed: %s (%d)\n",
- bdb->bi_dbenv_home, db_strerror(rc), rc );
+ "bi_back_db_open: dbenv_open failed: %s (%d)\n",
+ db_strerror(rc), rc, 0 );
return rc;
}