pythonPackages.gevent: move to python-modules/

This commit is contained in:
Bjørn Forsman 2017-10-29 14:51:29 +01:00
parent 34dbc6c01c
commit 9e76c950a7
2 changed files with 37 additions and 34 deletions

View File

@ -0,0 +1,36 @@
{ stdenv, fetchurl, buildPythonPackage, isPyPy, python, libev, greenlet }:
buildPythonPackage rec {
name = "gevent-1.1.2";
src = fetchurl {
url = "mirror://pypi/g/gevent/${name}.tar.gz";
sha256 = "cb15cf73d69a2eeefed330858f09634e2c50bf46da9f9e7635730fcfb872c02c";
};
# Why do we have this patch?
postPatch = ''
substituteInPlace libev/ev.c --replace \
"ecb_inline void ecb_unreachable (void) ecb_noreturn" \
"ecb_inline ecb_noreturn void ecb_unreachable (void)"
'';
buildInputs = [ libev ];
propagatedBuildInputs = stdenv.lib.optionals (!isPyPy) [ greenlet ];
checkPhase = ''
cd greentest
${python.interpreter} testrunner.py
'';
# Bunch of failures.
doCheck = false;
meta = with stdenv.lib; {
description = "Coroutine-based networking library";
homepage = http://www.gevent.org/;
license = licenses.mit;
platforms = platforms.unix;
maintainers = with maintainers; [ bjornfor ];
};
}

View File

@ -9445,40 +9445,7 @@ in {
};
};
gevent = buildPythonPackage rec {
name = "gevent-1.1.2";
src = pkgs.fetchurl {
url = "mirror://pypi/g/gevent/${name}.tar.gz";
sha256 = "cb15cf73d69a2eeefed330858f09634e2c50bf46da9f9e7635730fcfb872c02c";
};
# Why do we have this patch?
postPatch = ''
substituteInPlace libev/ev.c --replace \
"ecb_inline void ecb_unreachable (void) ecb_noreturn" \
"ecb_inline ecb_noreturn void ecb_unreachable (void)"
'';
buildInputs = with self; [ pkgs.libev ];
propagatedBuildInputs = with self; optionals (!isPyPy) [ greenlet ];
checkPhase = ''
cd greentest
${python.interpreter} testrunner.py
'';
# Bunch of failures.
doCheck = false;
meta = {
description = "Coroutine-based networking library";
homepage = http://www.gevent.org/;
license = licenses.mit;
platforms = platforms.unix;
maintainers = with maintainers; [ bjornfor ];
};
};
gevent = callPackage ../development/python-modules/gevent { };
geventhttpclient = buildPythonPackage rec {
name = "geventhttpclient-${version}";