mirror of
https://github.com/googleapis/googleapis.git
synced 2026-08-14 12:42:59 +02:00
This makes googleapis forward compatible with Bazel incompatible change https://github.com/bazelbuild/bazel/issues/8922. This CL was created by adding @rules_proto to the WORKSPACE file and then running: find . -name BUILD.bazel | \ while read build; do \ buildifier --lint=fix --warnings=load $build; \ done Since buildifier cannot be told not to reformat the BUILD file, some files are reformatted. PiperOrigin-RevId: 280356106
55 lines
1.6 KiB
Text
55 lines
1.6 KiB
Text
load("@rules_proto//proto:defs.bzl", "proto_library")
|
|
|
|
# This is an API workspace, having public visibility by default makes perfect sense.
|
|
package(default_visibility = ["//visibility:public"])
|
|
|
|
##############################################################################
|
|
# Common
|
|
##############################################################################
|
|
load("@com_google_googleapis_imports//:imports.bzl", "proto_library_with_info")
|
|
|
|
proto_library(
|
|
name = "source_proto",
|
|
srcs = [
|
|
"source.proto",
|
|
],
|
|
deps = [],
|
|
)
|
|
|
|
proto_library_with_info(
|
|
name = "source_proto_with_info",
|
|
deps = [":source_proto"],
|
|
)
|
|
|
|
##############################################################################
|
|
# Java
|
|
##############################################################################
|
|
load(
|
|
"@com_google_googleapis_imports//:imports.bzl",
|
|
"java_grpc_library",
|
|
"java_proto_library",
|
|
)
|
|
|
|
java_proto_library(
|
|
name = "source_java_proto",
|
|
deps = [":source_proto"],
|
|
)
|
|
|
|
java_grpc_library(
|
|
name = "source_java_grpc",
|
|
srcs = [":source_proto"],
|
|
deps = [":source_java_proto"],
|
|
)
|
|
|
|
##############################################################################
|
|
# Go
|
|
##############################################################################
|
|
load("@com_google_googleapis_imports//:imports.bzl", "go_proto_library")
|
|
|
|
go_proto_library(
|
|
name = "source_go_proto",
|
|
compilers = ["@io_bazel_rules_go//proto:go_grpc"],
|
|
importpath = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/source",
|
|
protos = [":source_proto"],
|
|
deps = [],
|
|
)
|