blob: d1c08bdd5112666f8d501db4394afecc0fe41bd3 [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")
10import("//testing/test.gni")
11
12group("stats") {
13 deps = [
14 ":rtc_stats",
15 ]
16}
17
18# GYP version: webrtc/stats/stats.gyp:rtc_stats
19source_set("rtc_stats") {
20 cflags = []
21 sources = [
22 "rtcstats.cc",
hbosd565b732016-08-30 14:04:35 -070023 "rtcstats_objects.cc",
24 "rtcstatscollector.cc",
25 "rtcstatscollector.h",
hbos615d3012016-08-24 01:33:13 -070026 "rtcstatsreport.cc",
27 ]
28
29 configs += [ "..:common_config" ]
30 public_configs = [ "..:common_inherited_config" ]
31
hbosd565b732016-08-30 14:04:35 -070032 if (is_clang) {
33 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
34 configs -= [ "//build/config/clang:find_bad_constructs" ]
35 }
36
hbos615d3012016-08-24 01:33:13 -070037 deps = [
38 "../api:libjingle_peerconnection",
39 ]
40}
41
42if (rtc_include_tests) {
43 # GYP version: webrtc/stats/stats.gyp:rtc_stats_unittests
44 test("rtc_stats_unittests") {
45 testonly = true
46 sources = [
47 "rtcstats_unittest.cc",
hbosd565b732016-08-30 14:04:35 -070048 "rtcstatscollector_unittest.cc",
hbos6d183ac2016-08-29 07:20:33 -070049 "rtcstatsreport_unittest.cc",
hbos615d3012016-08-24 01:33:13 -070050 ]
51
52 configs += [ "..:common_config" ]
53 public_configs = [ "..:common_inherited_config" ]
54
hbosd565b732016-08-30 14:04:35 -070055 if (is_clang) {
56 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
57 configs -= [ "//build/config/clang:find_bad_constructs" ]
58 }
59
hbos615d3012016-08-24 01:33:13 -070060 deps = [
61 ":rtc_stats",
62 "../base:rtc_base_tests_utils",
63 "../system_wrappers:metrics_default",
64 "//testing/gmock",
65 ]
66
67 if (is_android) {
68 deps += [ "//testing/android/native_test:native_test_native_code" ]
69 }
hbos615d3012016-08-24 01:33:13 -070070 }
71}