Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at gcc-offload 55 lines 1.1 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 cargo, 5 fetchFromGitHub, 6 hypothesis, 7 pytestCheckHook, 8 pythonOlder, 9 rustc, 10 rustPlatform, 11}: 12 13buildPythonPackage rec { 14 pname = "jh2"; 15 version = "5.0.4"; 16 pyproject = true; 17 18 disabled = pythonOlder "3.10"; 19 20 src = fetchFromGitHub { 21 owner = "jawah"; 22 repo = "h2"; 23 rev = "refs/tags/v${version}"; 24 hash = "sha256-la1tZ+t6HeGqaua1f858mT1IRyqS0hnoOiKr656vthQ="; 25 fetchSubmodules = true; 26 }; 27 28 cargoDeps = rustPlatform.fetchCargoTarball { 29 inherit src; 30 name = "${pname}-${version}"; 31 hash = "sha256-m1MkKhwTMDGsC0jt1skyFb23Ln5spa+vUEOyA5pHxP4="; 32 }; 33 34 build-system = [ 35 cargo 36 rustPlatform.cargoSetupHook 37 rustPlatform.maturinBuildHook 38 rustc 39 ]; 40 41 nativeCheckInputs = [ 42 hypothesis 43 pytestCheckHook 44 ]; 45 46 pythonImportsCheck = [ "jh2" ]; 47 48 meta = { 49 description = "HTTP/2 State-Machine based protocol implementation"; 50 homepage = "https://github.com/jawah/h2"; 51 changelog = "https://github.com/jawah/h2/blob/${src.rev}/CHANGELOG.rst"; 52 license = lib.licenses.mit; 53 maintainers = with lib.maintainers; [ fab ]; 54 }; 55}