16 # This package should be updated together with the main grpc package and other
17 # related python grpc packages.
18 # nixpkgs-update: no auto update
19 buildPythonPackage rec {
24 disabled = pythonOlder "3.8";
27 inherit pname version;
28 hash = "sha256-4JCyVT4Noch1RJyOdQc91EFd1xyb3mpAYkD99MDuRnw=";
36 build-system = [ setuptools ];
49 dependencies = [ protobuf ];
53 export GRPC_PYTHON_BUILD_EXT_COMPILER_JOBS="$NIX_BUILD_CORES"
54 if [ -z "$enableParallelBuilding" ]; then
55 GRPC_PYTHON_BUILD_EXT_COMPILER_JOBS=1
58 + lib.optionalString stdenv.hostPlatform.isDarwin ''
62 GRPC_BUILD_WITH_BORING_SSL_ASM = "";
63 GRPC_PYTHON_BUILD_SYSTEM_OPENSSL = 1;
64 GRPC_PYTHON_BUILD_SYSTEM_ZLIB = 1;
65 GRPC_PYTHON_BUILD_SYSTEM_CARES = 1;
67 # does not contain any tests
70 enableParallelBuilding = true;
72 pythonImportsCheck = [ "grpc" ];
75 description = "HTTP/2-based RPC framework";
76 homepage = "https://grpc.io/grpc/python/";
77 changelog = "https://github.com/grpc/grpc/releases/tag/v${version}";
78 license = licenses.asl20;