Add -dbstats argument.

Implement the -dbstats argument, which runs a database file storage
statistics analysis and prints it to the debug log.
Make CTxIndex::vSpent private.

Make the CTxIndex::vSpent member private, and access it only via
interface functions from the outside.
Change internal vSpent data format.

Actually change the vSpent array internally to be an array of flags
instead of full tx positions.  Not yet efficiently as a bit vector,
though.
Switch isSpent to std::vector<bool> and bit vector.

Use std::vector<bool> for the flag array, and implement proper
serialisation routines for bit vectors.
Allow setting of stream version in the DB.

Allow setting of the nVersion parameter used for stream serialisation in
the database.
Fully rewrite txindex on upgrading blkindex.dat format.

When upgrading the blkindex.dat data format, actually fully rewrite the
txindex objects stored in it.
Add comment and close DB earlier.
Rename variable to clarify its intent.
Remove serialisation versino from CDiskBlockIndex storage.

Don't store the nVersion field for CDiskBlockIndex, since we now have
the DB serialisation version.  (The nVersion of the block header is not
affected.)
Fix setting of stream versions for LoadBlockIndex.
Add assertion check for fRead | version up to date.
Remove unused skip field and don't overwrite version in CDB::Rewrite.

In CDB::Rewrite, just do a literal rewrite.  Don't skip fields and don't
overwrite the version.
Update changelog.md
Merge pull request #85 from domob1812/remove-vspent

Further update blkindex.dat by changing the vSpent format
Merge pull request #89 from domob1812/analyse-db

Add -dbstats argument from Huntercoin to analyse BDB storage