lol
1{ lib, stdenv
2, fetchFromGitHub
3, openssl
4, boost
5, libevent
6, autoreconfHook
7, db4
8, pkg-config
9, protobuf
10, hexdump
11, zeromq
12, gmp
13, withGui
14, qtbase ? null
15, qttools ? null
16, wrapQtAppsHook ? null
17}:
18
19stdenv.mkDerivation rec {
20 pname = "vertcoin";
21 version = "0.18.0";
22
23 name = pname + toString (lib.optional (!withGui) "d") + "-" + version;
24
25 src = fetchFromGitHub {
26 owner = pname + "-project";
27 repo = pname + "-core";
28 rev = "2bd6dba7a822400581d5a6014afd671fb7e61f36";
29 sha256 = "ua9xXA+UQHGVpCZL0srX58DDUgpfNa+AAIKsxZbhvMk=";
30 };
31
32 nativeBuildInputs = [
33 autoreconfHook
34 pkg-config
35 hexdump
36 ] ++ lib.optionals withGui [
37 wrapQtAppsHook
38 ];
39
40 buildInputs = [
41 openssl
42 boost
43 libevent
44 db4
45 zeromq
46 gmp
47 ] ++ lib.optionals withGui [
48 qtbase
49 qttools
50 protobuf
51 ];
52
53 enableParallelBuilding = true;
54
55 configureFlags = [
56 "--with-boost-libdir=${boost.out}/lib"
57 ] ++ lib.optionals withGui [
58 "--with-gui=qt5"
59 "--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
60 ];
61
62 meta = with lib; {
63 description = "A digital currency with mining decentralisation and ASIC resistance as a key focus";
64 homepage = "https://vertcoin.org/";
65 license = licenses.mit;
66 maintainers = [ maintainers.mmahut ];
67 platforms = platforms.linux;
68 };
69}