1
    2
    3
    4
    5
    6
    7
    8
    9
   10
   11
   12
   13
   14
   15
   16
   17
   18
   19
   20
   21
   22
   23
   24
   25
   26
   27
   28
   29
   30
   31
   32
   33
   34
   35
   36
   37
   38
   39
   40
   41
   42
   43
   44
   45
   46
   47
   48
   49
   50
   51
   52
   53
   54
   55
   56
   57
   58
   59
   60
   61
   62
   63
   64
   65
   66
   67
   68
   69
   70
   71
   72
   73
   74
   75
   76
   77
   78
   79
   80
   81
   82
   83
   84
   85

media / capabilities / BUILD.gn [blame]

# Copyright 2017 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//testing/test.gni")
import("//third_party/protobuf/proto_library.gni")

proto_library("video_decode_stats_proto") {
  sources = [ "video_decode_stats.proto" ]
}

proto_library("webrtc_video_stats_proto") {
  sources = [ "webrtc_video_stats.proto" ]
}

source_set("capabilities") {
  # Do not expand the visibility here without double-checking with OWNERS, this
  # is a roll-up target which is part of the //media component. Most other DEPs
  # should be using //media and not directly DEP this roll-up target.
  visibility = [ "//media" ]

  sources = [
    "bucket_utility.cc",
    "bucket_utility.h",
    "in_memory_video_decode_stats_db_impl.cc",
    "in_memory_video_decode_stats_db_impl.h",
    "learning_helper.cc",
    "learning_helper.h",
    "pending_operations.cc",
    "pending_operations.h",
    "video_decode_stats_db.cc",
    "video_decode_stats_db.h",
    "video_decode_stats_db_impl.cc",
    "video_decode_stats_db_impl.h",
    "video_decode_stats_db_provider.cc",
    "video_decode_stats_db_provider.h",
    "webrtc_video_stats_db.cc",
    "webrtc_video_stats_db.h",
    "webrtc_video_stats_db_impl.cc",
    "webrtc_video_stats_db_impl.h",
    "webrtc_video_stats_db_provider.cc",
    "webrtc_video_stats_db_provider.h",
  ]

  public_deps = [
    ":video_decode_stats_proto",
    ":webrtc_video_stats_proto",
    "//base",
    "//components/leveldb_proto",
    "//media/base",
    "//ui/gfx/geometry",
  ]

  deps = [
    "//media/learning/common",
    "//media/learning/impl",
  ]

  configs += [ "//media:subcomponent_config" ]
}

source_set("unit_tests") {
  testonly = true
  sources = [
    "in_memory_video_decode_stats_db_unittest.cc",
    "pending_operations_unittest.cc",
    "video_decode_stats_db_impl_unittest.cc",
    "video_decode_stats_db_unittest.cc",
    "webrtc_video_stats_db_impl_unittest.cc",
    "webrtc_video_stats_db_unittest.cc",
  ]

  deps = [
    # Explicitly adding the proto lib here (in addition to "capabilities"
    # public_deps), because the generated files seem not to be available through
    # the transitive "capabilities" target (via media:test_support -> media).
    ":video_decode_stats_proto",
    ":webrtc_video_stats_proto",
    "//base/test:test_support",
    "//components/leveldb_proto:test_support",
    "//media:test_support",
    "//testing/gmock",
    "//testing/gtest",
  ]
}