Index: /main/trunk/greenstone2/common-src/configure
===================================================================
--- /main/trunk/greenstone2/common-src/configure	(revision 21408)
+++ /main/trunk/greenstone2/common-src/configure	(revision 21409)
@@ -312,5 +312,5 @@
 ac_subdirs_all="$ac_subdirs_all packages"
 ac_subdirs_all="$ac_subdirs_all indexers"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE VERSION USE_FASTCGI USE_LANGACTION USE_CORBA MICO_DIR USE_Z3950 USE_YAZ ENABLE_ACCENTFOLD USE_SQLITE ENABLE_JNI ENABLE_MG ENABLE_MGPP ENABLE_LUCENE LDFLAGS CFLAGS CC CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX AWK YACC build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SET_MAKE RANLIB ac_ct_RANLIB COMPAT32BITFLAGS MICO_VER CPP EGREP U ANSI2KNR ALLOCA LIBOBJS STATIC gsdlos MODULEDIRS subdirs LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE VERSION USE_FASTCGI USE_LANGACTION USE_CORBA MICO_DIR USE_Z3950 USE_YAZ ENABLE_ACCENTFOLD USE_JDBM USE_SQLITE ENABLE_JNI ENABLE_MG ENABLE_MGPP ENABLE_LUCENE LDFLAGS CFLAGS CC CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX AWK YACC build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SET_MAKE RANLIB ac_ct_RANLIB COMPAT32BITFLAGS MICO_VER CPP EGREP U ANSI2KNR ALLOCA LIBOBJS STATIC gsdlos MODULEDIRS subdirs LTLIBOBJS'
 ac_subst_files=''
 
@@ -860,4 +860,5 @@
   --disable-yaz           Disable YAZ compilation
   --disable-accentfold    Disable Accent Folding for MGPP
+  --disable-jdbm        Disable JDBM support
   --disable-sqlite        Disable SQLite support
   --enable-jni    Enable JNI compilation
@@ -1427,4 +1428,17 @@
 
 
+# Check whether --enable-jdbm or --disable-jdbm was given.
+if test "${enable_jdbm+set}" = set; then
+  enableval="$enable_jdbm"
+  USE_JDBM=0
+else
+  USE_JDBM=1
+fi;
+cat >>confdefs.h <<\_ACEOF
+#define USE_JDBM $USE_JDBM
+_ACEOF
+
+
+
 # Check whether --enable-sqlite or --disable-sqlite was given.
 if test "${enable_sqlite+set}" = set; then
@@ -7903,4 +7917,5 @@
 s,@USE_YAZ@,$USE_YAZ,;t t
 s,@ENABLE_ACCENTFOLD@,$ENABLE_ACCENTFOLD,;t t
+s,@USE_JDBM@,$USE_JDBM,;t t
 s,@USE_SQLITE@,$USE_SQLITE,;t t
 s,@ENABLE_JNI@,$ENABLE_JNI,;t t
Index: /main/trunk/greenstone2/common-src/configure.in
===================================================================
--- /main/trunk/greenstone2/common-src/configure.in	(revision 21408)
+++ /main/trunk/greenstone2/common-src/configure.in	(revision 21409)
@@ -68,4 +68,11 @@
 AC_DEFINE(ENABLE_ACCENTFOLD, $ENABLE_ACCENTFOLD)
 AC_SUBST(ENABLE_ACCENTFOLD)
+
+dnl
+dnl Set use of JDBM (enabled by default)
+dnl
+AC_ARG_ENABLE(jdbm, [  --disable-jdbm        Disable JDBM support], USE_JDBM=0, USE_JDBM=1)
+AC_DEFINE(USE_JDBM, $USE_JDBM)
+AC_SUBST(USE_JDBM)
 
 dnl
Index: /main/trunk/greenstone2/common-src/packages/Makefile.in
===================================================================
--- /main/trunk/greenstone2/common-src/packages/Makefile.in	(revision 21408)
+++ /main/trunk/greenstone2/common-src/packages/Makefile.in	(revision 21409)
@@ -26,4 +26,12 @@
 
 
+USE_JDBM=@USE_JDBM@
+
+ifeq ($(USE_JDBM), 1)
+JDBM_DIR = jdbm/jdbm-1.0
+else
+JDBM_DIR = 
+endif
+
 USE_SQLITE=@USE_SQLITE@
 
@@ -39,5 +47,5 @@
 # CLEANDIRS is COMPILEDIRS and iconv and expat. Iconv and expat get compiled
 # up during the configure stage itself.
-COMPILEDIRS =	gdbm $(SQLITE_DIR) search4j
+COMPILEDIRS =	gdbm $(SQLITE_DIR) $(JDBM_DIR) search4j
 CLEANDIRS =	iconv expat $(COMPILEDIRS)
 
@@ -48,4 +56,8 @@
           (cd $$odir && $(MAKE) $(MDEFINES) $@) || exit 1; \
         done
