Tweaks to allow using a subset of the lib and altchains

I don't use this for wallets at all, so no bsddb needed, and I also use it for altchains where the address version is different (also nice for testnet).

In fact, I only ever use a very specific subset of the module's files, but these tweaks might be useful for others.