Support LevelDB memory-backed environments, and use them in unit tests.
Database-independent glue for supporting LevelDB databases. Based on code from earlier commits by Mike Hearn in his leveldb branch.