Protocol Buffers - Google's data interchange format (grpc依赖) https://developers.google.com/protocol-buffers/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
847 B

load(
"//bazel:build_defs.bzl",
"UPB_DEFAULT_CPPOPTS",
)
licenses(["notice"]) # BSD (Google-authored w/ possible external contributions)
cc_library(
name = "upbc_generator",
srcs = [
"generator.cc",
"message_layout.cc",
"message_layout.h",
],
hdrs = ["generator.h"],
copts = UPB_DEFAULT_CPPOPTS,
deps = [
"@com_google_absl//absl/base:core_headers",
"@com_google_absl//absl/container:flat_hash_map",
"@com_google_absl//absl/strings",
"@com_google_protobuf//:protobuf",
"@com_google_protobuf//:protoc_lib",
],
)
cc_binary(
name = "protoc-gen-upb",
srcs = ["main.cc"],
copts = UPB_DEFAULT_CPPOPTS,
visibility = ["//visibility:public"],
deps = [
":upbc_generator",
"@com_google_protobuf//:protoc_lib",
],
)