1<!--$Id: small.so,v 10.11 2007/06/13 18:56:05 bostic Exp $-->
2<!--Copyright (c) 1997,2008 Oracle.  All rights reserved.-->
3<!--See the file LICENSE for redistribution information.-->
4<html>
5<head>
6<title>Berkeley DB Reference Guide: Building a small memory footprint library</title>
7<meta name="description" content="Berkeley DB: An embedded database programmatic toolkit.">
8<meta name="keywords" content="embedded,database,programmatic,toolkit,btree,hash,hashing,transaction,transactions,locking,logging,access method,access methods,Java,C,C++">
9</head>
10<body bgcolor=white>
11<table width="100%"><tr valign=top>
12<td><b><dl><dt>Berkeley DB Reference Guide:<dd>Building Berkeley DB for UNIX/POSIX systems</dl></b></td>
13<td align=right><a href="/build_unix/conf.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/flags.html"><img src="/images/next.gif" alt="Next"></a>
14</td></tr></table>
15<p align=center><b>Building a small memory footprint library</b></p>
16<p>There are a set of configuration options to assist you in building a
17small memory footprint library.  These configuration options turn off
18specific functionality in the Berkeley DB library, reducing the code size.
19These configuration options include:</p>
20<br>
21<b><a name="--disable-cryptography">--disable-cryptography</a></b><ul compact><li>To build Berkeley DB without support for cryptography, enter
22--disable-cryptography as an argument to configure.</ul>
23<b><a name="--disable-hash">--disable-hash</a></b><ul compact><li>To build Berkeley DB without support for the Hash access method, enter
24--disable-hash as an argument to configure.</ul>
25<b><a name="--disable-queue">--disable-queue</a></b><ul compact><li>To build Berkeley DB without support for the Queue access method, enter
26--disable-queue as an argument to configure.</ul>
27<b><a name="--disable-replication">--disable-replication</a></b><ul compact><li>To build Berkeley DB without support for the database environment replication,
28enter --disable-replication as an argument to configure.</ul>
29<b><a name="--disable-statistics">--disable-statistics</a></b><ul compact><li>To build Berkeley DB without support for the statistics interfaces, enter
30--disable-statistics as an argument to configure.</ul>
31<b><a name="--disable-verify">--disable-verify</a></b><ul compact><li>To build Berkeley DB without support for database verification, enter
32--disable-verify as an argument to configure.</ul>
33<b><a name="--enable-smallbuild">--enable-smallbuild</a></b><ul compact><li>Equivalent to individually specifying --disable-cryptography,
34--disable-hash, --disable-queue, --disable-replication,
35--disable-statistics and --disable-verify.  In addition, when compiling
36building with the GNU gcc compiler, the --enable-smallbuild option uses
37the -Os compiler build flag instead of the default -O3.</ul>
38<br>
39<p>The following configuration options will increase the size of the Berkeley DB
40library dramatically and are only useful when debugging applications:</p>
41<br>
42<b><a href="/ref/build_unix/conf.html#--enable-debug">--enable-debug</a></b><ul compact><li>Build Berkeley DB with symbols for debugging.</ul>
43<b><a href="/ref/build_unix/conf.html#--enable-debug_rop">--enable-debug_rop</a></b><ul compact><li>Build Berkeley DB with read-operation logging.</ul>
44<b><a href="/ref/build_unix/conf.html#--enable-debug_wop">--enable-debug_wop</a></b><ul compact><li>Build Berkeley DB with write-operation logging.</ul>
45<b><a href="/ref/build_unix/conf.html#--enable-diagnostic">--enable-diagnostic</a></b><ul compact><li>Build Berkeley DB with run-time debugging checks.</ul>
46<br>
47<p>In addition, static libraries are usually smaller than shared libraries.
48By default Berkeley DB will build both shared and static libraries.  To build
49only a static library, configure Berkeley DB with the
50<a href="/ref/build_unix/conf.html">--disable-shared</a> option.</p>
51<p>The size of the Berkeley DB library varies depending on the compiler, machine
52architecture, and configuration options.  As an estimate, production
53Berkeley DB libraries built with GNU gcc version 3.X compilers have footprints
54in the range of 400KB to 900KB on 32-bit x86 architectures, and in the
55range of 500KB to 1MB on 64-bit x86 architectures.</p>
56<p>For assistance in further reducing the size of the Berkeley DB library, or in
57building small memory footprint libraries on other systems, please
58contact Berkeley DB support.</p>
59<table width="100%"><tr><td><br></td><td align=right><a href="/build_unix/conf.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/flags.html"><img src="/images/next.gif" alt="Next"></a>
60</td></tr></table>
61<p><font size=1>Copyright (c) 1996,2008 Oracle.  All rights reserved.</font>
62</body>
63</html>
64