From ef22086980e148da5e8264647b96ccf1f7d1feaf Mon Sep 17 00:00:00 2001 From: Stanley Cheung Date: Thu, 21 May 2020 12:46:35 -0700 Subject: [PATCH] Fix :protobuf_objc bazel target (#7538) * Potential 3.12 ObjC bazel patch * Add test targets to bazel test * Remove :protobuf_objc test target --- BUILD | 30 ++++++++++++++++++++---------- kokoro/linux/bazel/build.sh | 3 +++ 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/BUILD b/BUILD index 8ab4cb413e..b32a1f1610 100644 --- a/BUILD +++ b/BUILD @@ -969,6 +969,16 @@ alias( objc_library( name = "protobuf_objc", hdrs = [ + "objectivec/GPBAny.pbobjc.h", + "objectivec/GPBApi.pbobjc.h", + "objectivec/GPBDuration.pbobjc.h", + "objectivec/GPBEmpty.pbobjc.h", + "objectivec/GPBFieldMask.pbobjc.h", + "objectivec/GPBSourceContext.pbobjc.h", + "objectivec/GPBStruct.pbobjc.h", + "objectivec/GPBTimestamp.pbobjc.h", + "objectivec/GPBType.pbobjc.h", + "objectivec/GPBWrappers.pbobjc.h", "objectivec/GPBArray.h", "objectivec/GPBBootstrap.h", "objectivec/GPBCodedInputStream.h", @@ -1017,6 +1027,16 @@ objc_library( "objectivec", ], non_arc_srcs = [ + "objectivec/GPBAny.pbobjc.m", + "objectivec/GPBApi.pbobjc.m", + "objectivec/GPBDuration.pbobjc.m", + "objectivec/GPBEmpty.pbobjc.m", + "objectivec/GPBFieldMask.pbobjc.m", + "objectivec/GPBSourceContext.pbobjc.m", + "objectivec/GPBStruct.pbobjc.m", + "objectivec/GPBTimestamp.pbobjc.m", + "objectivec/GPBType.pbobjc.m", + "objectivec/GPBWrappers.pbobjc.m", "objectivec/GPBArray.m", "objectivec/GPBCodedInputStream.m", "objectivec/GPBCodedOutputStream.m", @@ -1031,16 +1051,6 @@ objc_library( "objectivec/GPBUtilities.m", "objectivec/GPBWellKnownTypes.m", "objectivec/GPBWireFormat.m", - "objectivec/google/protobuf/Any.pbobjc.m", - "objectivec/google/protobuf/Api.pbobjc.m", - "objectivec/google/protobuf/Duration.pbobjc.m", - "objectivec/google/protobuf/Empty.pbobjc.m", - "objectivec/google/protobuf/FieldMask.pbobjc.m", - "objectivec/google/protobuf/SourceContext.pbobjc.m", - "objectivec/google/protobuf/Struct.pbobjc.m", - "objectivec/google/protobuf/Timestamp.pbobjc.m", - "objectivec/google/protobuf/Type.pbobjc.m", - "objectivec/google/protobuf/Wrappers.pbobjc.m", ], visibility = ["//visibility:public"], ) diff --git a/kokoro/linux/bazel/build.sh b/kokoro/linux/bazel/build.sh index 9355ebae30..5f34bea30e 100755 --- a/kokoro/linux/bazel/build.sh +++ b/kokoro/linux/bazel/build.sh @@ -26,6 +26,9 @@ trap print_test_logs EXIT bazel test --copt=-Werror --host_copt=-Werror \ //:build_files_updated_unittest \ //java/... \ + //:protoc \ + //:protobuf \ + //:protobuf_python \ //:protobuf_test \ @com_google_protobuf//:cc_proto_blacklist_test trap - EXIT