xref: /aosp_15_r20/external/anonymous-counting-tokens/act/BUILD (revision a26f13018b999b025c962678da434c0a5aec4dae)
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
15# Contains implementations for Anonymous Counting Tokens.
16
17load("@rules_cc//cc:defs.bzl", "cc_library")
18load("@rules_proto//proto:defs.bzl", "proto_library")
19
20package(default_visibility = ["//visibility:public"])
21
22proto_library(
23    name = "act_proto",
24    srcs = ["act.proto"],
25    deps = ["//act/act_v0:act_v0_proto"],
26)
27
28cc_proto_library(
29    name = "act_cc_proto",
30    deps = [":act_proto"],
31)
32
33cc_library(
34    name = "act",
35    hdrs = ["act.h"],
36    deps = [
37        ":act_cc_proto",
38        "@private_join_and_compute//private_join_and_compute/util:status_includes",
39    ],
40)
41
42cc_library(
43    name = "fake_act",
44    srcs = ["fake_act.cc"],
45    hdrs = ["fake_act.h"],
46    deps = [
47        ":act",
48        ":act_cc_proto",
49        "@private_join_and_compute//private_join_and_compute/crypto:bn_util",
50        "@private_join_and_compute//private_join_and_compute/util:status_includes",
51    ],
52)
53
54cc_test(
55    name = "fake_act_test",
56    srcs = [
57        "fake_act_test.cc",
58    ],
59    deps = [
60        ":fake_act",
61        "@com_github_google_googletest//:gtest_main",
62        "@private_join_and_compute//private_join_and_compute/util:status_includes",
63        "@private_join_and_compute//private_join_and_compute/util:status_testing_includes",
64    ],
65)
66