Source0: https://bitcoin.org/bin/bitcoin-core-%{version}/bitcoin-%{version}.tar.gz
# Source0-md5: 46e632b4f42a5162e6f100a01cf4ee00
Patch0: qt-5.15.patch
+Patch1: univalue.patch
URL: http://www.bitcoin.org/
BuildRequires: Qt5Core-devel >= 5.0
BuildRequires: Qt5DBus-devel >= 5.0
%prep
%setup -q
%patch0 -p1
+%patch1 -p1
%build
%{__libtoolize}
--- /dev/null
+Description: fix convert atomic to non-atomic integer for UniValue
+ Fixes Bitcoin 0.20.1 build failure when linked with mainline UniValue:
+ rpc/blockchain.cpp:2077:35: error: cannot convert 'std::atomic<int>' to 'const UniValue&'
+Author: Jonas Smedegaard <dr@jones.dk>
+License: Expat
+Last-Update: 2020-11-26
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/src/rpc/blockchain.cpp
++++ b/src/rpc/blockchain.cpp
+@@ -2187,7 +2187,7 @@
+ // no scan in progress
+ return NullUniValue;
+ }
+- result.pushKV("progress", g_scan_progress);
++ result.pushKV("progress", (int)g_scan_progress);
+ return result;
+ } else if (request.params[0].get_str() == "abort") {
+ CoinsViewScanReserver reserver;