3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #132095 from 06kellyjac/grpc-web

protoc-gen-grpc-web: init at 1.2.1
This commit is contained in:
Sandro 2021-08-02 08:53:52 +00:00 committed by GitHub
commit 268b1dec32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 42 additions and 0 deletions

View file

@ -0,0 +1,40 @@
{ lib, stdenv, fetchFromGitHub, fetchpatch, protobuf }:
stdenv.mkDerivation rec {
pname = "protoc-gen-grpc-web";
version = "1.2.1";
src = fetchFromGitHub {
owner = "grpc";
repo = "grpc-web";
rev = version;
sha256 = "sha256-NBENyc01O8NPo84z1CeZ7YvFvVGY2GSlcdxacRrQALw=";
};
sourceRoot = "source/javascript/net/grpc/web";
# remove once PR merged
# https://github.com/grpc/grpc-web/pull/1107
patches = [
(fetchpatch {
name = "add-prefix.patch";
url = "https://github.com/06kellyjac/grpc-web/commit/b0803be1080fc635a8d5b88da971835a888a0c77.patch";
stripLen = 4;
sha256 = "sha256-Rw9Z7F8cYrc/UIGUN6yXOus4v+Qn9Yf1Nc301TFx85A=";
})
];
strictDeps = true;
nativeBuildInputs = [ protobuf ];
buildInputs = [ protobuf ];
makeFlags = [ "PREFIX=$(out)" ];
meta = with lib; {
homepage = "https://github.com/grpc/grpc-web";
changelog = "https://github.com/grpc/grpc-web/blob/${version}/CHANGELOG.md";
description = "gRPC web support for Google's protocol buffers";
license = licenses.asl20;
maintainers = with maintainers; [ jk ];
};
}

View file

@ -317,6 +317,8 @@ in
protoc-gen-go-grpc = callPackage ../development/tools/protoc-gen-go-grpc { };
protoc-gen-grpc-web = callPackage ../development/tools/protoc-gen-grpc-web { };
protoc-gen-twirp = callPackage ../development/tools/protoc-gen-twirp { };
protoc-gen-twirp_php = callPackage ../development/tools/protoc-gen-twirp_php { };