1# Copyright 2020 The Pigweed Authors 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); you may not 4# use this file except in compliance with the License. You may obtain a copy of 5# the License at 6# 7# https://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12# License for the specific language governing permissions and limitations under 13# the License. 14load("@rules_proto//proto:defs.bzl", "proto_library") 15load("@com_google_protobuf//:protobuf.bzl", "py_proto_library") 16load("//pw_build:pigweed.bzl", "pw_cc_test") 17 18package(default_visibility = ["//visibility:public"]) 19 20licenses(["notice"]) 21 22# TODO(frolv): Figure out how to support nanopb and pwpb codegen in Bazel. 23filegroup( 24 name = "nanopb_test", 25 srcs = ["nanopb_test.cc"], 26) 27 28filegroup( 29 name = "pwpb_test", 30 srcs = ["pwpb_test.cc"], 31) 32 33py_proto_library( 34 name = "pw_protobuf_compiler_protos", 35 srcs = [ 36 "pw_protobuf_compiler_protos/nested/more_nesting/test.proto", 37 "pw_protobuf_compiler_protos/test.proto", 38 ], 39) 40 41proto_library( 42 name = "test_protos", 43 srcs = [ 44 "pw_protobuf_compiler_protos/nested/more_nesting/test.proto", 45 "pw_protobuf_compiler_protos/test.proto", 46 ], 47) 48 49pw_cc_test( 50 name = "nested_packages_test", 51 srcs = ["nested_packages_test.cc"], 52 deps = [ 53 "//pw_protobuf_compiler/pw_nested_packages:aggregate_pw_proto.pwpb", 54 "//pw_protobuf_compiler/pw_nested_packages:aggregate_wrapper_pw_proto.pwpb", 55 "//pw_protobuf_compiler/pw_nested_packages/data_type/id:id_pw_proto.pwpb", 56 "//pw_protobuf_compiler/pw_nested_packages/data_type/thing:thing_pw_proto.pwpb", 57 "//pw_protobuf_compiler/pw_nested_packages/data_type/thing:type_of_thing_pw_proto.pwpb", 58 "//pw_unit_test", 59 ], 60) 61