Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 1 | # Copyright (c) 2014 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 | |
mbonadei | 9aa3f0a | 2017-01-24 06:58:22 -0800 | [diff] [blame] | 9 | import("../../webrtc.gni") |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 10 | |
Patrik Höglund | 7613454 | 2018-01-02 09:15:05 +0100 | [diff] [blame] | 11 | config("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 | |
kjellander | b62dbbe | 2016-09-23 00:38:52 -0700 | [diff] [blame] | 19 | rtc_static_library("congestion_controller") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 20 | visibility = [ "*" ] |
Patrik Höglund | 7613454 | 2018-01-02 09:15:05 +0100 | [diff] [blame] | 21 | configs += [ ":bwe_test_logging" ] |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 22 | sources = [ |
Sebastian Jansson | e4be6da | 2018-02-15 16:51:41 +0100 | [diff] [blame] | 23 | "include/network_changed_observer.h", |
nisse | 559af38 | 2017-03-21 06:41:12 -0700 | [diff] [blame] | 24 | "include/receive_side_congestion_controller.h", |
| 25 | "include/send_side_congestion_controller.h", |
Sebastian Jansson | dfde334 | 2018-02-22 12:32:27 +0100 | [diff] [blame] | 26 | "include/send_side_congestion_controller_interface.h", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 27 | "probe_controller.cc", |
| 28 | "probe_controller.h", |
nisse | 559af38 | 2017-03-21 06:41:12 -0700 | [diff] [blame] | 29 | "receive_side_congestion_controller.cc", |
| 30 | "send_side_congestion_controller.cc", |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 31 | ] |
| 32 | |
Olga Sharonova | 44e57be | 2017-12-20 13:13:32 +0000 | [diff] [blame] | 33 | # TODO(jschuh): Bug 1348: fix this warning. |
| 34 | configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] |
| 35 | |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 36 | if (!build_with_chromium && is_clang) { |
| 37 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 38 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 39 | } |
| 40 | |
| 41 | deps = [ |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 42 | ":delay_based_bwe", |
| 43 | ":estimators", |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 44 | ":transport_feedback", |
mbonadei | 1140f97 | 2017-04-26 03:38:35 -0700 | [diff] [blame] | 45 | "..:module_api", |
mbonadei | 49f465f | 2016-12-28 04:43:46 -0800 | [diff] [blame] | 46 | "../..:webrtc_common", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 47 | "../../rtc_base:checks", |
| 48 | "../../rtc_base:rate_limiter", |
mbonadei | 49f465f | 2016-12-28 04:43:46 -0800 | [diff] [blame] | 49 | "../../system_wrappers", |
Mirko Bonadei | a498ae8 | 2017-12-06 09:17:14 +0100 | [diff] [blame] | 50 | "../../system_wrappers:field_trial_api", |
| 51 | "../../system_wrappers:metrics_api", |
Ilya Nikolaevskiy | 2ffe3e8 | 2018-01-17 19:57:24 +0000 | [diff] [blame] | 52 | "../../system_wrappers:runtime_enabled_features_api", |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 53 | "../bitrate_controller", |
| 54 | "../pacing", |
mbonadei | 49f465f | 2016-12-28 04:43:46 -0800 | [diff] [blame] | 55 | "../remote_bitrate_estimator", |
Mirko Bonadei | b5728d9 | 2017-12-06 07:51:33 +0100 | [diff] [blame] | 56 | "../rtp_rtcp:rtp_rtcp_format", |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 57 | ] |
Dan Minor | 9c68613 | 2018-01-15 10:20:00 -0500 | [diff] [blame] | 58 | |
| 59 | if (!build_with_mozilla) { |
| 60 | deps += [ "../../rtc_base:rtc_base" ] |
| 61 | } |
Stefan Holmer | 80e1207 | 2016-02-23 13:30:42 +0100 | [diff] [blame] | 62 | } |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 63 | |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 64 | rtc_static_library("transport_feedback") { |
| 65 | visibility = [ "*" ] |
| 66 | sources = [ |
| 67 | "send_time_history.cc", |
| 68 | "send_time_history.h", |
| 69 | "transport_feedback_adapter.cc", |
| 70 | "transport_feedback_adapter.h", |
| 71 | ] |
| 72 | |
| 73 | deps = [ |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 74 | "../../modules:module_api", |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 75 | "../../rtc_base:checks", |
| 76 | "../../rtc_base:rtc_base_approved", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 77 | "../../system_wrappers:system_wrappers", |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 78 | "../rtp_rtcp:rtp_rtcp_format", |
| 79 | ] |
| 80 | } |
| 81 | |
Danil Chapovalov | bda5068 | 2018-02-14 09:08:28 +0000 | [diff] [blame] | 82 | rtc_source_set("estimators") { |
| 83 | configs += [ ":bwe_test_logging" ] |
| 84 | sources = [ |
| 85 | "acknowledged_bitrate_estimator.cc", |
| 86 | "acknowledged_bitrate_estimator.h", |
| 87 | "bitrate_estimator.cc", |
| 88 | "bitrate_estimator.h", |
| 89 | "delay_increase_detector_interface.h", |
| 90 | "median_slope_estimator.cc", |
| 91 | "median_slope_estimator.h", |
| 92 | "probe_bitrate_estimator.cc", |
| 93 | "probe_bitrate_estimator.h", |
| 94 | "trendline_estimator.cc", |
| 95 | "trendline_estimator.h", |
| 96 | ] |
| 97 | |
| 98 | # TODO(jschuh): Bug 1348: fix this warning. |
| 99 | configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] |
| 100 | |
| 101 | if (!build_with_chromium && is_clang) { |
| 102 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 103 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 104 | } |
| 105 | |
| 106 | deps = [ |
| 107 | "../../api:optional", |
| 108 | "../../logging:rtc_event_bwe", |
| 109 | "../../logging:rtc_event_log_api", |
| 110 | "../../rtc_base:checks", |
| 111 | "../../rtc_base:rtc_base_approved", |
| 112 | "../../rtc_base:rtc_numerics", |
| 113 | "../../system_wrappers:field_trial_api", |
| 114 | "../../system_wrappers:metrics_api", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 115 | "../remote_bitrate_estimator:remote_bitrate_estimator", |
Danil Chapovalov | bda5068 | 2018-02-14 09:08:28 +0000 | [diff] [blame] | 116 | "../rtp_rtcp:rtp_rtcp_format", |
| 117 | ] |
| 118 | } |
| 119 | |
| 120 | rtc_source_set("delay_based_bwe") { |
| 121 | configs += [ ":bwe_test_logging" ] |
| 122 | sources = [ |
| 123 | "delay_based_bwe.cc", |
| 124 | "delay_based_bwe.h", |
| 125 | ] |
| 126 | deps = [ |
| 127 | ":estimators", |
| 128 | "../../:typedefs", |
| 129 | "../../logging:rtc_event_bwe", |
| 130 | "../../logging:rtc_event_log_api", |
| 131 | "../../rtc_base:checks", |
| 132 | "../../rtc_base:rtc_base_approved", |
| 133 | "../../system_wrappers:field_trial_api", |
| 134 | "../../system_wrappers:metrics_api", |
| 135 | "../pacing", |
| 136 | "../remote_bitrate_estimator", |
| 137 | ] |
| 138 | |
| 139 | if (!build_with_chromium && is_clang) { |
| 140 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 141 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 142 | } |
| 143 | } |
| 144 | |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 145 | if (rtc_include_tests) { |
| 146 | rtc_source_set("congestion_controller_unittests") { |
| 147 | testonly = true |
kjellander | e0629c0 | 2017-04-25 04:04:50 -0700 | [diff] [blame] | 148 | |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 149 | sources = [ |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 150 | "acknowledged_bitrate_estimator_unittest.cc", |
elad.alon | 5bbf43f | 2017-03-09 06:40:08 -0800 | [diff] [blame] | 151 | "congestion_controller_unittests_helper.cc", |
| 152 | "congestion_controller_unittests_helper.h", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 153 | "delay_based_bwe_unittest.cc", |
| 154 | "delay_based_bwe_unittest_helper.cc", |
| 155 | "delay_based_bwe_unittest_helper.h", |
| 156 | "median_slope_estimator_unittest.cc", |
| 157 | "probe_bitrate_estimator_unittest.cc", |
| 158 | "probe_controller_unittest.cc", |
Niels Möller | 245f17e | 2017-08-21 10:45:07 +0200 | [diff] [blame] | 159 | "receive_side_congestion_controller_unittest.cc", |
| 160 | "send_side_congestion_controller_unittest.cc", |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 161 | "send_time_history_unittest.cc", |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 162 | "transport_feedback_adapter_unittest.cc", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 163 | "trendline_estimator_unittest.cc", |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 164 | ] |
| 165 | deps = [ |
| 166 | ":congestion_controller", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 167 | ":delay_based_bwe", |
| 168 | ":estimators", |
zstein | 7cb69d5 | 2017-05-08 11:52:38 -0700 | [diff] [blame] | 169 | ":mock_congestion_controller", |
Stefan Holmer | 4dbc7e4 | 2018-01-26 15:09:41 +0100 | [diff] [blame] | 170 | ":transport_feedback", |
Patrik Höglund | 731082c | 2018-01-03 09:08:20 +0100 | [diff] [blame] | 171 | "../../logging:mocks", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 172 | "../../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 173 | "../../rtc_base:rtc_base", |
| 174 | "../../rtc_base:rtc_base_approved", |
| 175 | "../../rtc_base:rtc_base_tests_utils", |
Mirko Bonadei | a498ae8 | 2017-12-06 09:17:14 +0100 | [diff] [blame] | 176 | "../../system_wrappers", |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 177 | "../../test:field_trial", |
| 178 | "../../test:test_support", |
Sebastian Jansson | ea86bb7 | 2018-02-14 16:53:38 +0000 | [diff] [blame] | 179 | "../bitrate_controller:bitrate_controller", |
Patrik Höglund | 94dc177 | 2018-01-02 14:20:17 +0100 | [diff] [blame] | 180 | "../bitrate_controller:mocks", |
mbonadei | 334f9e6 | 2017-09-04 04:57:11 -0700 | [diff] [blame] | 181 | "../pacing:mock_paced_sender", |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 182 | "../pacing:pacing", |
| 183 | "../remote_bitrate_estimator:remote_bitrate_estimator", |
Mirko Bonadei | b5728d9 | 2017-12-06 07:51:33 +0100 | [diff] [blame] | 184 | "../rtp_rtcp:rtp_rtcp_format", |
Sebastian Jansson | 56da2f7 | 2018-02-28 13:07:28 +0100 | [diff] [blame^] | 185 | "rtp:congestion_controller_unittests", |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 186 | ] |
| 187 | if (!build_with_chromium && is_clang) { |
| 188 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 189 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 190 | } |
| 191 | } |
zstein | 7cb69d5 | 2017-05-08 11:52:38 -0700 | [diff] [blame] | 192 | |
| 193 | rtc_source_set("mock_congestion_controller") { |
| 194 | testonly = true |
| 195 | sources = [ |
| 196 | "include/mock/mock_congestion_observer.h", |
zstein | 7cb69d5 | 2017-05-08 11:52:38 -0700 | [diff] [blame] | 197 | ] |
| 198 | deps = [ |
| 199 | ":congestion_controller", |
| 200 | "../../test:test_support", |
| 201 | ] |
| 202 | } |
ehmaldonado | 3626865 | 2017-01-19 08:27:11 -0800 | [diff] [blame] | 203 | } |