ui: Compile boost:signals2 only once
Summary:
ui is one of the modules that poison other modules with boost/signals2 headers. This moves the include to the cpp file and uses a forward declaration in the header.
Backport of core PR13634.
Test Plan:
ninja check
Reviewers: #bitcoin_abc, deadalnix, jasonbcox
Reviewed By: #bitcoin_abc, jasonbcox
Differential Revision: https://reviews.bitcoinabc.org/D5051