db3 - Database library and utilities ChangeLog


# Berkeley db3 3.3.11
# ===================
# Different versions of Slackware include db1, db2, db3, and db4 packages.
# Just listing 3.x versions - Slackware 9.0 and 9.1 include 3.3.11, 10.0,
# 10.1, and 10.2 include both 3.1.17 and 3.3.11  Slackware 11.0 includes
# 4.x versions.

# See the db4 howto for the current version

test -f installed/db-3.3.11.tar.gz && mv installed/db-3.3.11.tar.gz .
test ! -f db-3.3.11.tar.gz &&
wget http://www.sleepycat.com/update/snapshot/db-3.3.11.tar.gz
mkdir -p -m 0700 src
cd src
find -maxdepth 1 -type d -name "db-*" -exec rm -r {} \;
tar xzvf ~/db-3.3.11.tar.gz
cd db-3.3.11
test $UID = 0 && chown -R root:root .

# Apply two patches to fix some bugs:
wget -nc http://www.sleepycat.com/update/3.3.11/patch. \
test -f patch. && patch -p0 < patch.
test -f patch. && patch -p0 < patch.

cd build_unix

# If you want an exact replacement for the Slackware installed db3, add
# --prefix=/usr to the configure line, otherwise it'll be installed to
# /usr/local/BerkeleyDB.3.3 (which might be better to avoid conflicts).  If
# you do use --prefix=/usr, you should run "removepkg db3" before you run
# "make install" below.

../dist/configure \
--enable-compat185 \
--enable-rpc \
su -c "make install"
mkdir -p -m 0700 installed
mv db-3.3.11.tar.gz installed/

# If you installed it with the default prefix (/usr/local/BerkeleyDB.3.3) and
# are installing it for everything to use from now on (instead of a
# libdb1/2/3/4 in /usr) you'll probably need to do something like this below.
# Be careful though of anything you have that uses a different version of the
# libdb shared libraries and make sure it still works.  ie. if you're upgrading
# from db2 to db3 and libdb2.so no longer exists, any apps linked to it will be
# broken.  If you're replacing a Slackware-installed db3 and want to remove
# the old version, run "removepkg db3".

# Become root

# Clear out and back up potentially conflicting files:
mkdir -p ~/backup/db3
test -d /usr/include/db3 && mv -f /usr/include/db3 ~/backup/db3/
test -f /usr/lib/libdb.a && mv -f /usr/lib/libdb.a ~/backup/db3/
find /lib -type f -name "libdb-3*.so" -exec mv -f {} ~/backup/db3/ \;
find /usr/bin -type f -name "db_*" -exec mv -f {} ~/backup/db3/ \;
test -L /usr/include/db.h && rm /usr/include/db.h
test ! -L /usr/include/db.h && mv /usr/include/db.h ~/backup/db3/

# Get the new db3 noticed:
ln -sf /usr/local/BerkeleyDB.3.3/include/db.h /usr/include/db.h
ln -sf /usr/local/BerkeleyDB.3.3/lib/libdb.a /usr/lib/libdb.a
echo '#!/bin/sh' > /etc/profile.d/db3.sh
echo 'export PATH=$PATH:/usr/local/BerkeleyDB.3.3/bin' >> /etc/profile.d/db3.sh
chmod 755 /etc/profile.d/db3.sh
echo $PATH | grep "/usr/local/BerkeleyDB.3.3/bin" > /dev/null 2>&1 ||
export PATH=$PATH:/usr/local/BerkeleyDB.3.3/bin
grep "^/usr/local/BerkeleyDB.3.3/lib$" /etc/ld.so.conf > /dev/null 2>&1 ||
echo "/usr/local/BerkeleyDB.3.3/lib" >> /etc/ld.so.conf &&

# Become yourself again

# Even after doing everything above, you still may need to pass configure
# options to certain apps when building to get it to find the includes.
# Unless there's a configure option like --with-db3-includes, use something
# like this to pass the include directory to configure:
# CPPFLAGS="-I/usr/local/BerkeleyDB.3.3/include" ./configure

List of HOWTOs

Web page itself last updated: 2023-09-26 1:12am (EST -0500)
HOWTO last updated: 2007-06-22 6:06pm
Copyright © 2001-2023 Jason Englander. All Rights reserved.