1# Copyright 2023 Google LLC. 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of 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, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14 15load("@rules_cc//cc:defs.bzl", "cc_library") 16load("@rules_proto//proto:defs.bzl", "proto_library") 17 18package(default_visibility = ["//visibility:public"]) 19 20proto_library( 21 name = "transcript_proto", 22 srcs = ["transcript.proto"], 23 deps = ["//act:act_proto"], 24) 25 26cc_proto_library( 27 name = "transcript_cc_proto", 28 deps = [":transcript_proto"], 29) 30 31cc_binary( 32 name = "generate_transcript", 33 srcs = ["generate_transcript.cc"], 34 deps = [ 35 ":transcript_cc_proto", 36 "//act", 37 "//act:act_cc_proto", 38 "//act/act_v0", 39 "//act/act_v0:act_v0_cc_proto", 40 "//act/act_v0:parameters", 41 "@com_google_absl//absl/flags:flag", 42 "@com_google_absl//absl/flags:parse", 43 "@com_google_absl//absl/log", 44 "@com_google_absl//absl/log:check", 45 "@com_google_absl//absl/strings", 46 "@private_join_and_compute//private_join_and_compute/util:proto_util", 47 "@private_join_and_compute//private_join_and_compute/util:status_includes", 48 ], 49) 50 51filegroup( 52 name = "transcripts", 53 testonly = 1, 54 srcs = glob(["transcripts/*"]), 55) 56 57cc_test( 58 name = "golden_transcript_test", 59 srcs = ["golden_transcript_test.cc"], 60 data = [ 61 ":transcripts", 62 ], 63 deps = [ 64 ":transcript_cc_proto", 65 "//act", 66 "//act:act_cc_proto", 67 "//act/act_v0", 68 "//act/act_v0:act_v0_cc_proto", 69 "//act/act_v0:parameters", 70 "@com_github_google_googletest//:gtest_main", 71 "@private_join_and_compute//private_join_and_compute/util:proto_util", 72 "@private_join_and_compute//private_join_and_compute/util:status_includes", 73 "@private_join_and_compute//private_join_and_compute/util:status_testing_includes", 74 ], 75) 76