blob: e802f3bd2d90954a39885777ef6a94279c8016d1 [file] [log] [blame]
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +01001# Copyright (c) 2018 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("../../../webrtc.gni")
10
11config("bwe_test_logging") {
12 if (rtc_enable_bwe_test_logging) {
13 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=1" ]
14 } else {
15 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=0" ]
16 }
17}
18
19rtc_static_library("goog_cc") {
20 configs += [ ":bwe_test_logging" ]
21 sources = [
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010022 "goog_cc_factory.cc",
23 "goog_cc_network_control.cc",
24 "goog_cc_network_control.h",
25 "include/goog_cc_factory.h",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010026 ]
27
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010028 if (!build_with_chromium && is_clang) {
29 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
30 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
31 }
32
33 deps = [
Sebastian Janssonf9f49a32018-06-25 17:56:08 +020034 ":alr_detector",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010035 ":delay_based_bwe",
36 ":estimators",
Sebastian Janssonb2ecc3d2018-07-13 17:22:01 +020037 ":probe_controller",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010038 "../..:module_api",
39 "../../..:webrtc_common",
40 "../../../:typedefs",
Sebastian Janssonc6c44262018-05-09 10:33:39 +020041 "../../../api/transport:network_control",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010042 "../../../logging:rtc_event_log_api",
43 "../../../logging:rtc_event_pacing",
44 "../../../rtc_base:checks",
45 "../../../rtc_base:rtc_base_approved",
46 "../../../rtc_base/experiments:alr_experiment",
47 "../../../system_wrappers",
48 "../../../system_wrappers:field_trial_api",
49 "../../../system_wrappers:metrics_api",
50 "../../bitrate_controller",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010051 "../../remote_bitrate_estimator",
52 "../../rtp_rtcp:rtp_rtcp_format",
Karl Wiberg918f50c2018-07-05 11:40:33 +020053 "//third_party/abseil-cpp/absl/memory",
Danil Chapovalov0040b662018-06-18 10:48:16 +020054 "//third_party/abseil-cpp/absl/types:optional",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010055 ]
56}
57
Sebastian Janssonf9f49a32018-06-25 17:56:08 +020058rtc_source_set("alr_detector") {
59 sources = [
60 "alr_detector.cc",
61 "alr_detector.h",
62 ]
63 if (!build_with_chromium && is_clang) {
64 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
65 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
66 }
67 deps = [
68 "../../..:webrtc_common",
69 "../../../:typedefs",
70 "../../../logging:rtc_event_log_api",
71 "../../../logging:rtc_event_pacing",
72 "../../../rtc_base:checks",
73 "../../../rtc_base:rtc_base_approved",
74 "../../../rtc_base/experiments:alr_experiment",
75 "../../../system_wrappers:field_trial_api",
76 "../../pacing:interval_budget",
Karl Wiberg918f50c2018-07-05 11:40:33 +020077 "//third_party/abseil-cpp/absl/memory",
Sebastian Janssonf9f49a32018-06-25 17:56:08 +020078 "//third_party/abseil-cpp/absl/types:optional",
79 ]
80}
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +010081rtc_source_set("estimators") {
82 configs += [ ":bwe_test_logging" ]
83 sources = [
84 "acknowledged_bitrate_estimator.cc",
85 "acknowledged_bitrate_estimator.h",
86 "bitrate_estimator.cc",
87 "bitrate_estimator.h",
88 "delay_increase_detector_interface.h",
89 "median_slope_estimator.cc",
90 "median_slope_estimator.h",
91 "probe_bitrate_estimator.cc",
92 "probe_bitrate_estimator.h",
93 "trendline_estimator.cc",
94 "trendline_estimator.h",
95 ]
96
97 # TODO(jschuh): Bug 1348: fix this warning.
98 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
99
100 if (!build_with_chromium && is_clang) {
101 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
102 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
103 }
104
105 deps = [
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100106 "../../../logging:rtc_event_bwe",
107 "../../../logging:rtc_event_log_api",
108 "../../../rtc_base:checks",
109 "../../../rtc_base:rtc_base_approved",
110 "../../../rtc_base:rtc_numerics",
Karl Wiberg12edf4c2018-03-07 14:18:56 +0100111 "../../../rtc_base:safe_minmax",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100112 "../../../system_wrappers:field_trial_api",
113 "../../../system_wrappers:metrics_api",
114 "../../remote_bitrate_estimator",
115 "../../rtp_rtcp:rtp_rtcp_format",
Karl Wiberg918f50c2018-07-05 11:40:33 +0200116 "//third_party/abseil-cpp/absl/memory",
Danil Chapovalov0040b662018-06-18 10:48:16 +0200117 "//third_party/abseil-cpp/absl/types:optional",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100118 ]
119}
120
121rtc_source_set("delay_based_bwe") {
122 configs += [ ":bwe_test_logging" ]
123 sources = [
124 "delay_based_bwe.cc",
125 "delay_based_bwe.h",
126 ]
127
128 deps = [
129 ":estimators",
130 "../../../:typedefs",
131 "../../../logging:rtc_event_bwe",
132 "../../../logging:rtc_event_log_api",
133 "../../../rtc_base:checks",
134 "../../../rtc_base:rtc_base_approved",
135 "../../../system_wrappers:field_trial_api",
136 "../../../system_wrappers:metrics_api",
137 "../../pacing",
138 "../../remote_bitrate_estimator",
Karl Wiberg918f50c2018-07-05 11:40:33 +0200139 "//third_party/abseil-cpp/absl/memory",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100140 ]
141
142 if (!build_with_chromium && is_clang) {
143 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
144 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
145 }
146}
147
Sebastian Janssonb2ecc3d2018-07-13 17:22:01 +0200148rtc_source_set("probe_controller") {
149 sources = [
150 "probe_controller.cc",
151 "probe_controller.h",
152 ]
153
154 deps = [
155 "../../../api/transport:network_control",
156 "../../../logging:rtc_event_log_api",
157 "../../../logging:rtc_event_pacing",
158 "../../../rtc_base:checks",
159 "../../../rtc_base:rtc_base_approved",
160 "../../../system_wrappers:field_trial_api",
161 "../../../system_wrappers:metrics_api",
162 "//third_party/abseil-cpp/absl/types:optional",
163 ]
164
165 if (!build_with_chromium && is_clang) {
166 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
167 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
168 }
169}
170
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100171if (rtc_include_tests) {
Sebastian Jansson13171bd2018-07-03 18:11:45 +0200172 rtc_source_set("test_goog_cc_printer") {
173 testonly = true
174 sources = [
175 "test/goog_cc_printer.cc",
176 "test/goog_cc_printer.h",
177 ]
178 deps = [
179 ":goog_cc",
180 "..:test_controller_printer",
181 ]
182 }
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100183 rtc_source_set("goog_cc_unittests") {
184 testonly = true
185
186 sources = [
187 "acknowledged_bitrate_estimator_unittest.cc",
188 "alr_detector_unittest.cc",
189 "delay_based_bwe_unittest.cc",
190 "delay_based_bwe_unittest_helper.cc",
191 "delay_based_bwe_unittest_helper.h",
192 "median_slope_estimator_unittest.cc",
193 "probe_bitrate_estimator_unittest.cc",
194 "probe_controller_unittest.cc",
195 "trendline_estimator_unittest.cc",
196 ]
197 deps = [
Sebastian Janssonf9f49a32018-06-25 17:56:08 +0200198 ":alr_detector",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100199 ":delay_based_bwe",
200 ":estimators",
201 ":goog_cc",
Sebastian Janssonb2ecc3d2018-07-13 17:22:01 +0200202 ":probe_controller",
Sebastian Janssonc6c44262018-05-09 10:33:39 +0200203 "../../../api/transport:network_control",
204 "../../../api/transport:network_control_test",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100205 "../../../rtc_base:checks",
206 "../../../rtc_base:rtc_base_approved",
207 "../../../rtc_base:rtc_base_tests_utils",
208 "../../../rtc_base/experiments:alr_experiment",
209 "../../../system_wrappers",
210 "../../../test:field_trial",
211 "../../../test:test_support",
212 "../../pacing",
213 "../../remote_bitrate_estimator",
214 "../../rtp_rtcp:rtp_rtcp_format",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100215 "//testing/gmock",
Karl Wiberg918f50c2018-07-05 11:40:33 +0200216 "//third_party/abseil-cpp/absl/memory",
Sebastian Janssonfc7ec8e2018-02-28 16:48:00 +0100217 ]
218 if (!build_with_chromium && is_clang) {
219 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
220 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
221 }
222 }
223}