aboutsummaryrefslogtreecommitdiffhomepage
path: root/third_party/protobuf/3.0.0
diff options
context:
space:
mode:
authorGravatar Klaus Aehlig <aehlig@google.com>2016-11-25 12:47:29 +0000
committerGravatar Dmitry Lomov <dslomov@google.com>2016-11-25 13:37:41 +0000
commite72d7a07d6f6e13feee87e16d48fee9dd3857eee (patch)
tree4861b0a6ab5bbc208f35d5405148ac82cc784627 /third_party/protobuf/3.0.0
parentfdeb747093ce46ec3397d240cb0a467ca4fdbf72 (diff)
Build protoc from source
Use the provided sources to build the protoc binary instead of using the committed binaries. -- Change-Id: I3df01e9f400e3cebbd1fe3ce74c6142c93c58b6c Reviewed-on: https://cr.bazel.build/6732 MOS_MIGRATED_REVID=140192644
Diffstat (limited to 'third_party/protobuf/3.0.0')
-rw-r--r--third_party/protobuf/3.0.0/BUILD25
1 files changed, 8 insertions, 17 deletions
diff --git a/third_party/protobuf/3.0.0/BUILD b/third_party/protobuf/3.0.0/BUILD
index 2a22dbcfad..2e6f89401d 100644
--- a/third_party/protobuf/3.0.0/BUILD
+++ b/third_party/protobuf/3.0.0/BUILD
@@ -18,23 +18,6 @@ filegroup(
visibility = ["//third_party/protobuf:__pkg__"],
)
-filegroup(
- name = "protoc",
- srcs = select({
- # protoc-windows-x86_64.exe can't deal with long path(length > 260),
- # so use protoc-mingw.exe instead.
- "//third_party:windows_mingw": ["protoc-3.0.0-mingw.exe"],
- "//third_party:windows_msys64_mingw64": ["protoc-3.0.0-mingw.exe"],
- "//third_party:windows_msys64": ["protoc-3.0.0-mingw.exe"],
- "//third_party:windows_clang": ["protoc-3.0.0-mingw.exe"],
- "//third_party:darwin": ["protoc-3.0.0-osx-x86_32.exe"],
- "//third_party:k8": ["protoc-3.0.0-linux-x86_64.exe"],
- "//third_party:piii": ["protoc-3.0.0-linux-x86_32.exe"],
- "//third_party:freebsd": ["protoc-3.0.0-linux-x86_32.exe"],
- "//third_party:s390x": ["protoc-linux-s390x_64.exe"],
- }),
-)
-
java_import(
name = "protobuf",
jars = ["protobuf-java-3.0.0.jar"],
@@ -318,3 +301,11 @@ proto_lang_toolchain(
command_line = "--java_out=shared,immutable:$(OUT)",
runtime = ":protobuf",
)
+
+cc_binary(
+ name = "protoc",
+ srcs = ["src/google/protobuf/compiler/main.cc"],
+ linkopts = LINK_OPTS,
+ visibility = ["//visibility:public"],
+ deps = [":protoc_lib"],
+)