Small. Fast. Reliable.
Choose any three.

About Sitemap Documentation Download License News Developers Support

## SQLite Is Self-Contained

SQLite is largely self-contained. It requires very minimal support from external libraries or from the operating system. This makes it well suited for use in embedded devices that lack the support infrastructure of a desktop computer. This also makes SQLite appropriate for use within applications that need to run without modification on a wide variety of computers of varying configurations.

SQLite is written in ANSI-C and should be easily compiled by any standard C compiler. It makes minimal use of the standard C library. The only required C library functions called are:

- memset()
- memcpy()
- memcmp()
- strcmp()
- malloc(), free(), and realloc()

SQLite can be configured at compile-time to use a static buffer in place of calling malloc for the memory it needs. The date and time SQL functions provided by SQLite require some additional C library support, but those functions can be also be omitted from the build using compile-time options.

Communications between SQLite and the operating system and disk are mediated through an interchangable Virtual File System (VFS) layer. VFS modules for Unix (linux and MacOSX), OS/2, Win32, and WinCE are provided in the source tree. It is a simple matter to devise an alternative VFS for embedded devices.

The SQLite source code is available as an "amalgamation" - a single large C source code file. Projects that want to include SQLite can do so simply by dropping this one source file (named "sqlite3.c") and its corresponding header ("sqlite3.h") into their source tree and compiling it together with the rest of the code. SQLite does not link against any external libraries (other than the C library, as described above) and does not require any special build support.

This page last modified 2008/03/03 13:41:48 UTC