title: How to make bazel pick up right version of com_google_protobuf_cc repository for loaded gRPC repository?
body: <p>I'm building a program with gRPC library using bazel. My WORKSPACE file:</p>
  
  <pre><code>http_archive(
      name = "com_github_grpc_grpc",
      urls = ["https://github.com/grpc/grpc/archive/v1.8.3.zip"],
      sha256 = "57a2c67abe789ce9e80d49f473515c7479ae494e87dba84463b10bbd0990ad62",
      strip_prefix = "grpc-1.8.3",
  )
  
  load("@com_github_grpc_grpc//bazel:grpc_deps.bzl", "grpc_deps")
  grpc_deps()
  </code></pre>
  
  <p>BUILD file:</p>
  
  <pre><code>proto_library(
      name = "test_proto",
      srcs = ["test.proto"],
  )
  
  cc_proto_library(
      name = "test_cc_proto",
      deps = [":test_proto"],
  )
  
  cc_binary(
      name = "hello",
      srcs = ["hello.cc"],
      deps = [ 
          ":test_cc_proto",
          "@com_github_grpc_grpc//:grpc++",
      ],  
  )
  </code></pre>
  
  <p>Compiling this throws error:</p>
  
  <pre><code>every rule of type proto_library implicitly depends upon the target '@com_google_protobuf_cc//:cc_toolchain', but this target could not be found because of: no such package '@com_google_protobuf_cc//': The repository could not be resolved.
  </code></pre>
  
  <p>If I include com_google_protobuf_cc repository manually, the version doesn't match and I get error saying test.pb.h was generated using a newer version of protoc.</p>
  
  <p>How do I make gRPC load right version of com_google_protobuf_cc?</p>