From 0509465542d63a5bbe7296f283f44dd491e74f78 Mon Sep 17 00:00:00 2001 From: John Newbery Date: Tue, 2 Apr 2019 16:51:32 -0400 Subject: [build] Move rpc rawtransaction util functions to rpc/rawtransaction_util.cpp rpc/rawtransaction.cpp moves to libbitcoin_server since it should not be accessed by non-node libraries. The utility following utility methods move to their own unit rpc/rawtransaction_util since they need to be accessed by non-node libraries: - `ConstructTransaction` - `TxInErrorToJSON` - `SignTransaction` --- src/Makefile.am | 3 +- src/rpc/rawtransaction.cpp | 278 +------------------------------------- src/rpc/rawtransaction.h | 22 --- src/rpc/rawtransaction_util.cpp | 293 ++++++++++++++++++++++++++++++++++++++++ src/rpc/rawtransaction_util.h | 22 +++ src/wallet/rpcwallet.cpp | 2 +- 6 files changed, 319 insertions(+), 301 deletions(-) delete mode 100644 src/rpc/rawtransaction.h create mode 100644 src/rpc/rawtransaction_util.cpp create mode 100644 src/rpc/rawtransaction_util.h (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am index cbbf35ccb9..b0d718f60a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -176,7 +176,7 @@ BITCOIN_CORE_H = \ rpc/mining.h \ rpc/protocol.h \ rpc/server.h \ - rpc/rawtransaction.h \ + rpc/rawtransaction_util.h \ rpc/register.h \ rpc/util.h \ scheduler.h \ @@ -439,6 +439,7 @@ libbitcoin_common_a_SOURCES = \ policy/policy.cpp \ protocol.cpp \ psbt.cpp \ + rpc/rawtransaction_util.cpp \ rpc/util.cpp \ scheduler.cpp \ script/descriptor.cpp \ diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 6ecde84cdb..4da952060e 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include #include