[CMAKE] Add an option to promote some warnings to errors
Summary: This is a cmake port of the autotools --enable-werror option.
Test Plan:
cmake -GNinja -DENABLE_WERROR=ON .. ninja check
Reviewers: #bitcoin_abc, deadalnix, jasonbcox
Reviewed By: #bitcoin_abc, jasonbcox
Differential Revision: https://reviews.bitcoinabc.org/D4697