tree: 48cac18b28b03cb7501bb5faf2d08f9d94e3aeb8
  1. example/
  2. BUILD.bazel
  3. cpp_grpc_compile.bzl
  4. cpp_grpc_library.bzl
  5. cpp_proto_compile.bzl
  6. cpp_proto_library.bzl
  7. deps.bzl
  8. README.md
cpp/README.md

cpp

RuleDescription
cpp_proto_compileGenerates .h,.cc protobuf artifacts
cpp_grpc_compileGenerates .h,.cc protobuf+gRPC artifacts
cpp_proto_libraryGenerates .h,.cc protobuf library
cpp_grpc_libraryGenerates .h,.cc protobuf+gRPC library

cpp_proto_compile

Generates .h,.cc protobuf artifacts

WORKSPACE

load("@build_stack_rules_proto//cpp:deps.bzl", "cpp_proto_compile")

cpp_proto_compile()

BUILD.bazel

load("@build_stack_rules_proto//cpp:cpp_proto_compile.bzl", "cpp_proto_compile")

cpp_proto_compile(
    name = "person_cpp_proto",
    deps = ["@build_stack_rules_proto//example/proto:person_proto"],
)

Mandatory Attributes

NameTypeDefaultDescription
depslist<ProtoInfo>[]List of labels that provide a ProtoInfo (such as native.proto_library)

Optional Attributes

NameTypeDefaultDescription
verboseint0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc

cpp_grpc_compile

Generates .h,.cc protobuf+gRPC artifacts

WORKSPACE

load("@build_stack_rules_proto//cpp:deps.bzl", "cpp_grpc_compile")

cpp_grpc_compile()

load("@com_github_grpc_grpc//bazel:grpc_deps.bzl", "grpc_deps")

grpc_deps()

BUILD.bazel

load("@build_stack_rules_proto//cpp:cpp_grpc_compile.bzl", "cpp_grpc_compile")

cpp_grpc_compile(
    name = "greeter_cpp_grpc",
    deps = ["@build_stack_rules_proto//example/proto:greeter_grpc"],
)

Mandatory Attributes

NameTypeDefaultDescription
depslist<ProtoInfo>[]List of labels that provide a ProtoInfo (such as native.proto_library)

Optional Attributes

NameTypeDefaultDescription
verboseint0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc

cpp_proto_library

Generates .h,.cc protobuf library

WORKSPACE

load("@build_stack_rules_proto//cpp:deps.bzl", "cpp_proto_library")

cpp_proto_library()

BUILD.bazel

load("@build_stack_rules_proto//cpp:cpp_proto_library.bzl", "cpp_proto_library")

cpp_proto_library(
    name = "person_cpp_library",
    deps = ["@build_stack_rules_proto//example/proto:person_proto"],
)

Mandatory Attributes

NameTypeDefaultDescription
depslist<ProtoInfo>[]List of labels that provide a ProtoInfo (such as native.proto_library)

Optional Attributes

NameTypeDefaultDescription
verboseint0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc

cpp_grpc_library

Generates .h,.cc protobuf+gRPC library

WORKSPACE

load("@build_stack_rules_proto//cpp:deps.bzl", "cpp_grpc_library")

cpp_grpc_library()

load("@com_github_grpc_grpc//bazel:grpc_deps.bzl", "grpc_deps")

grpc_deps()

BUILD.bazel

load("@build_stack_rules_proto//cpp:cpp_grpc_library.bzl", "cpp_grpc_library")

cpp_grpc_library(
    name = "greeter_cpp_library",
    deps = ["@build_stack_rules_proto//example/proto:greeter_grpc"],
)

Mandatory Attributes

NameTypeDefaultDescription
depslist<ProtoInfo>[]List of labels that provide a ProtoInfo (such as native.proto_library)

Optional Attributes

NameTypeDefaultDescription
verboseint0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc