pythonPackages.pygit2: 0.25.1 -> 0.26.0

This commit is contained in:
Peter Hoeg 2017-11-02 16:35:40 +08:00 committed by Orivej Desh
parent ce1b0c05a5
commit 43934459fa
2 changed files with 32 additions and 39 deletions

View File

@ -0,0 +1,31 @@
{ stdenv, lib, buildPythonPackage, fetchPypi, isPyPy, libgit2, six, cffi }:
buildPythonPackage rec {
name = "${pname}-${version}";
pname = "pygit2";
version = "0.26.0";
src = fetchPypi {
inherit pname version;
sha256 = "1cbc488ra3kg7r3qky17ms0szi3cda2d96qfkv1l9djsy9hnvw57";
};
preConfigure = lib.optionalString stdenv.isDarwin ''
export DYLD_LIBRARY_PATH="${libgit2}/lib"
'';
propagatedBuildInputs = [ libgit2 six ] ++ lib.optional (!isPyPy) cffi;
preCheck = ''
# disable tests that require networking
rm test/test_repository.py
rm test/test_credentials.py
rm test/test_submodule.py
'';
meta = with lib; {
description = "A set of Python bindings to the libgit2 shared library";
homepage = https://pypi.python.org/pypi/pygit2;
license = licenses.gpl2;
};
}

View File

@ -15674,45 +15674,7 @@ in {
};
};
pygit2 = buildPythonPackage rec {
name = "pygit2-0.25.1";
src = pkgs.fetchurl {
url = "mirror://pypi/p/pygit2/${name}.tar.gz";
sha256 = "0sja3g9mqwp5bnhdc313b2gc4z3p70nn6zzf2h8j581g0lrn0sg8";
};
# Fixes a bug which can cause test failed when cffi==1.10
prePatch = let
cffiVersionPatch = pkgs.fetchurl {
url = "https://github.com/libgit2/pygit2/commit/b88dc868423af2f760f649960112efd0e37e5335.patch";
sha256 = "14cfrz56y2dnwlxrrss9pjhxfnyyg5856gbabzjzyx674k0qcid4";
};
in ''
# we need to delete part of the patch because the missing .travis.yml causes problem
sed -e '1,36d' ${cffiVersionPatch} | patch -p1
'';
preConfigure = ( if stdenv.isDarwin then ''
export DYLD_LIBRARY_PATH="${pkgs.libgit2}/lib"
'' else "" );
propagatedBuildInputs = with self; [ pkgs.libgit2 six ] ++ optionals (!isPyPy) [ cffi ];
preCheck = ''
# disable tests that require networking
rm test/test_repository.py
rm test/test_credentials.py
rm test/test_submodule.py
'';
meta = {
homepage = https://pypi.python.org/pypi/pygit2;
description = "A set of Python bindings to the libgit2 shared library";
license = licenses.gpl2;
platforms = platforms.all;
};
};
pygit2 = callPackage ../development/python-modules/pygit2 { };
Babel = buildPythonPackage (rec {
name = "Babel-2.3.4";