Micha Kalfon 6f9075d511 Compile internal SQLite library with -ffunction-sections
When building with SQLITECPP_INTERNAL_SQLITE=ON the SQLite amalgamation
source is used for generating the library. Using one big source file
means all the library code will be put in a single section. When
building statically linked executables the entire section will be
linked even if a small portion of the library is actually used.

This commit addresses this issue by setting the -ffunction-sections
compiler option when building the library. As each function is placed in
a section of its own the linker, when passed the --gc-sections, will
throw away unused sections (functions) and reduce the executable size.
2020-08-23 13:05:25 +03:00
..

sqlite3

"sqlite3.c" and "sqlite3.h" files from sqlite-amalgamation-3300100.zip (SQLite 3.30.1 2019-10-10)

Those files are provided for easy setup and compatibility under Windows/Linux/MacOS. They are used by default by the CMake build.

Use -DSQLITECPP_INTERNAL_SQLITE=OFF to link against the Linux "libsqlite3-dev" package instead.

License:

All of the code and documentation in SQLite has been dedicated to the public domain by the authors.