| # Copyright 2019 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//third_party/protobuf/proto_library.gni") |
| |
| source_set("observation_store_update_recipient") { |
| sources = [ |
| "observation_store_update_recipient.h", |
| ] |
| } |
| |
| proto_library("observation_store_internal_proto") { |
| sources = [ |
| "observation_store_internal.proto", |
| ] |
| extra_configs = [ "$cobalt_root:cobalt_config" ] |
| import_dirs = [ |
| "//third_party/protobuf/src", |
| "$cobalt_root", |
| "$cobalt_root/src/pb", |
| ] |
| cc_generator_options = "lite" |
| generate_python = false |
| deps = [ |
| "$cobalt_root/src/lib/util:proto_serialization", |
| "$cobalt_root/src/pb", |
| ] |
| } |
| |
| source_set("observation_store") { |
| sources = [ |
| "envelope_maker.cc", |
| "envelope_maker.h", |
| "file_observation_store.cc", |
| "file_observation_store.h", |
| "memory_observation_store.cc", |
| "memory_observation_store.h", |
| "observation_store.cc", |
| "observation_store.h", |
| ] |
| deps = [ |
| ":observation_store_update_recipient", |
| "$cobalt_root/src:tracing", |
| "$cobalt_root/src/lib/statusor", |
| "$cobalt_root/src/lib/util:posix_file_system", |
| "$cobalt_root/src/lib/util:protected_fields", |
| "$cobalt_root/src/lib/util:proto_serialization", |
| "$cobalt_root/src/logger:internal_metrics", |
| "$cobalt_root/src/logger:logger_interface", |
| "//third_party/googletest:gtest_prod", |
| ] |
| public_deps = [ |
| ":observation_store_internal_proto", |
| "$cobalt_root/src:logging", |
| "$cobalt_root/src:tracing", |
| "$cobalt_root/src/lib/util:encrypted_message_util", |
| "$cobalt_root/src/pb", |
| ] |
| } |
| |
| source_set("tests") { |
| testonly = true |
| |
| sources = [ |
| "envelope_maker_test.cc", |
| "file_observation_store_test.cc", |
| ] |
| |
| deps = [ |
| ":observation_store", |
| "$cobalt_root/src/lib/util:posix_file_system", |
| "$cobalt_root/src/lib/util:proto_serialization", |
| "$cobalt_root/src/system_data:client_secret", |
| "//third_party/gflags", |
| "//third_party/googletest:gmock", |
| "//third_party/googletest:gtest", |
| ] |
| } |