diff options
author | Frederik Rietdijk <fridh@fridh.nl> | 2017-11-11 16:24:38 +0100 |
---|---|---|
committer | Frederik Rietdijk <fridh@fridh.nl> | 2017-11-23 15:11:03 +0100 |
commit | 80329e71235d088e590ae044e96dabeb4ace3215 (patch) | |
tree | 0fb85dc4bb7933934bd2f8e41a01160ee794ce78 /pkgs/development/interpreters | |
parent | 7c3c2a0dcabf21478d4f895fd4aef6a9606d3835 (diff) | |
download | nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar.gz nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar.bz2 nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar.lz nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar.xz nixlib-80329e71235d088e590ae044e96dabeb4ace3215.tar.zst nixlib-80329e71235d088e590ae044e96dabeb4ace3215.zip |
python.pkgs.buildPythonPackage: some comments
Diffstat (limited to 'pkgs/development/interpreters')
-rw-r--r-- | pkgs/development/interpreters/python/build-python-package.nix | 6 | ||||
-rw-r--r-- | pkgs/development/interpreters/python/mk-python-derivation.nix | 14 |
2 files changed, 10 insertions, 10 deletions
diff --git a/pkgs/development/interpreters/python/build-python-package.nix b/pkgs/development/interpreters/python/build-python-package.nix index 29b578343687..982542c1fc3e 100644 --- a/pkgs/development/interpreters/python/build-python-package.nix +++ b/pkgs/development/interpreters/python/build-python-package.nix @@ -1,7 +1,5 @@ -/* This function provides a generic Python package builder. It is - intended to work with packages that use `distutils/setuptools' - (http://pypi.python.org/pypi/setuptools/), which represents a large - number of Python packages nowadays. */ +# This function provides a generic Python package builder, +# and can build packages that use distutils, setuptools or flit. { lib , python diff --git a/pkgs/development/interpreters/python/mk-python-derivation.nix b/pkgs/development/interpreters/python/mk-python-derivation.nix index b7327706d246..a0cac7d1ddda 100644 --- a/pkgs/development/interpreters/python/mk-python-derivation.nix +++ b/pkgs/development/interpreters/python/mk-python-derivation.nix @@ -1,4 +1,4 @@ -/* Generic builder for Python packages that come without a setup.py. */ +# Generic builder. { lib , python @@ -60,13 +60,15 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs [ name = namePrefix + name; - - buildInputs = [ wrapPython ] ++ buildInputs ++ pythonPath - ++ [ (ensureNewerSourcesHook { year = "1980"; }) ] + buildInputs = ([ wrapPython (ensureNewerSourcesHook { year = "1980"; }) ] ++ (lib.optional (lib.hasSuffix "zip" attrs.src.name or "") unzip) - ++ lib.optionals doCheck checkInputs; + ++ lib.optionals doCheck checkInputs + ++ lib.optional catchConflicts setuptools # If we nog longer propagate setuptools + ++ buildInputs + ++ pythonPath + ); - # propagate python/setuptools to active setup-hook in nix-shell + # Propagate python and setuptools. We should stop propagating setuptools. propagatedBuildInputs = propagatedBuildInputs ++ [ python setuptools ]; # Python packages don't have a checkPhase, only an installCheckPhase |