Add outputtype module
Summary:
Moves OutputType into its own module
- Move AddAndGetDestinationForScript from wallet to outputype module
Makes AddAndGetDestinationForScript use a generic CKeyStore rather than
the wallet, and makes it always add the script to the keystore, rather
than only adding related (redeem) scripts.
- segwit support for createmultisig RPC
- [tests] functional test for createmultisig RPC
This is a backport of Core PR13072
Depends on D4423
Test Plan:
make check ./test/functional/test_runner.py
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Subscribers: Fabien
Differential Revision: https://reviews.bitcoinabc.org/D4424