Though at the moment ChainActive() simply references g_chainstate.m_chain,
doing this change now clears the way for multiple chainstate usage and allows
us to script the diff.
-BEGIN VERIFY SCRIPT-
git grep -l "chainActive" | grep -E '(h|cpp)$' | xargs sed -i '/chainActive =/b; /extern CChain& chainActive/b; s/\(::\)\{0,1\}chainActive/::ChainActive()/g'
-END VERIFY SCRIPT-
Depends on D5056
Partial backport of Core PR15948
https://github.com/bitcoin/bitcoin/pull/15948/commits/631940aab228ccca64c15e05d5953f40381a0ffc
https://github.com/bitcoin/bitcoin/pull/15948/commits/486c1eea863a41e597ae4fddc392f446f2518b4b