buildPythonPackage: refactor

This commit is contained in:
Frederik Rietdijk
2016-12-03 13:04:52 +01:00
parent c6a7d8e10f
commit 42bad32e13
8 changed files with 148 additions and 110 deletions

View File

@@ -57,6 +57,10 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled"] // {
inherit pythonPath;
# patch python interpreter to write null timestamps when compiling python files
# this way python doesn't try to update them when we freeze timestamps in nix store
DETERMINISTIC_BUILD=1;
buildInputs = [ wrapPython ] ++ buildInputs ++ pythonPath
++ [ (ensureNewerSourcesHook { year = "1980"; }) ]
++ (lib.optional (lib.hasSuffix "zip" attrs.src.name or "") unzip)