From 45d92aea27585cadcb9ddf52913f66996948f33e Mon Sep 17 00:00:00 2001 From: cgrushko Date: Fri, 2 Dec 2016 19:40:50 -0500 Subject: Add a proto_lang_toolchain() for cc_proto_library Bazel's built-in cc_proto_library rule uses a proto_lang_toolchain to learn how to invoke proto-compiler. To use Bazel's cc_proto_library, add the following to your project's WORKSPACE file: local_repository( name = "com_google_protobuf_cc", path = "/path/to/protobuf-distribution/" ) --- BUILD | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/BUILD b/BUILD index f17c500a..7137088e 100644 --- a/BUILD +++ b/BUILD @@ -749,3 +749,10 @@ internal_protobuf_py_tests( ], deps = [":python_tests"], ) + +proto_lang_toolchain( + name = "cc_toolchain", + runtime = ":protobuf", + command_line = "--cpp_out=$(OUT)", + visibility = ["//visibility:public"], +) -- cgit v1.2.3