Once you complied leveldb for Windows, you should be able to reference the DLL and then use PInvoke to make calls into leveldb. Just as when using any other unmanaged resource, make sure to wrap calls to leveldb with a using() directive and dispose of them properly or else you could run into memory management issues.
Jeremiah Peschka
Founder, Brent Ozar PLF
build.bat will build release and debug version of 32bit and 64bit
version (in rel, dbg, rel64bit, dbg64bit directory). It creates all
test programs (e.g. arena_test.exe, cache_test.exe etc., statically
linked) as well as libleveldb.dll, which can be used from C#, if you
write a wrapper, using C-level apis (see db/c_test.c for how to use
C-level API, c_test.exe for test that exercises it).
Note that if you don't have 64bit compilers installed (they are
optional in Visual Studio 2010), build.bat will fail at some point.
Ignore that - 32 bit versions should have been built (in rel and dbg
directories).
If you want to recreate the build, you can analyze makefile.msvc,
build.bat and build.py to see how the build system works.
The WINDOWS file describes the other windows port, based on boost. My
port doesn't use boost or any other external dependencies and is pure
win32 API based. Most likely what happened is that you tried to
compile env_boost.cc and not env_win.cc.
-- kjk