From 60511ddf1ca95c465cea22e02b416b6c6de79db3 Mon Sep 17 00:00:00 2001 From: yvanwang Date: Wed, 9 Feb 2022 20:01:34 +0800 Subject: [PATCH] fix tutorial build error: use gen_proto("protobuf") instead of type("proto") in srpc.bzl's genrule_cmd --- srpc.bzl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/srpc.bzl b/srpc.bzl index cf6a64d7..18a6887b 100644 --- a/srpc.bzl +++ b/srpc.bzl @@ -28,14 +28,16 @@ def srpc_cc_library( if type == "thrift": output_headers = proto_output_headers + thrift_output_headers + gen_proto = "thrift" if type == "proto": output_headers = proto_output_headers + gen_proto = "protobuf" genrule_cmd = " ".join([ "SRCS=($(SRCS));", "for f in $${SRCS[@]:0:%s}; do" % len(srcs), "$(location %s)" % (tool_path), - " %s " % type, + " %s " % gen_proto, "$$f", output_directory + ";", "done",