BUILD.bazel 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. load("@rules_cc//cc:defs.bzl", "objc_library")
  2. load("@rules_pkg//:mappings.bzl", "pkg_files", "strip_prefix")
  3. objc_library(
  4. name = "objectivec",
  5. hdrs = [
  6. "GPBAny.pbobjc.h",
  7. "GPBApi.pbobjc.h",
  8. "GPBDuration.pbobjc.h",
  9. "GPBEmpty.pbobjc.h",
  10. "GPBFieldMask.pbobjc.h",
  11. "GPBSourceContext.pbobjc.h",
  12. "GPBStruct.pbobjc.h",
  13. "GPBTimestamp.pbobjc.h",
  14. "GPBType.pbobjc.h",
  15. "GPBWrappers.pbobjc.h",
  16. "GPBArray.h",
  17. "GPBBootstrap.h",
  18. "GPBCodedInputStream.h",
  19. "GPBCodedOutputStream.h",
  20. "GPBDescriptor.h",
  21. "GPBDictionary.h",
  22. "GPBExtensionInternals.h",
  23. "GPBExtensionRegistry.h",
  24. "GPBMessage.h",
  25. "GPBProtocolBuffers.h",
  26. "GPBProtocolBuffers_RuntimeSupport.h",
  27. "GPBRootObject.h",
  28. "GPBRuntimeTypes.h",
  29. "GPBUnknownField.h",
  30. "GPBUnknownFieldSet.h",
  31. "GPBUtilities.h",
  32. "GPBWellKnownTypes.h",
  33. "GPBWireFormat.h",
  34. "google/protobuf/Any.pbobjc.h",
  35. "google/protobuf/Api.pbobjc.h",
  36. "google/protobuf/Duration.pbobjc.h",
  37. "google/protobuf/Empty.pbobjc.h",
  38. "google/protobuf/FieldMask.pbobjc.h",
  39. "google/protobuf/SourceContext.pbobjc.h",
  40. "google/protobuf/Struct.pbobjc.h",
  41. "google/protobuf/Timestamp.pbobjc.h",
  42. "google/protobuf/Type.pbobjc.h",
  43. "google/protobuf/Wrappers.pbobjc.h",
  44. # Package private headers, but exposed because the generated sources
  45. # need to use them.
  46. "GPBArray_PackagePrivate.h",
  47. "GPBCodedInputStream_PackagePrivate.h",
  48. "GPBCodedOutputStream_PackagePrivate.h",
  49. "GPBDescriptor_PackagePrivate.h",
  50. "GPBDictionary_PackagePrivate.h",
  51. "GPBMessage_PackagePrivate.h",
  52. "GPBRootObject_PackagePrivate.h",
  53. "GPBUnknownFieldSet_PackagePrivate.h",
  54. "GPBUnknownField_PackagePrivate.h",
  55. "GPBUtilities_PackagePrivate.h",
  56. ],
  57. copts = [
  58. "-Wno-vla",
  59. ],
  60. includes = [
  61. ".",
  62. ],
  63. non_arc_srcs = [
  64. "GPBAny.pbobjc.m",
  65. "GPBApi.pbobjc.m",
  66. "GPBArray.m",
  67. "GPBCodedInputStream.m",
  68. "GPBCodedOutputStream.m",
  69. "GPBDescriptor.m",
  70. "GPBDictionary.m",
  71. "GPBDuration.pbobjc.m",
  72. "GPBEmpty.pbobjc.m",
  73. "GPBExtensionInternals.m",
  74. "GPBExtensionRegistry.m",
  75. "GPBFieldMask.pbobjc.m",
  76. "GPBMessage.m",
  77. "GPBRootObject.m",
  78. "GPBSourceContext.pbobjc.m",
  79. "GPBStruct.pbobjc.m",
  80. "GPBTimestamp.pbobjc.m",
  81. "GPBType.pbobjc.m",
  82. "GPBUnknownField.m",
  83. "GPBUnknownFieldSet.m",
  84. "GPBUtilities.m",
  85. "GPBWellKnownTypes.m",
  86. "GPBWireFormat.m",
  87. "GPBWrappers.pbobjc.m",
  88. ],
  89. visibility = ["//visibility:public"],
  90. )
  91. pkg_files(
  92. name = "dist_files",
  93. srcs = glob([
  94. "*.h",
  95. "*.m",
  96. "**/*.h",
  97. "**/*.m",
  98. "**/*.mm",
  99. "**/*.swift",
  100. "DevTools/*.sh",
  101. "DevTools/*.py",
  102. "ProtocolBuffers_iOS.xcodeproj/**/*",
  103. "ProtocolBuffers_OSX.xcodeproj/**/*",
  104. "ProtocolBuffers_tvOS.xcodeproj/**/*",
  105. "Tests/CocoaPods/**/*",
  106. "Tests/*.pddm",
  107. "Tests/*.txt",
  108. "Tests/*.plist",
  109. "Tests/*.proto",
  110. ]) + [
  111. ".clang-format",
  112. "BUILD.bazel",
  113. "README.md",
  114. "Tests/golden_message",
  115. "Tests/golden_packed_fields_message",
  116. "generate_well_known_types.sh",
  117. ],
  118. strip_prefix = strip_prefix.from_root(""),
  119. visibility = ["//pkg:__pkg__"],
  120. )