+ifeq ($(USE_JDBM), 1)
+# do 'make install' in jdbm directory to get the jar file into the right place
+	cd $(JDBM_DIR) && $(MAKE) $(MDEFINES) install
+endif
 ifeq ($(USE_SQLITE), 1)
 # need to do make install in sqlite to get the header files and library into the right place
Index: /main/trunk/greenstone2/common-src/packages/configure
===================================================================
--- /main/trunk/greenstone2/common-src/packages/configure	(revision 21408)
+++ /main/trunk/greenstone2/common-src/packages/configure	(revision 21409)
@@ -181,4 +181,21 @@
 
 
+# configure JDBM
+echo ""
+echo "Configuring JDBM"
+if test x$USE_JDBM = xtrue ; 
+then
+  echo ""
+  cd "$PACKAGES/jdbm"
+  if test ! -d jdbm-1.0 ;
+  then
+    gzip -dc gs-jdbm-1.0.tar.gz | tar -xf -
+  fi
+else
+  echo "JDBM support disabled."
+  echo "  add '--enable-jdbm' to the configure command to include JDBM support."
+  echo ""
+fi
+
 # configure SQLite
 echo ""
@@ -189,5 +206,5 @@
   cd "$PACKAGES/sqlite"
   if test ! -d sqlite-amalgamation-3.5.9 ;
-  then
+  then 
     gzip -dc sqlite-amalgamation-3.5.9.tar.gz | tar -xf -
   fi
Index: /main/trunk/greenstone2/configure
===================================================================
--- /main/trunk/greenstone2/configure	(revision 21408)
+++ /main/trunk/greenstone2/configure	(revision 21409)
@@ -312,5 +312,5 @@
 ac_subdirs_all="$ac_subdirs_all build-src"
 ac_subdirs_all="$ac_subdirs_all runtime-src"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE VERSION USE_FASTCGI USE_LANGACTION USE_CORBA MICO_DIR USE_Z3950 USE_YAZ ENABLE_ACCENTFOLD USE_SQLITE USE_APACHE_HTTPD ENABLE_JNI ENABLE_MG ENABLE_MGPP ENABLE_LUCENE LDFLAGS CFLAGS CC CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX AWK YACC build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SET_MAKE RANLIB ac_ct_RANLIB COMPAT32BITFLAGS MICO_VER CPP EGREP U ANSI2KNR ALLOCA LIBOBJS STATIC gsdlos MODULEDIRS subdirs LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE VERSION USE_FASTCGI USE_LANGACTION USE_CORBA MICO_DIR USE_Z3950 USE_YAZ ENABLE_ACCENTFOLD USE_JDBM USE_SQLITE USE_APACHE_HTTPD ENABLE_JNI ENABLE_MG ENABLE_MGPP ENABLE_LUCENE LDFLAGS CFLAGS CC CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX AWK YACC build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SET_MAKE RANLIB ac_ct_RANLIB COMPAT32BITFLAGS MICO_VER CPP EGREP U ANSI2KNR ALLOCA LIBOBJS STATIC gsdlos MODULEDIRS subdirs LTLIBOBJS'
 ac_subst_files=''
 
@@ -860,4 +860,5 @@
   --disable-yaz           Disable YAZ compilation
   --disable-accentfold    Disable Accent Folding for MGPP
+  --disable-jdbm        Disable JDBM support
   --disable-sqlite        Disable SQLite support
   --enable-apache-httpd  Enable Apache httpd support
@@ -1426,4 +1427,17 @@
 
 
+# Check whether --enable-jdbm or --disable-jdbm was given.
+if test "${enable_jdbm+set}" = set; then
+  enableval="$enable_jdbm"
+  USE_JDBM=0
+else
+  USE_JDBM=1
+fi;
+cat >>confdefs.h <<\_ACEOF
+#define USE_JDBM $USE_JDBM
+_ACEOF
+
+
+
 # Check whether --enable-sqlite or --disable-sqlite was given.
 if test "${enable_sqlite+set}" = set; then
@@ -7952,4 +7966,5 @@
 s,@USE_YAZ@,$USE_YAZ,;t t
 s,@ENABLE_ACCENTFOLD@,$ENABLE_ACCENTFOLD,;t t
+s,@USE_JDBM@,$USE_JDBM,;t t
 s,@USE_SQLITE@,$USE_SQLITE,;t t
 s,@USE_APACHE_HTTPD@,$USE_APACHE_HTTPD,;t t
Index: /main/trunk/greenstone2/configure.in
===================================================================
--- /main/trunk/greenstone2/configure.in	(revision 21408)
+++ /main/trunk/greenstone2/configure.in	(revision 21409)
@@ -66,4 +66,11 @@
 AC_DEFINE(ENABLE_ACCENTFOLD, $ENABLE_ACCENTFOLD)
 AC_SUBST(ENABLE_ACCENTFOLD)
+
+dnl
+dnl Set use of JDBM (enabled by default)
+dnl
+AC_ARG_ENABLE(jdbm, [  --disable-jdbm        Disable JDBM support], USE_JDBM=0, USE_JDBM=1)
+AC_DEFINE(USE_JDBM, $USE_JDBM)
+AC_SUBST(USE_JDBM)
 
 dnl
