blob: 515376b2b2b91c8cf50d460103c5a560f1b2578f [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
kjellanderfb114242016-06-13 00:19:48 -07009import("../../build/webrtc.gni")
kjellanderfb114242016-06-13 00:19:48 -070010
kjellanderb62dbbe2016-09-23 00:38:52 -070011rtc_static_library("remote_bitrate_estimator") {
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000012 sources = [
pbos@webrtc.org9f79fe62014-12-04 15:34:06 +000013 "aimd_rate_control.cc",
14 "aimd_rate_control.h",
stefan64636dd2016-08-03 00:29:03 -070015 "bwe_defines.cc",
kjellander5c1d0432016-06-09 02:40:58 -070016 "include/bwe_defines.h",
17 "include/remote_bitrate_estimator.h",
sprang318673c2015-09-04 04:43:21 -070018 "include/send_time_history.h",
pbos@webrtc.org9f79fe62014-12-04 15:34:06 +000019 "inter_arrival.cc",
20 "inter_arrival.h",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000021 "overuse_detector.cc",
22 "overuse_detector.h",
pbos@webrtc.org9f79fe62014-12-04 15:34:06 +000023 "overuse_estimator.cc",
24 "overuse_estimator.h",
25 "remote_bitrate_estimator_abs_send_time.cc",
kjellander5c1d0432016-06-09 02:40:58 -070026 "remote_bitrate_estimator_abs_send_time.h",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000027 "remote_bitrate_estimator_single_stream.cc",
kjellander5c1d0432016-06-09 02:40:58 -070028 "remote_bitrate_estimator_single_stream.h",
Erik Språng6b8d3552015-09-24 15:06:57 +020029 "remote_estimator_proxy.cc",
30 "remote_estimator_proxy.h",
sprang318673c2015-09-04 04:43:21 -070031 "send_time_history.cc",
kjellander5c1d0432016-06-09 02:40:58 -070032 "test/bwe_test_logging.h",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000033 ]
kjellander@webrtc.org9bef5512014-07-13 09:02:54 +000034
gaetano.carlucci61050f62016-09-30 06:29:54 -070035 if (rtc_enable_bwe_test_logging) {
36 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=1" ]
37 sources += [ "test/bwe_test_logging.cc" ]
38 } else {
39 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=0" ]
brucedawson07df20b2016-05-22 17:15:02 -070040 }
41
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000042 if (is_clang) {
kjellanderfb114242016-06-13 00:19:48 -070043 # Suppress warnings from the Chromium Clang plugins (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -070044 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000045 }
kjellander5c1d0432016-06-09 02:40:58 -070046
47 deps = [
48 "../..:webrtc_common",
Henrik Kjellanderd4070c62016-06-09 11:55:29 +020049 "../../base:rtc_base_approved",
kjellander5c1d0432016-06-09 02:40:58 -070050 "../../system_wrappers",
51 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000052}
kjellanderfb114242016-06-13 00:19:48 -070053
54if (rtc_include_tests) {
kjellanderb62dbbe2016-09-23 00:38:52 -070055 rtc_static_library("bwe_simulator") {
kjellanderfb114242016-06-13 00:19:48 -070056 testonly = true
57 sources = [
gaetano.carlucci52a57032016-09-14 05:04:36 -070058 "bwe_simulations.cc",
kjellanderfb114242016-06-13 00:19:48 -070059 "test/bwe.cc",
60 "test/bwe.h",
61 "test/bwe_test.cc",
62 "test/bwe_test.h",
63 "test/bwe_test_baselinefile.cc",
64 "test/bwe_test_baselinefile.h",
65 "test/bwe_test_fileutils.cc",
66 "test/bwe_test_fileutils.h",
67 "test/bwe_test_framework.cc",
68 "test/bwe_test_framework.h",
69 "test/bwe_test_logging.h",
70 "test/estimators/nada.cc",
71 "test/estimators/nada.h",
72 "test/estimators/remb.cc",
73 "test/estimators/remb.h",
74 "test/estimators/send_side.cc",
75 "test/estimators/send_side.h",
76 "test/estimators/tcp.cc",
77 "test/estimators/tcp.h",
78 "test/metric_recorder.cc",
79 "test/metric_recorder.h",
80 "test/packet.h",
81 "test/packet_receiver.cc",
82 "test/packet_receiver.h",
83 "test/packet_sender.cc",
84 "test/packet_sender.h",
85 ]
86
87 if (rtc_enable_bwe_test_logging) {
88 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=1" ]
kjellanderfb114242016-06-13 00:19:48 -070089 } else {
90 defines = [ "BWE_TEST_LOGGING_COMPILE_TIME_ENABLE=0" ]
91 }
92
kjellanderfb114242016-06-13 00:19:48 -070093 if (is_clang) {
94 # Suppress warnings from the Chromium Clang plugins (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -070095 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellanderfb114242016-06-13 00:19:48 -070096 }
97
98 if (is_win) {
99 cflags = [
100 # TODO(kjellander): Bug 261: fix this warning.
101 "/wd4373", # virtual function override.
102 ]
103 }
104
105 deps = [
106 "../../test:test_support",
107 "../pacing",
108 "//testing/gmock",
109 "//testing/gtest",
110 ]
111 }
112}