diff options
Diffstat (limited to 'pkgs/development/tools/build-managers/gup/build.nix')
-rw-r--r-- | pkgs/development/tools/build-managers/gup/build.nix | 30 |
1 files changed, 7 insertions, 23 deletions
diff --git a/pkgs/development/tools/build-managers/gup/build.nix b/pkgs/development/tools/build-managers/gup/build.nix index b2a60c309b32..a9af037bb81e 100644 --- a/pkgs/development/tools/build-managers/gup/build.nix +++ b/pkgs/development/tools/build-managers/gup/build.nix @@ -1,30 +1,14 @@ -# NOTE: the `nixpkgs` version of this file is copied from the upstream repository -# for this package. Please make any changes to https://github.com/timbertson/gup/ +# NOTE: this file is copied from the upstream repository for this package. +# Please submit any changes you make here to https://github.com/timbertson/gup/ -{ stdenv, lib, pythonPackages }: -{ src, version, meta ? {}, passthru ? {}, forceTests ? false }: -let - testInputs = [ - pythonPackages.mocktest or null - pythonPackages.whichcraft - pythonPackages.nose - pythonPackages.nose_progressive - ]; - pychecker = pythonPackages.pychecker or null; - usePychecker = forceTests || pychecker != null; - enableTests = forceTests || (lib.all (dep: dep != null) testInputs); -in +{ stdenv, lib, python, which, pychecker ? null }: +{ src, version, meta ? {} }: stdenv.mkDerivation { - inherit src meta passthru; + inherit src meta; name = "gup-${version}"; - buildInputs = [ pythonPackages.python ] - ++ (lib.optionals enableTests testInputs) - ++ (lib.optional usePychecker pychecker) - ; - SKIP_PYCHECKER = !usePychecker; + buildInputs = lib.remove null [ python which pychecker ]; + SKIP_PYCHECKER = pychecker == null; buildPhase = "make python"; - inherit pychecker; - testPhase = if enableTests then "make test" else "true"; installPhase = '' mkdir $out cp -r python/bin $out/bin |