python.pkgs.backports_lzma: move expression

This commit is contained in:
Frederik Rietdijk 2017-12-31 12:08:59 +01:00
parent 45a92a0ddd
commit 4e19e620c8
2 changed files with 33 additions and 17 deletions

View File

@ -0,0 +1,32 @@
{ lib
, buildPythonPackage
, fetchPypi
, isPy3k
, lzma
, python
}:
buildPythonPackage rec {
pname = "backports.lzma";
version = "0.0.3";
disabled = isPy3k;
src = fetchPypi {
inherit pname version;
sha256 = "bac58aec8d39ac3d22250840fb24830d0e4a0ef05ad8f3f09172dc0cc80cdbca";
};
buildInputs = [ lzma ];
# Needs the compiled module in $out
checkPhase = ''
PYTHONPATH=$out/${python.sitePackages}:$PYTHONPATH ${python.interpreter} -m unittest discover -s test
'';
meta = {
description = "Backport of Python 3.3's 'lzma' module for XZ/LZMA compressed files";
homepage = https://github.com/peterjc/backports.lzma;
license = lib.licenses.bsd3;
};
}

View File

@ -1038,23 +1038,7 @@ in {
};
};
backports_lzma = self.buildPythonPackage rec {
name = "backports.lzma-0.0.3";
disabled = isPy3k;
src = pkgs.fetchurl {
url = "mirror://pypi/b/backports.lzma/${name}.tar.gz";
sha256 = "bac58aec8d39ac3d22250840fb24830d0e4a0ef05ad8f3f09172dc0cc80cdbca";
};
buildInputs = [ pkgs.lzma ];
meta = {
description = "Backport of Python 3.3's 'lzma' module for XZ/LZMA compressed files";
homepage = https://github.com/peterjc/backports.lzma;
license = licenses.bsd3;
};
};
backports_lzma = callPackage ../development/python-modules/backports_lzma { };
backports_tempfile = callPackage ../development/python-modules/backports_tempfile { };