Merge pull request #311123 from drawbu/fix-http-parser
This commit is contained in:
commit
0d793f31de
@ -1,9 +1,11 @@
|
|||||||
{ lib
|
{
|
||||||
, buildPythonPackage
|
lib,
|
||||||
, fetchFromGitHub
|
buildPythonPackage,
|
||||||
, cython
|
fetchFromGitHub,
|
||||||
, setuptools
|
cython,
|
||||||
, pytestCheckHook
|
setuptools,
|
||||||
|
pytestCheckHook,
|
||||||
|
fetchpatch,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
@ -28,18 +30,24 @@ buildPythonPackage rec {
|
|||||||
make -B
|
make -B
|
||||||
'';
|
'';
|
||||||
|
|
||||||
pythonImportsCheck = [
|
pythonImportsCheck = [ "http_parser" ];
|
||||||
"http_parser"
|
|
||||||
|
# The imp module is deprecated since version 3.4, and was removed in 3.12
|
||||||
|
# https://docs.python.org/3.11/library/imp.html
|
||||||
|
# Fix from: https://github.com/benoitc/http-parser/pull/101/
|
||||||
|
patches = [
|
||||||
|
(fetchpatch {
|
||||||
|
url = "https://github.com/benoitc/http-parser/commit/4d4984ce129253f9de475bfd3c683301c916e8b1.patch";
|
||||||
|
hash = "sha256-d3k1X41/D9PpPWsDety2AiYyLv9LJIhpkOo3a6qKcB8=";
|
||||||
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
nativeCheckInputs = [
|
nativeCheckInputs = [ pytestCheckHook ];
|
||||||
pytestCheckHook
|
|
||||||
];
|
|
||||||
|
|
||||||
meta = with lib; {
|
meta = {
|
||||||
description = "HTTP request/response parser for python in C";
|
description = "HTTP request/response parser for python in C";
|
||||||
homepage = "https://github.com/benoitc/http-parser";
|
homepage = "https://github.com/benoitc/http-parser";
|
||||||
license = licenses.mit;
|
license = lib.licenses.mit;
|
||||||
maintainers = with maintainers; [ ];
|
maintainers = [ ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user