Add ChainstateManagerOpts, using as ::Options, pass it an adjusted_time_callback
Summary:
This reduces coupling validation.cpp from netaddress.cpp (transitively,
timedata.cpp, and asmap.cpp). We unfortunately still have the transitive coupling with these modules because of validation -> avalanche/processor -> net.
This is important for libbitcoinkernel as:
- There is no reason for the consensus engine to be coupled with netaddress, timedata, and asmap
- Users of libbitcoinkernel can now easily supply their own std::function that provides the adjusted time.
This is a backport of core#25064
Test Plan: cmake .. -GNinja -DBUILD_BITCOIN_CHAINSTATE=ON && ninja all check-all
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Differential Revision: https://reviews.bitcoinabc.org/D15031