summary refs log tree commit diff
path: root/pkgs/development/python-modules/generic
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2009-05-26 10:03:33 +0000
committerLudovic Courtès <ludo@gnu.org>2009-05-26 10:03:33 +0000
commit010edd37395bd092076ec4f9707989d6ba88ceac (patch)
treebc7a0475f4b7e71e9a4b900fe59ace908cb2622d /pkgs/development/python-modules/generic
parent1635ec4bdfc992db19e902dfa018e8b8faad4c6d (diff)
downloadnixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar.gz
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar.bz2
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar.lz
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar.xz
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.tar.zst
nixpkgs-010edd37395bd092076ec4f9707989d6ba88ceac.zip
buildPythonPackage: Simplify attribute inheritance.
Suggested by Eelco Dolstra.

svn path=/nixpkgs/trunk/; revision=15731
Diffstat (limited to 'pkgs/development/python-modules/generic')
-rw-r--r--pkgs/development/python-modules/generic/default.nix14
1 files changed, 2 insertions, 12 deletions
diff --git a/pkgs/development/python-modules/generic/default.nix b/pkgs/development/python-modules/generic/default.nix
index 91869923be1..e97bf8d9add 100644
--- a/pkgs/development/python-modules/generic/default.nix
+++ b/pkgs/development/python-modules/generic/default.nix
@@ -5,7 +5,7 @@
 
 { python, setuptools, makeWrapper, lib }:
 
-attrs:
+{ name, src, meta, patches ? [], doCheck ? true, ... } @ attrs:
 
 let
     # Return the list of recursively propagated build inputs of PKG.
@@ -20,7 +20,7 @@ let
 in
 
 python.stdenv.mkDerivation rec {
-  inherit (attrs) src meta;
+  inherit src meta patches doCheck;
 
   name = "python-" + attrs.name;
 
@@ -32,18 +32,8 @@ python.stdenv.mkDerivation rec {
      then attrs.propagatedBuildInputs
      else []);
 
-  patches =
-    (if attrs ? patches
-     then attrs.patches
-     else []);
-
   buildPhase = "true";
 
-  doCheck =
-    (if attrs ? doCheck
-     then attrs.doCheck
-     else true);
-
   # Many packages, but not all, support this.
   checkPhase = "python setup.py test";