From 50578abfc5e42b47247c486bf845c310c2299d8d Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Mon, 17 Sep 2018 20:21:21 +0200 Subject: [PATCH] fetchcargo: Fix cargo-vendor-normalise for darwin --- pkgs/build-support/rust/fetchcargo.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/build-support/rust/fetchcargo.nix b/pkgs/build-support/rust/fetchcargo.nix index eb51e5c4ff9..9e77f8817b2 100644 --- a/pkgs/build-support/rust/fetchcargo.nix +++ b/pkgs/build-support/rust/fetchcargo.nix @@ -2,8 +2,11 @@ let cargo-vendor-normalise = stdenv.mkDerivation { name = "cargo-vendor-normalise"; src = ./cargo-vendor-normalise.py; + nativeBuildInputs = [ python3.pkgs.wrapPython ]; unpackPhase = ":"; installPhase = "install -D $src $out/bin/cargo-vendor-normalise"; + pythonPath = [ python3.pkgs.toml ]; + postFixup = "wrapPythonPrograms"; doInstallCheck = true; installCheckPhase = '' # check that ./fetchcargo-default-config.toml is a fix point @@ -11,7 +14,6 @@ let cargo-vendor-normalise = stdenv.mkDerivation { < $reference $out/bin/cargo-vendor-normalise > test; cmp test $reference ''; - buildInputs = [ (python3.withPackages(ps: [ ps.toml ])) ]; preferLocalBuild = true; }; in