I have a wxWidgets C++ project which uses SQLite. It is built with MSVC 2010.
Basically all you need is this:
1. Download sqlite3 amalgamation packet which contains the source code of sqlite3
2. Create a C++ project or C project for that matter.
3. In the main() put following code:
int result = sqlite3_open( "database.db", &handle );
if( result == SQLITE_OK )
if( sqlite3_prepare_v2( handle, "CREATE TABLE test( id INTEGER, name CHAR( 10 ) );", -1, &stmt, 0 ) == SQLITE_OK )
sqlite3_step( stmt );
sqlite3_finalize( stmt );
sqlite3_close( handle );
Attach "vld" to the project, compile and run.
You will get a lot of memory leaks on the "sqlite3_open()" and "sqlite3_prepare_v2()" calls.
However, "sqlite3_finalize( stmt );" line should take care of all memory allocations that had been done on the code.
If you will not get any leaks let me know and I will try to provide the code along with the simple db to replicate.
If you do, let me know as well so that I know this is not something specific to wxWidgets.
P.S.: One suggestion (a little off-topic): it would be nice if there will be some instructions on how to remove VLD from Visual Studio.
I tried to just remove the line "#include "vld.h", but when running the project under the debugger it has been stuck on exit as if it searches for the VLD DLL's.