BUILD 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. load(
  2. "@io_bazel_rules_go//proto:def.bzl",
  3. "go_proto_library",
  4. )
  5. package(default_visibility = ["//visibility:public"])
  6. load(
  7. "@io_bazel_rules_go//go:def.bzl",
  8. "go_library",
  9. )
  10. proto_library(
  11. name = "api_proto",
  12. srcs = ["api.proto"],
  13. tags = ["automanaged"],
  14. deps = [
  15. "@go_googleapis//google/api:annotations_proto",
  16. "@gogo_special_proto//github.com/gogo/protobuf/gogoproto",
  17. ],
  18. )
  19. go_proto_library(
  20. name = "api_go_proto",
  21. compilers = ["@io_bazel_rules_go//proto:gogofast_grpc"],
  22. importpath = "go-common/app/service/main/passport-sns/api",
  23. proto = ":api_proto",
  24. tags = ["automanaged"],
  25. deps = [
  26. "@com_github_gogo_protobuf//gogoproto:go_default_library",
  27. "@go_googleapis//google/api:annotations_go_proto",
  28. ],
  29. )
  30. go_library(
  31. name = "go_default_library",
  32. srcs = ["api.bm.go"],
  33. embed = [":api_go_proto"],
  34. importpath = "go-common/app/service/main/passport-sns/api",
  35. tags = ["automanaged"],
  36. visibility = ["//visibility:public"],
  37. deps = [
  38. "//library/net/http/blademaster:go_default_library",
  39. "//library/net/http/blademaster/binding:go_default_library",
  40. "//vendor/google.golang.org/genproto/googleapis/api/annotations:go_default_library",
  41. "@com_github_gogo_protobuf//gogoproto:go_default_library",
  42. "@com_github_gogo_protobuf//proto:go_default_library",
  43. "@org_golang_google_grpc//:go_default_library",
  44. "@org_golang_x_net//context:go_default_library",
  45. ],
  46. )
  47. filegroup(
  48. name = "package-srcs",
  49. srcs = glob(["**"]),
  50. tags = ["automanaged"],
  51. visibility = ["//visibility:private"],
  52. )
  53. filegroup(
  54. name = "all-srcs",
  55. srcs = [":package-srcs"],
  56. tags = ["automanaged"],
  57. visibility = ["//visibility:public"],
  58. )