Break circular dependency: init -> * -> init by extracting shutdown.h
Summary:
Most includers just wanted to react to pending shutdown. This isolates access to `fRequestShutdown` and limits access to the shutdown api functions, including the new `AbortShutdown` for setting it to `false`.
Partial backport of core PR13235 (commit 1fabd59):
https://github.com/bitcoin/bitcoin/pull/13235/commits/1fabd59e7e870fae73bfbcfb227dd7452de94726
Depends on D4464.
Note to reviewers:
The Makefile/CMakeLists.txt change is obviously bad, because it is not
solving the circular dependency. Unfortunately solving this requires a
lot more backports that come after this one, so I leave it as is for
now.
Test Plan:
make check # autotools ninja check ninja bench-bitcoin
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D4465