about summary refs log tree commit diff
path: root/pkgs/applications/blockchains/zcash
diff options
context:
space:
mode:
authorAlex Wied <centromere@users.noreply.github.com>2022-10-21 02:35:58 -0400
committerAlex Wied <centromere@users.noreply.github.com>2022-10-26 22:17:27 -0400
commite50d949516c661e2bcd7be54977762bc4d883deb (patch)
tree5134150a4de0530463fad42ef3ffc4ed7a912c03 /pkgs/applications/blockchains/zcash
parentd0072ce484c88a6b638eec3a68c60fba30605bf4 (diff)
zcash: 5.1.0 -> 5.3.0
Diffstat (limited to 'pkgs/applications/blockchains/zcash')
-rw-r--r--pkgs/applications/blockchains/zcash/default.nix32
-rw-r--r--pkgs/applications/blockchains/zcash/patches/fix-missing-header.patch10
2 files changed, 20 insertions, 22 deletions
diff --git a/pkgs/applications/blockchains/zcash/default.nix b/pkgs/applications/blockchains/zcash/default.nix
index c4d007f290773..7466ff31d5816 100644
--- a/pkgs/applications/blockchains/zcash/default.nix
+++ b/pkgs/applications/blockchains/zcash/default.nix
@@ -1,17 +1,17 @@
-{ autoreconfHook, boost179, cargo, coreutils, curl, cxx-rs, db62, fetchFromGitHub
-, hexdump, lib, libevent, libsodium, makeWrapper, rust, rustPlatform, pkg-config
-, stdenv, testers, utf8cpp, util-linux, zcash, zeromq
+{ autoreconfHook, boost180, cargo, coreutils, curl, cxx-rs, db62, fetchFromGitHub
+, hexdump, hostPlatform, lib, libevent, libsodium, makeWrapper, rust, rustPlatform
+, pkg-config, Security, stdenv, testers, utf8cpp, util-linux, zcash, zeromq
 }:
 
 rustPlatform.buildRustPackage.override { inherit stdenv; } rec {
   pname = "zcash";
-  version = "5.1.0";
+  version = "5.3.0";
 
   src = fetchFromGitHub {
     owner = "zcash";
     repo  = "zcash";
     rev = "v${version}";
-    sha256 = "sha256-tU6DuWpe8Vlx0qIilAKWuO7WFp1ucbxtvOxoWLA0gdc=";
+    hash = "sha256-mlABKZDYYC3y+KlXQVFqdcm46m8K9tbOCqk4lM4shp8=";
   };
 
   prePatch = lib.optionalString stdenv.isAarch64 ''
@@ -20,15 +20,20 @@ rustPlatform.buildRustPackage.override { inherit stdenv; } rec {
       --replace "linker = \"aarch64-linux-gnu-gcc\"" ""
   '';
 
-  patches = [
-    ./patches/fix-missing-header.patch
-  ];
-
-  cargoSha256 = "sha256-ZWmkveDEENdXRirGmnUWSjtPNJvX0Jpgfxhzk44F7Q0=";
+  cargoHash = "sha256-6uhtOaBsgMw59Dy6yivZYUEWDsYfpInA7VmJrqxDS/4=";
 
   nativeBuildInputs = [ autoreconfHook cargo cxx-rs hexdump makeWrapper pkg-config ];
 
-  buildInputs = [ boost179 db62 libevent libsodium utf8cpp zeromq ];
+  buildInputs = [
+    boost180
+    db62
+    libevent
+    libsodium
+    utf8cpp
+    zeromq
+  ] ++ lib.optionals stdenv.isDarwin [
+    Security
+  ];
 
   # Use the stdenv default phases (./configure; make) instead of the
   # ones from buildRustPackage.
@@ -50,7 +55,7 @@ rustPlatform.buildRustPackage.override { inherit stdenv; } rec {
 
   configureFlags = [
     "--disable-tests"
-    "--with-boost-libdir=${lib.getLib boost179}/lib"
+    "--with-boost-libdir=${lib.getLib boost180}/lib"
     "RUST_TARGET=${rust.toRustTargetSpec stdenv.hostPlatform}"
   ];
 
@@ -75,5 +80,8 @@ rustPlatform.buildRustPackage.override { inherit stdenv; } rec {
     homepage = "https://z.cash/";
     maintainers = with maintainers; [ rht tkerber centromere ];
     license = licenses.mit;
+
+    # https://github.com/zcash/zcash/issues/4405
+    broken = hostPlatform.isAarch64 && hostPlatform.isDarwin;
   };
 }
diff --git a/pkgs/applications/blockchains/zcash/patches/fix-missing-header.patch b/pkgs/applications/blockchains/zcash/patches/fix-missing-header.patch
deleted file mode 100644
index 6850d78ef12bf..0000000000000
--- a/pkgs/applications/blockchains/zcash/patches/fix-missing-header.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/src/uint256.h	2022-07-20 10:07:39.191319302 +0000
-+++ b/src/uint256.h	2022-07-20 10:07:11.809632293 +0000
-@@ -7,6 +7,7 @@
- #ifndef BITCOIN_UINT256_H
- #define BITCOIN_UINT256_H
-
-+#include <array>
- #include <assert.h>
- #include <cstring>
- #include <stdexcept>