Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.09 31 lines 900 B view raw
1{ stdenv, buildPythonPackage, fetchFromGitHub, darwin 2, six, protobuf, enum34, futures, isPy27, pkgconfig 3, cython}: 4 5buildPythonPackage rec { 6 pname = "grpcio"; 7 version = "1.23.0"; 8 9 src = fetchFromGitHub { 10 owner = "grpc"; 11 repo = "grpc"; 12 rev = "v${version}"; 13 fetchSubmodules = true; 14 sha256 = "18hf794frncqvq3n4j5n8kip0gp6ch4pf5b3n6809q0c1paf6rp5"; 15 }; 16 17 nativeBuildInputs = [ cython pkgconfig ] 18 ++ stdenv.lib.optional stdenv.isDarwin darwin.cctools; 19 20 propagatedBuildInputs = [ six protobuf ] 21 ++ stdenv.lib.optionals (isPy27) [ enum34 futures ]; 22 23 preBuild = stdenv.lib.optionalString stdenv.isDarwin "unset AR"; 24 25 meta = with stdenv.lib; { 26 description = "HTTP/2-based RPC framework"; 27 license = licenses.asl20; 28 homepage = "https://grpc.io/grpc/python/"; 29 maintainers = with maintainers; [ vanschelven ]; 30 }; 31}