@@ -1,5 +1,5 @@
11{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, openssl, db48, boost
2−, zlib, miniupnpc, qt4, utillinux, protobuf, qrencode, libevent
2+, zlib, miniupnpc, qt5, utillinux, protobuf, qrencode, libevent
33, withGui }:
44
55with stdenv.lib;
@@ -16,13 +16,15 @@ stdenv.mkDerivation rec {
1616 sha256 = "1fygn6cc99iasg5g5jyps5ps873hfnn4ln4hsmcwlwiqd591qxyv";
1717 };
1818
19+ patches = [ ./fix-bitcoin-qt-build.patch ];
20+
1921 nativeBuildInputs = [ pkgconfig autoreconfHook ];
2022 buildInputs = [ openssl db48 boost zlib
2123 miniupnpc utillinux protobuf libevent ]
22− ++ optionals withGui [ qt4 qrencode ];
24+ ++ optionals withGui [ qt5.qtbase qt5.qttools qrencode ];
2325
2426 configureFlags = [ "--with-boost-libdir=${boost.out}/lib" ]
25− ++ optionals withGui [ "--with-gui=qt4" ];
27+ ++ optionals withGui [ "--with-gui=qt5" ];
2628
2729 meta = {
2830 description = "Peer-to-peer electronic cash system (Cash client)";