开发者

Minimize SQLite library size

I assume this is the same for sqlite3.dll or sqlite3.lib, but if not, I am interested in sqlite3.o (mingw32).

How can I minimize the size of the library (compiling with -O3, since speed is my top concern, so different compiler optimizations is not an option)?

If I know there are parts of SQL I don't need in my program (like JOIN or ATTACH or triggers), can I remove support for them (this is for an embedded system and every byte counts, or at least every 100 bytes or so)?

What pre-processor options can I set to remove things like FTS or R-Tree support which I do not need? Do I set them at the command line or in the file?

Are there any other things easily removable that I might not need and might not even know they exist i开发者_JAVA百科n order to remove them?

How about some of the C API? Most of it I never use.


Please look here. There's a chapter "Options to omit features". You'll find for example SQLITE_OMIT_ATTACH there.

But please note the warning there. It says

the SQLITE_OMIT_* compile-time options are usually untested and are almost certainly untested in combination. Any or all of these options may be removed from the code in future releases and without warning. For any particular release, some of these options may cause compile-time or run-time failures, particularly when used in combination with other options.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