blob: 719c728a31f9e14d7fe43b49d7b6d6f2ab688040 [file] [log] [blame]
hbos615d3012016-08-24 01:33:13 -07001# Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
2#
3# Use of this source code is governed by a BSD-style license
4# that can be found in the LICENSE file in the root of the source
5# tree. An additional intellectual property rights grant can be found
6# in the file PATENTS. All contributing project authors may
7# be found in the AUTHORS file in the root of the source tree.
8
9import("../build/webrtc.gni")
hbos615d3012016-08-24 01:33:13 -070010
11group("stats") {
kjellander705ecc52016-09-15 00:53:26 -070012 public_deps = [
hbos615d3012016-08-24 01:33:13 -070013 ":rtc_stats",
14 ]
15}
16
17# GYP version: webrtc/stats/stats.gyp:rtc_stats
kjellanderb62dbbe2016-09-23 00:38:52 -070018rtc_static_library("rtc_stats") {
hbos615d3012016-08-24 01:33:13 -070019 cflags = []
20 sources = [
21 "rtcstats.cc",
hbosd565b732016-08-30 14:04:35 -070022 "rtcstats_objects.cc",
hbos615d3012016-08-24 01:33:13 -070023 "rtcstatsreport.cc",
24 ]
25
hbos615d3012016-08-24 01:33:13 -070026 deps = [
hbos74e1a4f2016-09-15 23:33:01 -070027 "../api:rtc_stats_api",
28 "../base:rtc_base_approved",
hbos615d3012016-08-24 01:33:13 -070029 ]
30}
31
hbos27e177c2016-09-19 06:05:56 -070032rtc_source_set("rtc_stats_test_utils") {
33 cflags = []
34 sources = [
35 "test/rtcteststats.cc",
36 "test/rtcteststats.h",
37 ]
38
hbos27e177c2016-09-19 06:05:56 -070039 deps = [
40 ":rtc_stats",
41 "../api:rtc_stats_api",
42 ]
43}
44
hbos615d3012016-08-24 01:33:13 -070045if (rtc_include_tests) {
ehmaldonado38a21322016-09-02 04:10:34 -070046 rtc_test("rtc_stats_unittests") {
hbos615d3012016-08-24 01:33:13 -070047 testonly = true
48 sources = [
49 "rtcstats_unittest.cc",
hbos6d183ac2016-08-29 07:20:33 -070050 "rtcstatsreport_unittest.cc",
hbos615d3012016-08-24 01:33:13 -070051 ]
52
kjellandere40a7ee2016-10-16 23:56:12 -070053 if (!build_with_chromium && is_clang) {
hbosd565b732016-08-30 14:04:35 -070054 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -070055 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
hbosd565b732016-08-30 14:04:35 -070056 }
57
hbos615d3012016-08-24 01:33:13 -070058 deps = [
59 ":rtc_stats",
hbos27e177c2016-09-19 06:05:56 -070060 ":rtc_stats_test_utils",
hbos615d3012016-08-24 01:33:13 -070061 "../base:rtc_base_tests_utils",
62 "../system_wrappers:metrics_default",
63 "//testing/gmock",
64 ]
65
66 if (is_android) {
67 deps += [ "//testing/android/native_test:native_test_native_code" ]
68 }
hbos615d3012016-08-24 01:33:13 -070069 }
70}