blob: 09990b16f4d296b36e5c0ed5f14016aecfc2f39c [file] [log] [blame]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +00001# 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
mbonadei9aa3f0a2017-01-24 06:58:22 -08009import("../../webrtc.gni")
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000010
kjellanderb62dbbe2016-09-23 00:38:52 -070011rtc_static_library("bitrate_controller") {
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000012 sources = [
13 "bitrate_controller_impl.cc",
14 "bitrate_controller_impl.h",
15 "include/bitrate_controller.h",
16 "send_side_bandwidth_estimation.cc",
17 "send_side_bandwidth_estimation.h",
18 ]
19
gaetano.carlucci52a57032016-09-14 05:04:36 -070020 if (rtc_enable_bwe_test_logging) {
21 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=1" ]
22 } else {
23 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=0" ]
24 }
25
kjellander8f4419b2016-06-02 02:09:52 -070026 # TODO(jschuh): Bug 1348: fix this warning.
27 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
28
kjellandere40a7ee2016-10-16 23:56:12 -070029 if (!build_with_chromium && is_clang) {
30 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -070031 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000032 }
33
Henrik Kjellander57e5fd22015-05-25 12:55:39 +020034 deps = [
Patrik Höglund08279b52017-12-19 09:33:40 +010035 "..:module_api",
36 "../../logging:rtc_event_log_api",
37 "../../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 10:40:47 -070038 "../../rtc_base:rtc_base_approved",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +020039 "../../system_wrappers",
Patrik Höglund08279b52017-12-19 09:33:40 +010040 "../../system_wrappers:field_trial_api",
41 "../../system_wrappers:metrics_api",
42 "../congestion_controller:delay_based_bwe",
43 "../pacing",
44 "../remote_bitrate_estimator:remote_bitrate_estimator",
mbonadei49f465f2016-12-28 04:43:46 -080045 "../rtp_rtcp",
Patrik Höglund08279b52017-12-19 09:33:40 +010046 "../rtp_rtcp:rtp_rtcp_format",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +020047 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000048}
ehmaldonado36268652017-01-19 08:27:11 -080049
50if (rtc_include_tests) {
51 rtc_source_set("bitrate_controller_unittests") {
52 testonly = true
kjellandere0629c02017-04-25 04:04:50 -070053
ehmaldonado36268652017-01-19 08:27:11 -080054 sources = [
55 "bitrate_controller_unittest.cc",
56 "send_side_bandwidth_estimation_unittest.cc",
57 ]
58 deps = [
59 ":bitrate_controller",
Elad Alon4a87e1c2017-10-03 16:11:34 +020060 "../../logging:rtc_event_log_api",
ehmaldonado36268652017-01-19 08:27:11 -080061 "../../test:field_trial",
62 "../../test:test_support",
mbonadei334f9e62017-09-04 04:57:11 -070063 "../pacing:mock_paced_sender",
ehmaldonado36268652017-01-19 08:27:11 -080064 "../remote_bitrate_estimator:remote_bitrate_estimator",
65 "//testing/gmock",
66 ]
67 if (!build_with_chromium && is_clang) {
68 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
69 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
70 }
71 }
72}