conf.html   [plain text]


<!--$Id: conf.so,v 10.68 2008/01/28 23:59:31 sarette Exp $-->
<!--Copyright (c) 1997,2008 Oracle.  All rights reserved.-->
<!--See the file LICENSE for redistribution information.-->
<html>
<head>
<title>Berkeley DB Reference Guide: Configuring Berkeley DB</title>
<meta name="description" content="Berkeley DB: An embedded database programmatic toolkit.">
<meta name="keywords" content="embedded,database,programmatic,toolkit,btree,hash,hashing,transaction,transactions,locking,logging,access method,access methods,Java,C,C++">
</head>
<body bgcolor=white>
<a name="2"><!--meow--></a><a name="3"><!--meow--></a>
<table width="100%"><tr valign=top>
<td><b><dl><dt>Berkeley DB Reference Guide:<dd>Building Berkeley DB for UNIX/POSIX systems</dl></b></td>
<td align=right><a href="../build_unix/intro.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../toc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../build_unix/small.html"><img src="../../images/next.gif" alt="Next"></a>
</td></tr></table>
<p align=center><b>Configuring Berkeley DB</b></p>
<p>There are several arguments you can specify when configuring Berkeley DB.
Although only the Berkeley DB-specific ones are described here, most of the
standard GNU autoconf arguments are available and supported.  To see a
complete list of possible arguments, specify the --help flag to the
configure program.</p>
<p>The Berkeley DB specific arguments are as follows:</p>
<br>
<a name="4"><!--meow--></a>
<b><a name="--disable-largefile">--disable-largefile</a></b><ul compact><li>Some systems, notably versions of HP/UX and Solaris, require special
compile-time options in order to create files larger than 2^32 bytes.
These options are automatically enabled when Berkeley DB is compiled.  For
this reason, binaries built on current versions of these systems may
not run on earlier versions of the system because the library and system
calls necessary for large files are not available.  To disable building
with these compile-time options, enter --disable-largefile as an argument
to configure.</ul>
<a name="5"><!--meow--></a><a name="6"><!--meow--></a>
<b><a name="--disable-shared">--disable-shared</a>, <a name="--disable-static">--disable-static</a></b><ul compact><li>On systems supporting shared libraries, Berkeley DB builds both static and
shared libraries by default.  (Shared libraries are built using
<a href="http://www.gnu.org/software/libtool/libtool.html">the GNU
Project's Libtool</a> distribution, which supports shared library builds
on many (although not all) systems.)  To not build shared libraries,
configure using the --disable-shared argument.  To not build static
libraries, configure using the --disable-static argument.</ul>
<a name="7"><!--meow--></a>
<b><a name="--enable-compat185">--enable-compat185</a></b><ul compact><li>To compile or load Berkeley DB 1.85 applications against this release of the
Berkeley DB library, enter --enable-compat185 as an argument to configure.
This will include Berkeley DB 1.85 API compatibility code in the library.</ul>
<a name="8"><!--meow--></a>
<b><a name="--enable-cxx">--enable-cxx</a></b><ul compact><li>To build the Berkeley DB C++ API, enter --enable-cxx as an argument to
configure.</ul>
<b><a name="--enable-debug">--enable-debug</a></b><ul compact><li>To build Berkeley DB with <b>-g</b> as a compiler flag and with
<b>DEBUG</b> #defined during compilation, enter --enable-debug as an
argument to configure.  This will create a Berkeley DB library and utilities
with debugging symbols, as well as load various routines that can be
called from a debugger to display pages, cursor queues, and so forth.
If installed, the utilities will not be stripped.  This argument should
not be specified when configuring to build production binaries.</ul>
<b><a name="--enable-debug_rop">--enable-debug_rop</a></b><ul compact><li>To build Berkeley DB to output log records for read operations, enter
--enable-debug_rop as an argument to configure.  This argument should not
be specified when configuring to build production binaries.</ul>
<b><a name="--enable-debug_wop">--enable-debug_wop</a></b><ul compact><li>To build Berkeley DB to output log records for write operations, enter
--enable-debug_wop as an argument to configure.  This argument should not
be specified when configuring to build production binaries.</ul>
<b><a name="--enable-diagnostic">--enable-diagnostic</a></b><ul compact><li>To build Berkeley DB with run-time debugging checks, enter --enable-diagnostic
as an argument to configure.  This causes a number of additional checks
to be performed when Berkeley DB is running, and also causes some failures to
trigger process abort rather than returning errors to the application.
Applications built using this argument should not share database
environments with applications built without this argument.  This
argument should not be specified when configuring to build production
binaries.</ul>
<a name="9"><!--meow--></a>
<b><a name="--enable-dump185">--enable-dump185</a></b><ul compact><li>To convert Berkeley DB 1.85 (or earlier) databases to this release of Berkeley DB,
enter --enable-dump185 as an argument to configure.  This will build the
<a href="../../utility/db_dump.html">db_dump185</a> utility, which can dump Berkeley DB 1.85 and 1.86 databases
in a format readable by the Berkeley DB <a href="../../utility/db_load.html">db_load</a> utility.
<p>The system libraries with which you are loading the <a href="../../utility/db_dump.html">db_dump185</a>
utility must already contain the Berkeley DB 1.85 library routines for this
to work because the Berkeley DB distribution does not include them.  If you
are using a non-standard library for the Berkeley DB 1.85 library routines,
you will have to change the Makefile that the configuration step creates
to load the <a href="../../utility/db_dump.html">db_dump185</a> utility with that library.</p></ul>
<a name="10"><!--meow--></a>
<b><a name="--enable-java">--enable-java</a></b><ul compact><li>To build the Berkeley DB Java API, enter --enable-java as an argument to
configure. To build Java, you must also build with shared libraries.
Before configuring, you must set your PATH environment variable to
include javac.  Note that it is not sufficient to include a symbolic
link to javac in your PATH because the configuration process uses the
location of javac to determine the location of the Java include files
(for example, jni.h). On some systems, additional include directories
may be needed to process jni.h; see <a href="flags.html">Changing compile or
load options</a> for more information.</ul>
<b><a name="--enable-posixmutexes">--enable-posixmutexes</a></b><ul compact><li>To force Berkeley DB to use the POSIX pthread mutex interfaces for underlying
mutex support, enter --enable-posixmutexes as an argument to configure.
This is rarely necessary: POSIX mutexes will be selected automatically
on systems where they are the preferred implementation.
<p>The --enable-posixmutexes configuration argument is normally used in
two ways: First, when there are multiple mutex implementations available
and the POSIX mutex implementation is not the preferred one (for
example, on Solaris where the LWP mutexes are used by default).  Second,
by default the Berkeley DB library will only select the POSIX mutex
implementation if it supports mutexes shared between multiple processes,
as described for the pthread_condattr_setpshared and
pthread_mutexattr_setpshared interfaces.  The --enable-posixmutexes
configuration argument can be used to force the selection of POSIX
mutexes in this case, which can improve application performance
significantly when the alternative mutex implementation is a
non-blocking one (for example test-and-set assembly instructions).
However, configuring to use POSIX mutexes when the implementation does
not have inter-process support will only allow the creation of private
database environments, that is, environments where the
<a href="../../api_c/env_open.html#DB_PRIVATE">DB_PRIVATE</a> flag is specified to the <a href="../../api_c/env_open.html">DB_ENV-&gt;open</a> method.</p>
<p>Specifying the --enable-posixmutexes configuration argument may require
that applications and Berkeley DB be linked with the -lpthread library.</p></ul>
<b><a name="--enable-pthread_api">--enable-pthread_api</a></b><ul compact><li>To configure Berkeley DB for a POSIX pthreads application (with the exception
that POSIX pthread mutexes may not be selected as the underlying mutex
implementation for the build), enter --enable-pthread_api as an argument
to configure.  The build will include the Berkeley DB replication manager
interfaces and will use the POSIX standard pthread_self and
pthread_yield functions to identify threads of control and yield the
processor.  The --enable-pthread_api argument requires POSIX pthread
support already be installed on your system.
<p>Specifying the --enable-pthread_api configuration argument may require
that applications and Berkeley DB be linked with the -lpthread library.</p></ul>
<a name="11"><!--meow--></a>
<b><a name="--enable-rpc">--enable-rpc</a></b><ul compact><li>To build the Berkeley DB RPC client code and server utility, enter --enable-rpc
as an argument to configure.  The --enable-rpc argument requires that RPC
support already be installed on your system.</ul>
<a name="12"><!--meow--></a>
<b><a name="--enable-smallbuild">--enable-smallbuild</a></b><ul compact><li>To build a small memory footprint version of the Berkeley DB library, enter
--enable-smallbuild as an argument to configure.  The
--enable-smallbuild argument is equivalent to individually specifying
--disable-cryptography, --disable-hash, --disable-queue,
--disable-replication, --disable-statistics and --disable-verify,
turning off cryptography support, the Hash and Queue access methods,
database environment replication support and database verification
support.  See <a href="../../ref/build_unix/small.html">Building a
small memory footprint library</a> for more information.</ul>
<a name="13"><!--meow--></a>
<b><a name="--enable-tcl">--enable-tcl</a></b><ul compact><li>To build the Berkeley DB Tcl API, enter --enable-tcl as an argument to
configure.  This configuration argument expects to find Tcl's tclConfig.sh
file in the <b>/usr/local/lib</b> directory.  See the --with-tcl
argument for instructions on specifying a non-standard location for the
Tcl installation.  See <a href="../../ref/tcl/intro.html">Loading Berkeley DB
with Tcl</a> for information on sites from which you can download Tcl and
which Tcl versions are compatible with Berkeley DB.  To build Tcl, you must
also build with shared libraries.</ul>
<a name="14"><!--meow--></a>
<b><a name="--enable-test">--enable-test</a></b><ul compact><li>To build the Berkeley DB test suite, enter --enable-test as an argument to
configure.  To run the Berkeley DB test suite, you must also build the Tcl
API.  This argument should not be specified when configuring to build
production binaries.</ul>
<b><a name="--enable-uimutexes">--enable-uimutexes</a></b><ul compact><li>To force Berkeley DB to use the UNIX International (UI) mutex interfaces for
underlying mutex support, enter --enable-uimutexes as an argument to
configure.  This is rarely necessary: UI mutexes will be selected
automatically on systems where they are the preferred implementation.
<p>The --enable-uimutexes configuration argument is normally used when
there are multiple mutex implementations available and the UI mutex
implementation is not the preferred one (for example, on Solaris where
the LWP mutexes are used by default).</p>
<p>Specifying the --enable-uimutexes configuration argument may require
that applications and Berkeley DB be linked with the -lthread library.</p></ul>
<b><a name="--enable-umrw">--enable-umrw</a></b><ul compact><li>Rational Software's Purify product and other run-time tools complain
about uninitialized reads/writes of structure fields whose only purpose
is padding, as well as when heap memory that was never initialized is
written to disk.  Specify the --enable-umrw argument during
configuration to mask these errors.  This argument should not be
specified when configuring to build production binaries.</ul>
<b><a name="--with-mutex=MUTEX">--with-mutex=MUTEX</a></b><ul compact><li>To force Berkeley DB to use a specific mutex implementation, configure with
--with-mutex=MUTEX, where MUTEX is the mutex implementation you want.
For example, --with-mutex=x86/gcc-assembly will configure Berkeley DB to use
the x86 GNU gcc compiler based test-and-set assembly mutexes.  This is
rarely necessary and should be done only when the default configuration
selects the wrong mutex implementation.  A list of available mutex
implementations can be found in the distribution file
<b>dist/aclocal/mutex.m4</b>.</ul>
<b><a name="--with-tcl=DIR">--with-tcl=DIR</a></b><ul compact><li>To build the Berkeley DB Tcl API, enter --with-tcl=DIR, replacing DIR with
the directory in which the Tcl tclConfig.sh file may be found.  See
<a href="../../ref/tcl/intro.html">Loading Berkeley DB with Tcl</a> for information
on sites from which you can download Tcl and which Tcl versions are
compatible with Berkeley DB.  To build Tcl, you must also build with shared
libraries.</ul>
<b><a name="--with-uniquename=NAME">--with-uniquename=NAME</a></b><ul compact><li>To build Berkeley DB with unique symbol names (in order to avoid conflicts
with other application modules or libraries), enter --with-uniquename=NAME,
replacing NAME with a string that to be appended to every Berkeley DB symbol.
If "=NAME" is not specified, a default value of "_MAJORMINOR" is used,
where MAJORMINOR is the major and minor release numbers of the Berkeley DB
release.  See <a href="../../ref/install/multiple.html">Building with
multiple versions of Berkeley DB</a> for more information.</ul>
<br>
<table width="100%"><tr><td><br></td><td align=right><a href="../build_unix/intro.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../toc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../build_unix/small.html"><img src="../../images/next.gif" alt="Next"></a>
</td></tr></table>
<p><font size=1>Copyright (c) 1996,2008 Oracle.  All rights reserved.</font>
</body>
</html>