summaryrefslogtreecommitdiff
path: root/source/l/db42
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2009-08-26 10:00:38 -0500
committerEric Hameleers <alien@slackware.com>2018-05-31 22:41:17 +0200
commit5a12e7c134274dba706667107d10d231517d3e05 (patch)
tree55718d5acb710fde798d9f38d0bbaf594ed4b296 /source/l/db42
downloadcurrent-5a12e7c134274dba706667107d10d231517d3e05.tar.gz
Slackware 13.0slackware-13.0
Wed Aug 26 10:00:38 CDT 2009 Slackware 13.0 x86_64 is released as stable! Thanks to everyone who helped make this release possible -- see the RELEASE_NOTES for the credits. The ISOs are off to the replicator. This time it will be a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. We're taking pre-orders now at store.slackware.com. Please consider picking up a copy to help support the project. Once again, thanks to the entire Slackware community for all the help testing and fixing things and offering suggestions during this development cycle. As always, have fun and enjoy! -P.
Diffstat (limited to 'source/l/db42')
-rwxr-xr-xsource/l/db42/db42.SlackBuild140
-rw-r--r--source/l/db42/patch.4.2.52.136
-rw-r--r--source/l/db42/patch.4.2.52.245
-rw-r--r--source/l/db42/patch.4.2.52.3247
-rw-r--r--source/l/db42/patch.4.2.52.436
-rw-r--r--source/l/db42/slack-desc19
6 files changed, 523 insertions, 0 deletions
diff --git a/source/l/db42/db42.SlackBuild b/source/l/db42/db42.SlackBuild
new file mode 100755
index 00000000..21f5a50a
--- /dev/null
+++ b/source/l/db42/db42.SlackBuild
@@ -0,0 +1,140 @@
+#!/bin/sh
+
+# Copyright 2008, 2009 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+VERSION=4.2.52
+ARCH=${ARCH:-x86_64}
+BUILD=${BUILD:-3}
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp}
+PKG=$TMP/package-db42
+rm -rf $PKG
+mkdir -p $TMP $PKG
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+ CONFIGURE_ARGS=""
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+ CONFIGURE_ARGS=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+ # Needed as a workaround for:
+ # "architecture lacks fast mutexes: applications cannot be threaded"
+ CONFIGURE_ARGS="--with-mutex=x86/gcc-assembly"
+fi
+
+cd $TMP
+rm -rf db-$VERSION
+tar xjvf $CWD/db-$VERSION.tar.bz2
+cd db-$VERSION
+zcat $CWD/patch.4.2.52.1.gz | patch -p0 --verbose || exit 1
+zcat $CWD/patch.4.2.52.2.gz | patch -p0 --verbose || exit 1
+zcat $CWD/patch.4.2.52.3.gz | patch -p0 --verbose || exit 1
+zcat $CWD/patch.4.2.52.4.gz | patch -p0 --verbose || exit 1
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+rm -rf build-dir
+mkdir build-dir
+cd build-dir
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+../dist/configure \
+ --prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --enable-shared \
+ --enable-rpc \
+ --enable-compat185 \
+ $CONFIGURE_ARGS \
+ $ARCH-slackware-linux
+make -j3
+make install DESTDIR=$PKG
+( cd $PKG
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+)
+# Remove WAY TOO LARGE (and misplaced) docs:
+rm -rf $PKG/usr/docs
+mkdir -p $PKG/usr/doc/db-$VERSION
+cp -a \
+ ../LICENSE ../README \
+ $PKG/usr/doc/db-$VERSION
+cat << EOF > $PKG/usr/doc/db-$VERSION/README-DOCS
+
+ For a ton of additional documentation (too large to include
+ here) on writing source code that uses libdb42, please see
+ the source tarball db-$VERSION.tar.bz2, which can be found
+ in the Slackware source tree in source/l/db42/, or on
+ Sleepycat's web site: http://www.sleepycat.com.
+
+EOF
+
+# Put libdb-4.2.so into /lib${LIBDIRSUFFIX} since it might be needed
+# before /usr is mounted.
+mkdir -p $PKG/lib${LIBDIRSUFFIX}
+mv $PKG/usr/lib${LIBDIRSUFFIX}/libdb-4.2.so $PKG/lib${LIBDIRSUFFIX}/libdb-4.2.so
+( cd $PKG/usr/lib${LIBDIRSUFFIX}
+ ln -sf /lib${LIBDIRSUFFIX}/libdb-4.2.so .
+)
+
+( cd $PKG/usr/include
+ chmod 644 *
+ mkdir db42
+ mv db.h db_185.h db_cxx.h db42
+ # Not any more... db-4.2 is on the way out.
+ #ln -sf db42/db.h .
+ #ln -sf db42/db_185.h .
+ #ln -sf db42/db_cxx.h .
+)
+
+chmod 755 $PKG/usr/bin/*
+
+( cd $PKG/usr/bin
+ mv berkeley_db_svc berkeley_db42_svc
+ for file in db_* ; do
+ mv $file db42_`echo $file | cut -f 2- -d _`
+ done
+)
+
+# Not the default DB version:
+rm -f $PKG/usr/include/{db.h,db_185.h,db_cxx.h}
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/libdb-4.so
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/libdb.{a,so}
+# We will not be linking statically against this, either.
+# If you need to do that, drag up an old package from the Slackware 10.2 era...
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.a
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+makepkg -l y -c n $TMP/db42-$VERSION-$ARCH-$BUILD.txz
+
diff --git a/source/l/db42/patch.4.2.52.1 b/source/l/db42/patch.4.2.52.1
new file mode 100644
index 00000000..474cb875
--- /dev/null
+++ b/source/l/db42/patch.4.2.52.1
@@ -0,0 +1,36 @@
+*** mp/mp_fget.c.orig 25 Sep 2003 02:15:16 -0000 11.81
+--- mp/mp_fget.c 9 Dec 2003 19:06:28 -0000 11.82
+***************
+*** 440,446 ****
+ c_mp->stat.st_pages--;
+ alloc_bhp = NULL;
+ R_UNLOCK(dbenv, &dbmp->reginfo[n_cache]);
+- MUTEX_LOCK(dbenv, &hp->hash_mutex);
+
+ /*
+ * We can't use the page we found in the pool if DB_MPOOL_NEW
+--- 440,445 ----
+***************
+*** 455,460 ****
+--- 454,462 ----
+ b_incr = 0;
+ goto alloc;
+ }
++
++ /* We can use the page -- get the bucket lock. */
++ MUTEX_LOCK(dbenv, &hp->hash_mutex);
+ break;
+ case SECOND_MISS:
+ /*
+*** mp/mp_fput.c.orig 30 Sep 2003 17:12:00 -0000 11.48
+--- mp/mp_fput.c 13 Dec 2003 00:08:29 -0000 11.49
+***************
+*** 285,290 ****
+--- 285,291 ----
+ bhp != NULL; bhp = SH_TAILQ_NEXT(bhp, hq, __bh))
+ if (bhp->priority != UINT32_T_MAX &&
+ bhp->priority > MPOOL_BASE_DECREMENT)
++ bhp->priority -= MPOOL_BASE_DECREMENT;
+ MUTEX_UNLOCK(dbenv, &hp->hash_mutex);
+ }
+ }
diff --git a/source/l/db42/patch.4.2.52.2 b/source/l/db42/patch.4.2.52.2
new file mode 100644
index 00000000..3dc13c17
--- /dev/null
+++ b/source/l/db42/patch.4.2.52.2
@@ -0,0 +1,45 @@
+*** lock/lock.c.save 2004-01-30 10:48:33.000000000 -0800
+--- lock/lock.c 2004-01-30 10:55:58.000000000 -0800
+***************
+*** 2216,2226 ****
+ dp = (u_int8_t *)dp + \
+ sizeof(db_pgno_t); \
+ } while (0)
+! #define COPY_OBJ(dp, obj) do { \
+! memcpy(dp, obj->data, obj->size); \
+! dp = (u_int8_t *)dp + \
+! ALIGN(obj->size, \
+! sizeof(u_int32_t)); \
+ } while (0)
+
+ #define GET_COUNT(dp, count) do { \
+--- 2216,2227 ----
+ dp = (u_int8_t *)dp + \
+ sizeof(db_pgno_t); \
+ } while (0)
+! #define COPY_OBJ(dp, obj) do { \
+! memcpy(dp, \
+! (obj)->data, (obj)->size); \
+! dp = (u_int8_t *)dp + \
+! ALIGN((obj)->size, \
+! sizeof(u_int32_t)); \
+ } while (0)
+
+ #define GET_COUNT(dp, count) do { \
+***************
+*** 2339,2345 ****
+ for (i = 0; i < nlocks; i = j) {
+ PUT_PCOUNT(dp, obj[i].ulen);
+ PUT_SIZE(dp, obj[i].size);
+! COPY_OBJ(dp, obj);
+ lock = (DB_LOCK_ILOCK *)obj[i].data;
+ for (j = i + 1; j <= i + obj[i].ulen; j++) {
+ lock = (DB_LOCK_ILOCK *)obj[j].data;
+--- 2340,2346 ----
+ for (i = 0; i < nlocks; i = j) {
+ PUT_PCOUNT(dp, obj[i].ulen);
+ PUT_SIZE(dp, obj[i].size);
+! COPY_OBJ(dp, &obj[i]);
+ lock = (DB_LOCK_ILOCK *)obj[i].data;
+ for (j = i + 1; j <= i + obj[i].ulen; j++) {
+ lock = (DB_LOCK_ILOCK *)obj[j].data;
diff --git a/source/l/db42/patch.4.2.52.3 b/source/l/db42/patch.4.2.52.3
new file mode 100644
index 00000000..9e82423c
--- /dev/null
+++ b/source/l/db42/patch.4.2.52.3
@@ -0,0 +1,247 @@
+--- java/src/com/sleepycat/db/DbEnv.java 2003-12-03 16:26:27.000000000 -0500
++++ java/src/com/sleepycat/db/DbEnv.java 2004-03-18 15:15:42.000000000 -0500
+@@ -61,7 +61,7 @@
+ // Internally, the JNI layer creates a global reference to each DbEnv,
+ // which can potentially be different to this. We keep a copy here so
+ // we can clean up after destructors.
+- private Object dbenv_ref;
++ private long dbenv_ref;
+ private DbAppDispatch app_dispatch_handler;
+ private DbEnvFeedbackHandler env_feedback_handler;
+ private DbErrorHandler error_handler;
+@@ -94,7 +94,7 @@
+ void cleanup() {
+ swigCPtr = 0;
+ db_java.deleteRef0(dbenv_ref);
+- dbenv_ref = null;
++ dbenv_ref = 0L;
+ }
+
+
+--- java/src/com/sleepycat/db/Db.java 2003-12-03 16:26:25.000000000 -0500
++++ java/src/com/sleepycat/db/Db.java 2004-03-18 15:15:55.000000000 -0500
+@@ -57,7 +57,7 @@
+ // Internally, the JNI layer creates a global reference to each Db,
+ // which can potentially be different to this. We keep a copy here so
+ // we can clean up after destructors.
+- private Object db_ref;
++ private long db_ref;
+ private DbEnv dbenv;
+ private boolean private_dbenv;
+ private DbAppendRecno append_recno_handler;
+@@ -84,7 +84,7 @@
+ private void cleanup() {
+ swigCPtr = 0;
+ db_java.deleteRef0(db_ref);
+- db_ref = null;
++ db_ref = 0L;
+ if (private_dbenv) {
+ dbenv.cleanup();
+ }
+--- java/src/com/sleepycat/db/db_java.java 2003-12-03 16:10:54.000000000 -0500
++++ java/src/com/sleepycat/db/db_java.java 2004-03-18 15:17:24.000000000 -0500
+@@ -14,15 +14,15 @@
+ db_javaJNI.DbEnv_lock_vec(DbEnv.getCPtr(dbenv), locker, flags, list, offset, nlist);
+ }
+
+- static Object initDbEnvRef0(DbEnv self, Object handle) {
++ static long initDbEnvRef0(DbEnv self, Object handle) {
+ return db_javaJNI.initDbEnvRef0(DbEnv.getCPtr(self), handle);
+ }
+
+- static Object initDbRef0(Db self, Object handle) {
++ static long initDbRef0(Db self, Object handle) {
+ return db_javaJNI.initDbRef0(Db.getCPtr(self), handle);
+ }
+
+- static void deleteRef0(Object ref) {
++ static void deleteRef0(long ref) {
+ db_javaJNI.deleteRef0(ref);
+ }
+
+--- java/src/com/sleepycat/db/db_javaJNI.java 2003-12-03 16:10:55.000000000 -0500
++++ java/src/com/sleepycat/db/db_javaJNI.java 2004-03-18 15:16:18.000000000 -0500
+@@ -45,9 +45,9 @@
+ static native final void initialize();
+
+ public final static native void DbEnv_lock_vec(long jarg1, int jarg2, int jarg3, DbLockRequest[] jarg4, int jarg5, int jarg6) throws DbException;
+- final static native Object initDbEnvRef0(long jarg1, Object jarg2);
+- final static native Object initDbRef0(long jarg1, Object jarg2);
+- final static native void deleteRef0(Object jarg1);
++ final static native long initDbEnvRef0(long jarg1, Object jarg2);
++ final static native long initDbRef0(long jarg1, Object jarg2);
++ final static native void deleteRef0(long jarg1);
+ final static native long getDbEnv0(long jarg1);
+ public final static native long new_Db(long jarg1, int jarg2) throws DbException;
+ public final static native void Db_associate(long jarg1, long jarg2, long jarg3, DbSecondaryKeyCreate jarg4, int jarg5) throws DbException;
+--- libdb_java/db_java.i 2003-11-17 15:00:52.000000000 -0500
++++ libdb_java/db_java.i 2004-03-18 09:21:14.000000000 -0500
+@@ -53,7 +53,7 @@
+ // Internally, the JNI layer creates a global reference to each DbEnv,
+ // which can potentially be different to this. We keep a copy here so
+ // we can clean up after destructors.
+- private Object dbenv_ref;
++ private long dbenv_ref;
+ private DbAppDispatch app_dispatch_handler;
+ private DbEnvFeedbackHandler env_feedback_handler;
+ private DbErrorHandler error_handler;
+@@ -76,7 +76,7 @@
+ void cleanup() {
+ swigCPtr = 0;
+ db_java.deleteRef0(dbenv_ref);
+- dbenv_ref = null;
++ dbenv_ref = 0L;
+ }
+
+ public synchronized void close(int flags) throws DbException {
+@@ -220,7 +220,7 @@
+ // Internally, the JNI layer creates a global reference to each Db,
+ // which can potentially be different to this. We keep a copy here so
+ // we can clean up after destructors.
+- private Object db_ref;
++ private long db_ref;
+ private DbEnv dbenv;
+ private boolean private_dbenv;
+ private DbAppendRecno append_recno_handler;
+@@ -245,7 +245,7 @@
+ private void cleanup() {
+ swigCPtr = 0;
+ db_java.deleteRef0(db_ref);
+- db_ref = null;
++ db_ref = 0L;
+ if (private_dbenv)
+ dbenv.cleanup();
+ dbenv = null;
+@@ -503,46 +503,42 @@
+ }
+ %}
+
+-%native(initDbEnvRef0) jobject initDbEnvRef0(DB_ENV *self, void *handle);
+-%native(initDbRef0) jobject initDbRef0(DB *self, void *handle);
+-%native(deleteRef0) void deleteRef0(jobject ref);
++%native(initDbEnvRef0) jlong initDbEnvRef0(DB_ENV *self, void *handle);
++%native(initDbRef0) jlong initDbRef0(DB *self, void *handle);
++%native(deleteRef0) void deleteRef0(jlong ref);
+ %native(getDbEnv0) DB_ENV *getDbEnv0(DB *self);
+
+ %{
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbEnvRef0(
++JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbEnvRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg2) {
+ DB_ENV *self = *(DB_ENV **)&jarg1;
++ jlong ret;
+ COMPQUIET(jcls, NULL);
+
+ DB_ENV_INTERNAL(self) = (void *)(*jenv)->NewGlobalRef(jenv, jarg2);
+ self->set_errpfx(self, (const char*)self);
+- return (jobject)DB_ENV_INTERNAL(self);
++ *(jobject *)&ret = (jobject)DB_ENV_INTERNAL(self);
++ return (ret);
+ }
+
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbRef0(
++JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg2) {
+ DB *self = *(DB **)&jarg1;
++ jlong ret;
+ COMPQUIET(jcls, NULL);
+
+ DB_INTERNAL(self) = (void *)(*jenv)->NewGlobalRef(jenv, jarg2);
+- return (jobject)DB_INTERNAL(self);
++ *(jobject *)&ret = (jobject)DB_INTERNAL(self);
++ return (ret);
+ }
+
+ JNIEXPORT void JNICALL Java_com_sleepycat_db_db_1javaJNI_deleteRef0(
+- JNIEnv *jenv, jclass jcls, jobject jref) {
+- COMPQUIET(jcls, NULL);
+-
+- if (jref != NULL)
+- (*jenv)->DeleteGlobalRef(jenv, jref);
+-}
+-
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_getDbRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1) {
+- DB *self = *(DB **)&jarg1;
++ jobject jref = *(jobject *)&jarg1;
+ COMPQUIET(jcls, NULL);
+- COMPQUIET(jenv, NULL);
+
+- return (jobject)DB_INTERNAL(self);
++ if (jref != 0L)
++ (*jenv)->DeleteGlobalRef(jenv, jref);
+ }
+
+ JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_getDbEnv0(
+@@ -554,7 +550,7 @@
+ COMPQUIET(jcls, NULL);
+
+ *(DB_ENV **)&env_cptr = self->dbenv;
+- return env_cptr;
++ return (env_cptr);
+ }
+
+ JNIEXPORT jboolean JNICALL
+--- libdb_java/db_java_wrap.c 2003-12-03 16:10:36.000000000 -0500
++++ libdb_java/db_java_wrap.c 2004-03-18 12:18:58.000000000 -0500
+@@ -1192,40 +1192,36 @@
+ }
+
+
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbEnvRef0(
++JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbEnvRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg2) {
+ DB_ENV *self = *(DB_ENV **)&jarg1;
++ jlong ret;
+ COMPQUIET(jcls, NULL);
+
+ DB_ENV_INTERNAL(self) = (void *)(*jenv)->NewGlobalRef(jenv, jarg2);
+ self->set_errpfx(self, (const char*)self);
+- return (jobject)DB_ENV_INTERNAL(self);
++ *(jobject *)&ret = (jobject)DB_ENV_INTERNAL(self);
++ return (ret);
+ }
+
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbRef0(
++JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_initDbRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg2) {
+ DB *self = *(DB **)&jarg1;
++ jlong ret;
+ COMPQUIET(jcls, NULL);
+
+ DB_INTERNAL(self) = (void *)(*jenv)->NewGlobalRef(jenv, jarg2);
+- return (jobject)DB_INTERNAL(self);
++ *(jobject *)&ret = (jobject)DB_INTERNAL(self);
++ return (ret);
+ }
+
+ JNIEXPORT void JNICALL Java_com_sleepycat_db_db_1javaJNI_deleteRef0(
+- JNIEnv *jenv, jclass jcls, jobject jref) {
+- COMPQUIET(jcls, NULL);
+-
+- if (jref != NULL)
+- (*jenv)->DeleteGlobalRef(jenv, jref);
+-}
+-
+-JNIEXPORT jobject JNICALL Java_com_sleepycat_db_db_1javaJNI_getDbRef0(
+ JNIEnv *jenv, jclass jcls, jlong jarg1) {
+- DB *self = *(DB **)&jarg1;
++ jobject jref = *(jobject *)&jarg1;
+ COMPQUIET(jcls, NULL);
+- COMPQUIET(jenv, NULL);
+
+- return (jobject)DB_INTERNAL(self);
++ if (jref != 0L)
++ (*jenv)->DeleteGlobalRef(jenv, jref);
+ }
+
+ JNIEXPORT jlong JNICALL Java_com_sleepycat_db_db_1javaJNI_getDbEnv0(
+@@ -1237,7 +1233,7 @@
+ COMPQUIET(jcls, NULL);
+
+ *(DB_ENV **)&env_cptr = self->dbenv;
+- return env_cptr;
++ return (env_cptr);
+ }
+
+ JNIEXPORT jboolean JNICALL
diff --git a/source/l/db42/patch.4.2.52.4 b/source/l/db42/patch.4.2.52.4
new file mode 100644
index 00000000..4ba773bb
--- /dev/null
+++ b/source/l/db42/patch.4.2.52.4
@@ -0,0 +1,36 @@
+*** btree/bt_rec.c.orig Tue Mar 22 09:41:49 2005
+--- btree/bt_rec.c Tue Mar 22 09:42:11 2005
+***************
+*** 222,228 ****
+ * previous-page pointer updated to our new page. The next
+ * page must exist because we're redoing the operation.
+ */
+! if (!rootsplit && !IS_ZERO_LSN(argp->nlsn)) {
+ if ((ret =
+ __memp_fget(mpf, &argp->npgno, 0, &np)) != 0) {
+ ret = __db_pgerr(file_dbp, argp->npgno, ret);
+--- 222,228 ----
+ * previous-page pointer updated to our new page. The next
+ * page must exist because we're redoing the operation.
+ */
+! if (!rootsplit && argp->npgno != PGNO_INVALID) {
+ if ((ret =
+ __memp_fget(mpf, &argp->npgno, 0, &np)) != 0) {
+ ret = __db_pgerr(file_dbp, argp->npgno, ret);
+***************
+*** 294,300 ****
+ * possible that the next-page never existed, we ignore it as
+ * if there's nothing to undo.
+ */
+! if (!rootsplit && !IS_ZERO_LSN(argp->nlsn)) {
+ if ((ret =
+ __memp_fget(mpf, &argp->npgno, 0, &np)) != 0) {
+ np = NULL;
+--- 294,300 ----
+ * possible that the next-page never existed, we ignore it as
+ * if there's nothing to undo.
+ */
+! if (!rootsplit && argp->npgno != PGNO_INVALID) {
+ if ((ret =
+ __memp_fget(mpf, &argp->npgno, 0, &np)) != 0) {
+ np = NULL;
diff --git a/source/l/db42/slack-desc b/source/l/db42/slack-desc
new file mode 100644
index 00000000..2e40e09c
--- /dev/null
+++ b/source/l/db42/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|' on
+# the right side marks the last column you can put a character in. You must make
+# exactly 11 lines for the formatting to be correct. It's also customary to
+# leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+db42: db42 (Berkeley database library version 4.2.x)
+db42:
+db42: The Berkeley Database (Berkeley DB) library provides embedded database
+db42: support for both traditional and client/server applications.
+db42:
+db42: This package should be installed if compatibility is needed with
+db42: databases created with the Berkeley DB version 4.2.x.
+db42:
+db42:
+db42:
+db42: