anchor.diff:  { fetchFromGitHub, stdenv, pkgconfig, autoreconfHook, wrapQtAppsHook ? null
  -, openssl_1_0_2, db48, boost, zlib, miniupnpc, gmp
  +, openssl, db48, boost, zlib, miniupnpc, gmp
   , qrencode, glib, protobuf, yasm, libevent
   , utillinux, qtbase ? null, qttools ? null
   , enableUpnp ? false
  
positive.code:                     ++ optional disableWallet "--disable-wallet"
                      ++ optional disableDaemon "--disable-daemon"
                      ++ optionals withGui [ "--with-gui=yes"
                                             "--with-unsupported-ssl" # TODO remove this ASAP
                                             "--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
                                           ];
    
  
negative.code: with stdenv.lib;
  stdenv.mkDerivation rec {
    name = "pivx-${version}";
    version = "4.1.1";
  
    src = fetchFromGitHub {
      owner = "PIVX-Project";
      repo= "PIVX";
      rev = "v${version}";
      sha256 = "03ndk46h6093v8s18d5iffz48zhlshq7jrk6vgpjfs6z2iqgd2sy";
    };
  
    nativeBuildInputs = [ pkgconfig autoreconfHook ] ++ optionals withGui [ wrapQtAppsHook ];
    buildInputs = [ glib gmp openssl db48 yasm boost zlib libevent miniupnpc protobuf utillinux ]
                    ++ optionals withGui [ qtbase qttools qrencode ];
  
    configureFlags = [ "--with-boost-libdir=${boost.out}/lib" ]
  