kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 1 | # 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 | |
| 9 | import("//build/config/linux/pkg_config.gni") |
mbonadei | 9aa3f0a | 2017-01-24 06:58:22 -0800 | [diff] [blame] | 10 | import("../webrtc.gni") |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 11 | |
| 12 | group("media") { |
Dan Minor | 9c68613 | 2018-01-15 10:20:00 -0500 | [diff] [blame] | 13 | deps = [] |
| 14 | if (!build_with_mozilla) { |
| 15 | deps += [ |
| 16 | ":rtc_media", |
| 17 | ":rtc_media_base", |
| 18 | ] |
| 19 | } |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 20 | } |
| 21 | |
| 22 | config("rtc_media_defines_config") { |
| 23 | defines = [ |
| 24 | "HAVE_WEBRTC_VIDEO", |
| 25 | "HAVE_WEBRTC_VOICE", |
| 26 | ] |
| 27 | } |
| 28 | |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 29 | config("rtc_media_warnings_config") { |
| 30 | # GN orders flags on a target before flags from configs. The default config |
| 31 | # adds these flags so to cancel them out they need to come from a config and |
| 32 | # cannot be on the target directly. |
| 33 | if (!is_win) { |
| 34 | cflags = [ "-Wno-deprecated-declarations" ] |
| 35 | } |
| 36 | } |
| 37 | |
zhihuang | 130ca7e | 2017-06-21 01:02:59 -0700 | [diff] [blame] | 38 | rtc_source_set("rtc_h264_profile_id") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 39 | visibility = [ "*" ] |
zhihuang | 130ca7e | 2017-06-21 01:02:59 -0700 | [diff] [blame] | 40 | sources = [ |
| 41 | "base/h264_profile_level_id.cc", |
| 42 | "base/h264_profile_level_id.h", |
| 43 | ] |
| 44 | |
| 45 | if (!build_with_chromium && is_clang) { |
| 46 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 47 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 48 | } |
| 49 | |
| 50 | deps = [ |
| 51 | "..:webrtc_common", |
kwiberg | 84f6a3f | 2017-09-05 08:43:13 -0700 | [diff] [blame] | 52 | "../api:optional", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 53 | "../rtc_base:rtc_base", |
| 54 | "../rtc_base:rtc_base_approved", |
zhihuang | 130ca7e | 2017-06-21 01:02:59 -0700 | [diff] [blame] | 55 | ] |
| 56 | } |
| 57 | |
Niels Möller | 6daa278 | 2018-01-23 10:37:42 +0100 | [diff] [blame] | 58 | rtc_source_set("rtc_media_config") { |
| 59 | visibility = [ "*" ] |
| 60 | sources = [ |
| 61 | "base/mediaconfig.h", |
| 62 | ] |
| 63 | } |
| 64 | |
zhihuang | ab97e18 | 2017-06-22 01:28:59 -0700 | [diff] [blame] | 65 | rtc_static_library("rtc_media_base") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 66 | visibility = [ "*" ] |
Karl Wiberg | bb23c83 | 2018-04-22 19:55:00 +0200 | [diff] [blame] | 67 | allow_poison = [ "audio_codecs" ] # TODO(bugs.webrtc.org/8396): Remove. |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 68 | defines = [] |
| 69 | libs = [] |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 70 | deps = [ |
Niels Möller | a6fe261 | 2018-01-19 11:28:54 +0100 | [diff] [blame] | 71 | "../api:audio_options_api", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 72 | "../rtc_base:checks", |
Tommi | 8d2c5a8 | 2018-03-19 11:12:48 +0100 | [diff] [blame] | 73 | "../rtc_base:rtc_base_approved", |
| 74 | "../rtc_base:rtc_task_queue", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 75 | "../rtc_base:sanitizer", |
Tommi | 1829af6 | 2018-02-06 09:29:17 +0100 | [diff] [blame] | 76 | "../rtc_base:sequenced_task_checker", |
Patrik Höglund | 3e11343 | 2017-12-15 14:40:10 +0100 | [diff] [blame] | 77 | "../rtc_base:stringutils", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 78 | ] |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 79 | sources = [ |
nisse | 6f5a6c3 | 2016-09-22 01:25:59 -0700 | [diff] [blame] | 80 | "base/adaptedvideotracksource.cc", |
| 81 | "base/adaptedvideotracksource.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 82 | "base/audiosource.h", |
| 83 | "base/codec.cc", |
| 84 | "base/codec.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 85 | "base/cryptoparams.h", |
| 86 | "base/device.h", |
Paulina Hensman | 11b34f4 | 2018-04-09 14:24:52 +0200 | [diff] [blame] | 87 | "base/mediachannel.cc", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 88 | "base/mediachannel.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 89 | "base/mediaconstants.cc", |
| 90 | "base/mediaconstants.h", |
| 91 | "base/mediaengine.cc", |
| 92 | "base/mediaengine.h", |
| 93 | "base/rtpdataengine.cc", |
| 94 | "base/rtpdataengine.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 95 | "base/rtputils.cc", |
| 96 | "base/rtputils.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 97 | "base/streamparams.cc", |
| 98 | "base/streamparams.h", |
| 99 | "base/turnutils.cc", |
| 100 | "base/turnutils.h", |
| 101 | "base/videoadapter.cc", |
| 102 | "base/videoadapter.h", |
| 103 | "base/videobroadcaster.cc", |
| 104 | "base/videobroadcaster.h", |
| 105 | "base/videocapturer.cc", |
| 106 | "base/videocapturer.h", |
| 107 | "base/videocapturerfactory.h", |
| 108 | "base/videocommon.cc", |
| 109 | "base/videocommon.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 110 | "base/videosourcebase.cc", |
| 111 | "base/videosourcebase.h", |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 112 | ] |
| 113 | |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 114 | if (!build_with_chromium && is_clang) { |
| 115 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 116 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 117 | } |
| 118 | |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 119 | deps += [ |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 120 | ":rtc_h264_profile_id", |
Niels Möller | 6daa278 | 2018-01-23 10:37:42 +0100 | [diff] [blame] | 121 | ":rtc_media_config", |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 122 | "..:webrtc_common", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 123 | "../api:libjingle_peerconnection_api", |
Patrik Höglund | aba85d1 | 2017-11-28 15:46:08 +0100 | [diff] [blame] | 124 | "../api:optional", |
| 125 | "../api:video_frame_api", |
| 126 | "../api:video_frame_api_i420", |
| 127 | "../api/audio_codecs:audio_codecs_api", |
| 128 | "../api/video_codecs:video_codecs_api", |
| 129 | "../call:call_interfaces", |
| 130 | "../call:video_stream_api", |
Patrik Höglund | be214a2 | 2018-01-04 12:14:35 +0100 | [diff] [blame] | 131 | "../common_video", |
Patrik Höglund | aba85d1 | 2017-11-28 15:46:08 +0100 | [diff] [blame] | 132 | "../modules/audio_processing:audio_processing_statistics", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 133 | "../rtc_base:rtc_base", |
| 134 | "../rtc_base:rtc_base_approved", |
Patrik Höglund | aba85d1 | 2017-11-28 15:46:08 +0100 | [diff] [blame] | 135 | "../system_wrappers:field_trial_api", |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 136 | ] |
kjellander | 8a11663 | 2017-04-21 05:17:08 -0700 | [diff] [blame] | 137 | |
Dan Minor | 9c68613 | 2018-01-15 10:20:00 -0500 | [diff] [blame] | 138 | if (!build_with_mozilla) { |
| 139 | deps += [ "../p2p" ] |
| 140 | } |
| 141 | |
kjellander | 8a11663 | 2017-04-21 05:17:08 -0700 | [diff] [blame] | 142 | if (is_nacl) { |
| 143 | deps += [ "//native_client_sdk/src/libraries/nacl_io" ] |
| 144 | } |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 145 | } |
| 146 | |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 147 | rtc_static_library("rtc_constants") { |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 148 | defines = [] |
| 149 | libs = [] |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 150 | deps = [] |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 151 | sources = [ |
mallikarjun82 | 9deda48 | 2017-11-20 17:48:13 +0530 | [diff] [blame] | 152 | "engine/constants.cc", |
charujain | 6674846 | 2017-09-14 13:53:02 -0700 | [diff] [blame] | 153 | "engine/constants.h", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 154 | ] |
| 155 | } |
| 156 | |
| 157 | rtc_static_library("rtc_internal_video_codecs") { |
Per Kjellander | a0f5f60 | 2018-01-10 15:57:32 +0000 | [diff] [blame] | 158 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 159 | allow_poison = [ |
| 160 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 161 | "software_video_codecs", |
| 162 | ] |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 163 | defines = [] |
| 164 | libs = [] |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 165 | deps = [ |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 166 | ":rtc_h264_profile_id", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 167 | "../modules/video_coding:video_codec_interface", |
| 168 | ] |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 169 | sources = [ |
Magnus Jedvert | 07e0d01 | 2017-10-31 11:24:54 +0100 | [diff] [blame] | 170 | "engine/convert_legacy_video_factory.cc", |
| 171 | "engine/convert_legacy_video_factory.h", |
magjed | dd40702 | 2016-12-01 00:27:27 -0800 | [diff] [blame] | 172 | "engine/internaldecoderfactory.cc", |
| 173 | "engine/internaldecoderfactory.h", |
magjed | 509e4fe | 2016-11-18 01:34:11 -0800 | [diff] [blame] | 174 | "engine/internalencoderfactory.cc", |
| 175 | "engine/internalencoderfactory.h", |
Emircan Uysaler | d7ae3c3 | 2018-01-25 13:01:09 -0800 | [diff] [blame] | 176 | "engine/multiplexcodecfactory.cc", |
| 177 | "engine/multiplexcodecfactory.h", |
andersc | 063f0c0 | 2017-09-11 11:50:51 -0700 | [diff] [blame] | 178 | "engine/scopedvideodecoder.cc", |
| 179 | "engine/scopedvideodecoder.h", |
magjed | 3f89758 | 2017-08-28 08:05:42 -0700 | [diff] [blame] | 180 | "engine/scopedvideoencoder.cc", |
| 181 | "engine/scopedvideoencoder.h", |
magjed | 6cc2561 | 2017-07-10 03:26:36 -0700 | [diff] [blame] | 182 | "engine/simulcast_encoder_adapter.cc", |
| 183 | "engine/simulcast_encoder_adapter.h", |
Ilya Nikolaevskiy | c22a3a6 | 2017-10-25 10:04:54 +0200 | [diff] [blame] | 184 | "engine/vp8_encoder_simulcast_proxy.cc", |
| 185 | "engine/vp8_encoder_simulcast_proxy.h", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 186 | "engine/webrtcvideodecoderfactory.h", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 187 | "engine/webrtcvideoencoderfactory.h", |
| 188 | ] |
| 189 | |
| 190 | configs += [ ":rtc_media_warnings_config" ] |
| 191 | |
| 192 | if (!build_with_chromium && is_clang) { |
| 193 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 194 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 195 | } |
| 196 | |
| 197 | if (is_win) { |
| 198 | cflags = [ |
| 199 | "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch. |
| 200 | "/wd4267", # conversion from "size_t" to "int", possible loss of data. |
| 201 | "/wd4389", # signed/unsigned mismatch. |
| 202 | ] |
| 203 | } |
| 204 | |
| 205 | include_dirs = [] |
| 206 | |
| 207 | public_configs = [] |
| 208 | deps += [ |
| 209 | ":rtc_constants", |
| 210 | ":rtc_media_base", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 211 | ":rtc_software_fallback_wrappers", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 212 | "..:webrtc_common", |
| 213 | "../api:video_frame_api_i420", |
| 214 | "../api/video_codecs:video_codecs_api", |
| 215 | "../call:call_interfaces", |
| 216 | "../call:video_stream_api", |
| 217 | "../modules/video_coding:webrtc_h264", |
Emircan Uysaler | d7ae3c3 | 2018-01-25 13:01:09 -0800 | [diff] [blame] | 218 | "../modules/video_coding:webrtc_multiplex", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 219 | "../modules/video_coding:webrtc_vp8", |
| 220 | "../modules/video_coding:webrtc_vp8_helpers", |
| 221 | "../modules/video_coding:webrtc_vp9", |
| 222 | "../rtc_base:checks", |
| 223 | "../rtc_base:rtc_base_approved", |
| 224 | "../rtc_base:sequenced_task_checker", |
| 225 | "../system_wrappers", |
| 226 | "../system_wrappers:field_trial_api", |
| 227 | "../system_wrappers:metrics_api", |
| 228 | "//third_party/libyuv", |
| 229 | ] |
| 230 | } |
| 231 | |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 232 | rtc_static_library("rtc_software_fallback_wrappers") { |
| 233 | sources = [ |
| 234 | "engine/videodecodersoftwarefallbackwrapper.cc", |
| 235 | "engine/videodecodersoftwarefallbackwrapper.h", |
| 236 | "engine/videoencodersoftwarefallbackwrapper.cc", |
| 237 | "engine/videoencodersoftwarefallbackwrapper.h", |
| 238 | ] |
| 239 | |
| 240 | configs += [ ":rtc_media_warnings_config" ] |
| 241 | |
| 242 | if (!build_with_chromium && is_clang) { |
| 243 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 244 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 245 | } |
| 246 | |
| 247 | deps = [ |
| 248 | ":rtc_h264_profile_id", |
| 249 | ":rtc_media_base", |
| 250 | "../api/video_codecs:video_codecs_api", |
| 251 | "../modules/video_coding:video_codec_interface", |
| 252 | "../rtc_base:checks", |
| 253 | "../rtc_base:rtc_base_approved", |
Sami Kalliomäki | 99f52f8 | 2018-02-23 09:05:49 +0100 | [diff] [blame] | 254 | "../rtc_base/system:fallthrough", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 255 | "../system_wrappers:field_trial_api", |
| 256 | ] |
| 257 | } |
| 258 | |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 259 | rtc_static_library("rtc_audio_video") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 260 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 261 | allow_poison = [ |
| 262 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 263 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 264 | ] |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 265 | defines = [] |
| 266 | libs = [] |
| 267 | deps = [ |
Mirko Bonadei | ca913b0 | 2018-01-26 15:11:40 +0100 | [diff] [blame] | 268 | "../modules/audio_processing/aec_dump:aec_dump", |
Patrik Höglund | a97af1f | 2018-01-16 10:11:40 +0100 | [diff] [blame] | 269 | "../modules/video_coding:video_codec_interface", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 270 | "../modules/video_coding:video_coding", |
Jonas Olsson | abbe841 | 2018-04-03 13:40:05 +0200 | [diff] [blame] | 271 | "../rtc_base:audio_format_to_string", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 272 | "../rtc_base:checks", |
| 273 | ] |
| 274 | |
| 275 | sources = [ |
| 276 | "engine/adm_helpers.cc", |
| 277 | "engine/adm_helpers.h", |
| 278 | "engine/apm_helpers.cc", |
| 279 | "engine/apm_helpers.h", |
| 280 | "engine/nullwebrtcvideoengine.h", |
| 281 | "engine/payload_type_mapper.cc", |
| 282 | "engine/payload_type_mapper.h", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 283 | "engine/simulcast.cc", |
| 284 | "engine/simulcast.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 285 | "engine/webrtcmediaengine.cc", |
| 286 | "engine/webrtcmediaengine.h", |
| 287 | "engine/webrtcvideocapturer.cc", |
| 288 | "engine/webrtcvideocapturer.h", |
| 289 | "engine/webrtcvideocapturerfactory.cc", |
| 290 | "engine/webrtcvideocapturerfactory.h", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 291 | "engine/webrtcvideodecoderfactory.cc", |
| 292 | "engine/webrtcvideodecoderfactory.h", |
| 293 | "engine/webrtcvideoencoderfactory.cc", |
| 294 | "engine/webrtcvideoencoderfactory.h", |
eladalon | f184138 | 2017-06-12 01:16:46 -0700 | [diff] [blame] | 295 | "engine/webrtcvideoengine.cc", |
| 296 | "engine/webrtcvideoengine.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 297 | "engine/webrtcvoiceengine.cc", |
| 298 | "engine/webrtcvoiceengine.h", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 299 | ] |
| 300 | |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 301 | configs += [ ":rtc_media_warnings_config" ] |
deadbeef | 40610e2 | 2016-12-22 10:53:38 -0800 | [diff] [blame] | 302 | |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 303 | if (!build_with_chromium && is_clang) { |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 304 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
kjellander | 660312b | 2016-09-26 06:11:53 -0700 | [diff] [blame] | 305 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 306 | } |
| 307 | |
| 308 | if (is_win) { |
| 309 | cflags = [ |
| 310 | "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch. |
| 311 | "/wd4267", # conversion from "size_t" to "int", possible loss of data. |
| 312 | "/wd4389", # signed/unsigned mismatch. |
| 313 | ] |
| 314 | } |
| 315 | |
peah | 1bcfce5 | 2016-08-26 07:16:04 -0700 | [diff] [blame] | 316 | if (rtc_enable_intelligibility_enhancer) { |
| 317 | defines += [ "WEBRTC_INTELLIGIBILITY_ENHANCER=1" ] |
| 318 | } else { |
| 319 | defines += [ "WEBRTC_INTELLIGIBILITY_ENHANCER=0" ] |
| 320 | } |
| 321 | |
minyue | 2e03c66 | 2017-02-01 17:31:11 -0800 | [diff] [blame] | 322 | if (rtc_opus_support_120ms_ptime) { |
| 323 | defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=1" ] |
| 324 | } else { |
| 325 | defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=0" ] |
| 326 | } |
| 327 | |
kjellander | ec5c906 | 2016-08-19 01:07:30 -0700 | [diff] [blame] | 328 | include_dirs = [] |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 329 | |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 330 | public_configs = [] |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 331 | if (build_with_chromium) { |
| 332 | deps += [ "../modules/video_capture:video_capture" ] |
| 333 | } else { |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 334 | public_configs += [ ":rtc_media_defines_config" ] |
| 335 | deps += [ "../modules/video_capture:video_capture_internal_impl" ] |
| 336 | } |
aleloi | 048cbdd | 2017-05-29 02:56:27 -0700 | [diff] [blame] | 337 | if (rtc_enable_protobuf) { |
| 338 | deps += [ "../modules/audio_processing/aec_dump:aec_dump_impl" ] |
| 339 | } else { |
| 340 | deps += [ "../modules/audio_processing/aec_dump:null_aec_dump_factory" ] |
| 341 | } |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 342 | if (rtc_use_builtin_sw_codecs) { |
| 343 | deps += [ ":rtc_internal_video_codecs" ] |
| 344 | } |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 345 | deps += [ |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 346 | ":rtc_constants", |
magjed | 0928a3c | 2016-11-25 00:40:18 -0800 | [diff] [blame] | 347 | ":rtc_media_base", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 348 | ":rtc_software_fallback_wrappers", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 349 | "..:webrtc_common", |
kjellander | a69d973 | 2016-08-31 07:33:05 -0700 | [diff] [blame] | 350 | "../api:call_api", |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 351 | "../api:libjingle_peerconnection_api", |
kwiberg | 84f6a3f | 2017-09-05 08:43:13 -0700 | [diff] [blame] | 352 | "../api:optional", |
aleloi | a8eb756 | 2016-11-28 07:02:13 -0800 | [diff] [blame] | 353 | "../api:transport_api", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 354 | "../api:video_frame_api", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 355 | "../api:video_frame_api_i420", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 356 | "../api/audio_codecs:audio_codecs_api", |
ilnik | d60d06a | 2017-04-05 03:02:20 -0700 | [diff] [blame] | 357 | "../api/video_codecs:video_codecs_api", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 358 | "../call", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 359 | "../call:call_interfaces", |
aleloi | 440b6d9 | 2017-08-22 05:43:23 -0700 | [diff] [blame] | 360 | "../call:video_stream_api", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 361 | "../common_video:common_video", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 362 | "../modules/audio_device:audio_device", |
Paulina Hensman | 7bd79a0 | 2018-03-15 12:44:12 +0100 | [diff] [blame] | 363 | "../modules/audio_device:audio_device_impl", |
aleloi | 10111bc | 2016-11-17 06:48:48 -0800 | [diff] [blame] | 364 | "../modules/audio_mixer:audio_mixer_impl", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 365 | "../modules/audio_processing:audio_processing", |
| 366 | "../modules/video_capture:video_capture_module", |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 367 | "../pc:rtc_pc_base", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 368 | "../rtc_base:rtc_base", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 369 | "../rtc_base:rtc_task_queue", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 370 | "../rtc_base:stringutils", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 371 | "../system_wrappers", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 372 | "../system_wrappers:field_trial_api", |
| 373 | "../system_wrappers:metrics_api", |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 374 | ] |
| 375 | } |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 376 | |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 377 | rtc_static_library("rtc_data") { |
| 378 | defines = [] |
| 379 | deps = [] |
| 380 | |
| 381 | if (rtc_enable_sctp) { |
| 382 | sources = [ |
| 383 | "sctp/sctptransport.cc", |
| 384 | "sctp/sctptransport.h", |
| 385 | "sctp/sctptransportinternal.h", |
| 386 | ] |
Kári Tristan Helgason | 4d3e24a | 2017-12-01 15:26:41 +0100 | [diff] [blame] | 387 | } else { |
| 388 | # libtool on mac does not like empty targets. |
| 389 | sources = [ |
Mirko Bonadei | 6c8e666 | 2017-12-13 07:40:54 +0100 | [diff] [blame] | 390 | "sctp/noop.cc", |
Kári Tristan Helgason | 4d3e24a | 2017-12-01 15:26:41 +0100 | [diff] [blame] | 391 | ] |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 392 | } |
| 393 | |
| 394 | configs += [ ":rtc_media_warnings_config" ] |
| 395 | |
| 396 | if (!build_with_chromium && is_clang) { |
| 397 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
| 398 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 399 | } |
| 400 | |
| 401 | if (is_win) { |
| 402 | cflags = [ |
| 403 | "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch. |
| 404 | "/wd4267", # conversion from "size_t" to "int", possible loss of data. |
| 405 | "/wd4389", # signed/unsigned mismatch. |
| 406 | ] |
| 407 | } |
| 408 | |
| 409 | if (rtc_enable_sctp && rtc_build_usrsctp) { |
| 410 | include_dirs = [ |
| 411 | # TODO(jiayl): move this into the public_configs of |
| 412 | # //third_party/usrsctp/BUILD.gn. |
| 413 | "//third_party/usrsctp/usrsctplib", |
| 414 | ] |
| 415 | deps += [ "//third_party/usrsctp" ] |
| 416 | } |
| 417 | |
| 418 | deps += [ |
| 419 | ":rtc_media_base", |
| 420 | "..:webrtc_common", |
| 421 | "../api:call_api", |
| 422 | "../api:transport_api", |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 423 | "../p2p:rtc_p2p", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 424 | "../rtc_base:rtc_base", |
| 425 | "../rtc_base:rtc_base_approved", |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 426 | "../system_wrappers", |
| 427 | ] |
| 428 | } |
| 429 | |
| 430 | rtc_source_set("rtc_media") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 431 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 432 | allow_poison = [ |
| 433 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 434 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 435 | ] |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 436 | deps = [ |
zhihuang | 38ede13 | 2017-06-15 12:52:32 -0700 | [diff] [blame] | 437 | ":rtc_audio_video", |
| 438 | ":rtc_data", |
| 439 | ] |
| 440 | } |
| 441 | |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 442 | if (rtc_include_tests) { |
| 443 | config("rtc_unittest_main_config") { |
| 444 | # GN orders flags on a target before flags from configs. The default config |
| 445 | # adds -Wall, and this flag have to be after -Wall -- so they need to |
| 446 | # come from a config and can"t be on the target directly. |
| 447 | if (is_clang && is_ios) { |
| 448 | cflags = [ "-Wno-unused-variable" ] |
| 449 | } |
| 450 | } |
| 451 | |
mbonadei | 9087d49 | 2017-04-25 00:35:35 -0700 | [diff] [blame] | 452 | rtc_source_set("rtc_media_tests_utils") { |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 453 | testonly = true |
| 454 | |
kjellander | ec5c906 | 2016-08-19 01:07:30 -0700 | [diff] [blame] | 455 | include_dirs = [] |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 456 | deps = [ |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 457 | ":rtc_audio_video", |
Patrik Höglund | be214a2 | 2018-01-04 12:14:35 +0100 | [diff] [blame] | 458 | "../api:libjingle_peerconnection_api", |
Patrik Höglund | b5b5bce | 2017-11-13 10:19:58 +0100 | [diff] [blame] | 459 | "../api:video_frame_api_i420", |
aleloi | 440b6d9 | 2017-08-22 05:43:23 -0700 | [diff] [blame] | 460 | "../call:video_stream_api", |
Patrik Höglund | be214a2 | 2018-01-04 12:14:35 +0100 | [diff] [blame] | 461 | "../common_video:common_video", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 462 | "../modules/audio_coding:rent_a_codec", |
| 463 | "../modules/audio_processing:audio_processing", |
Mirko Bonadei | b5728d9 | 2017-12-06 07:51:33 +0100 | [diff] [blame] | 464 | "../modules/rtp_rtcp:rtp_rtcp_format", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 465 | "../modules/video_coding:video_codec_interface", |
charujain | cb728ea | 2017-09-18 03:08:08 -0700 | [diff] [blame] | 466 | "../modules/video_coding:video_coding_utility", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 467 | "../p2p:rtc_p2p", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 468 | "../rtc_base:checks", |
Tommi | 8d2c5a8 | 2018-03-19 11:12:48 +0100 | [diff] [blame] | 469 | "../rtc_base:rtc_task_queue", |
Patrik Höglund | 3e11343 | 2017-12-15 14:40:10 +0100 | [diff] [blame] | 470 | "../rtc_base:stringutils", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 471 | ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 472 | sources = [ |
Niels Möller | a6cc0f9 | 2018-02-12 17:14:55 +0100 | [diff] [blame] | 473 | "base/fakeframesource.cc", |
| 474 | "base/fakeframesource.h", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 475 | "base/fakemediaengine.h", |
| 476 | "base/fakenetworkinterface.h", |
jbauch | 5869f50 | 2017-06-29 12:31:36 -0700 | [diff] [blame] | 477 | "base/fakertp.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 478 | "base/fakertp.h", |
Tommi | 1829af6 | 2018-02-06 09:29:17 +0100 | [diff] [blame] | 479 | "base/fakevideocapturer.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 480 | "base/fakevideocapturer.h", |
| 481 | "base/fakevideorenderer.h", |
| 482 | "base/testutils.cc", |
| 483 | "base/testutils.h", |
| 484 | "engine/fakewebrtccall.cc", |
| 485 | "engine/fakewebrtccall.h", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 486 | "engine/fakewebrtcdeviceinfo.h", |
| 487 | "engine/fakewebrtcvcmfactory.h", |
| 488 | "engine/fakewebrtcvideocapturemodule.h", |
Anders Carlsson | 6753795 | 2018-05-03 11:28:29 +0200 | [diff] [blame^] | 489 | "engine/fakewebrtcvideoengine.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 490 | "engine/fakewebrtcvideoengine.h", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 491 | ] |
| 492 | |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 493 | configs += [ ":rtc_unittest_main_config" ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 494 | |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 495 | if (!build_with_chromium && is_clang) { |
| 496 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 497 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 498 | } |
| 499 | |
| 500 | deps += [ |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 501 | ":rtc_internal_video_codecs", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 502 | ":rtc_media", |
| 503 | ":rtc_media_base", |
| 504 | "..:webrtc_common", |
| 505 | "../api:call_api", |
| 506 | "../api:video_frame_api", |
ilnik | d60d06a | 2017-04-05 03:02:20 -0700 | [diff] [blame] | 507 | "../api/video_codecs:video_codecs_api", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 508 | "../call:call_interfaces", |
Sebastian Jansson | 8f83b42 | 2018-02-21 13:07:13 +0100 | [diff] [blame] | 509 | "../call:mock_rtp_interfaces", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 510 | "../rtc_base:rtc_base", |
| 511 | "../rtc_base:rtc_base_approved", |
| 512 | "../rtc_base:rtc_base_tests_utils", |
Tommi | 6856156 | 2018-02-13 19:47:50 +0100 | [diff] [blame] | 513 | "../rtc_base:rtc_task_queue_for_test", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 514 | "../test:test_support", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 515 | "//testing/gtest", |
| 516 | ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 517 | } |
| 518 | |
| 519 | config("rtc_media_unittests_config") { |
| 520 | # GN orders flags on a target before flags from configs. The default config |
| 521 | # adds -Wall, and this flag have to be after -Wall -- so they need to |
| 522 | # come from a config and can"t be on the target directly. |
| 523 | # TODO(kjellander): Make the code compile without disabling these flags. |
| 524 | # See https://bugs.webrtc.org/3307. |
| 525 | if (is_clang && is_win) { |
ehmaldonado | d02fe4b | 2016-08-26 13:31:24 -0700 | [diff] [blame] | 526 | cflags = [ |
| 527 | # See https://bugs.chromium.org/p/webrtc/issues/detail?id=6266 |
| 528 | # for -Wno-sign-compare |
| 529 | "-Wno-sign-compare", |
ehmaldonado | d02fe4b | 2016-08-26 13:31:24 -0700 | [diff] [blame] | 530 | ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 531 | } |
| 532 | if (!is_win) { |
| 533 | cflags = [ "-Wno-sign-compare" ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 534 | } |
| 535 | } |
| 536 | |
ehmaldonado | 3a7f35b | 2016-09-14 05:10:01 -0700 | [diff] [blame] | 537 | rtc_media_unittests_resources = [ |
Mirko Bonadei | 92ea95e | 2017-09-15 06:47:31 +0200 | [diff] [blame] | 538 | "../resources/media/captured-320x240-2s-48.frames", |
| 539 | "../resources/media/faces.1280x720_P420.yuv", |
| 540 | "../resources/media/faces_I420.jpg", |
| 541 | "../resources/media/faces_I422.jpg", |
| 542 | "../resources/media/faces_I444.jpg", |
| 543 | "../resources/media/faces_I411.jpg", |
| 544 | "../resources/media/faces_I400.jpg", |
ehmaldonado | 3a7f35b | 2016-09-14 05:10:01 -0700 | [diff] [blame] | 545 | ] |
kjellander | 32c4a20 | 2016-08-30 02:53:49 -0700 | [diff] [blame] | 546 | |
| 547 | if (is_ios) { |
| 548 | bundle_data("rtc_media_unittests_bundle_data") { |
| 549 | testonly = true |
| 550 | sources = rtc_media_unittests_resources |
| 551 | outputs = [ |
| 552 | "{{bundle_resources_dir}}/{{source_file_part}}", |
| 553 | ] |
| 554 | } |
| 555 | } |
| 556 | |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 557 | rtc_test("rtc_media_unittests") { |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 558 | testonly = true |
| 559 | |
johan | 073ece4 | 2016-08-26 02:59:47 -0700 | [diff] [blame] | 560 | defines = [] |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 561 | deps = [ |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 562 | ":rtc_audio_video", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 563 | ":rtc_constants", |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 564 | ":rtc_data", |
Patrik Höglund | b5b5bce | 2017-11-13 10:19:58 +0100 | [diff] [blame] | 565 | "../api:video_frame_api_i420", |
Patrik Höglund | 6213929 | 2017-12-19 16:44:45 +0100 | [diff] [blame] | 566 | "../modules/audio_processing:mocks", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 567 | "../modules/video_coding:video_codec_interface", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 568 | "../pc:rtc_pc", |
Mirko Bonadei | e51f785 | 2017-12-06 11:23:19 +0100 | [diff] [blame] | 569 | "../pc:rtc_pc_base", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 570 | "../rtc_base:checks", |
Tommi | 8d2c5a8 | 2018-03-19 11:12:48 +0100 | [diff] [blame] | 571 | "../rtc_base:rtc_task_queue", |
Patrik Höglund | 3e11343 | 2017-12-15 14:40:10 +0100 | [diff] [blame] | 572 | "../rtc_base:stringutils", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 573 | "../test:field_trial", |
| 574 | ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 575 | sources = [ |
| 576 | "base/codec_unittest.cc", |
| 577 | "base/rtpdataengine_unittest.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 578 | "base/rtputils_unittest.cc", |
| 579 | "base/streamparams_unittest.cc", |
| 580 | "base/turnutils_unittest.cc", |
| 581 | "base/videoadapter_unittest.cc", |
| 582 | "base/videobroadcaster_unittest.cc", |
| 583 | "base/videocapturer_unittest.cc", |
| 584 | "base/videocommon_unittest.cc", |
solenberg | 76377c5 | 2017-02-21 00:54:31 -0800 | [diff] [blame] | 585 | "engine/apm_helpers_unittest.cc", |
magjed | dd40702 | 2016-12-01 00:27:27 -0800 | [diff] [blame] | 586 | "engine/internaldecoderfactory_unittest.cc", |
Emircan Uysaler | d7ae3c3 | 2018-01-25 13:01:09 -0800 | [diff] [blame] | 587 | "engine/multiplexcodecfactory_unittest.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 588 | "engine/nullwebrtcvideoengine_unittest.cc", |
ossu | c54071d | 2016-08-17 02:45:41 -0700 | [diff] [blame] | 589 | "engine/payload_type_mapper_unittest.cc", |
magjed | 6cc2561 | 2017-07-10 03:26:36 -0700 | [diff] [blame] | 590 | "engine/simulcast_encoder_adapter_unittest.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 591 | "engine/simulcast_unittest.cc", |
magjed | f6acc2a | 2016-11-22 01:43:03 -0800 | [diff] [blame] | 592 | "engine/videodecodersoftwarefallbackwrapper_unittest.cc", |
magjed | 614d5b7 | 2016-11-15 06:30:54 -0800 | [diff] [blame] | 593 | "engine/videoencodersoftwarefallbackwrapper_unittest.cc", |
Ilya Nikolaevskiy | c22a3a6 | 2017-10-25 10:04:54 +0200 | [diff] [blame] | 594 | "engine/vp8_encoder_simulcast_proxy_unittest.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 595 | "engine/webrtcmediaengine_unittest.cc", |
| 596 | "engine/webrtcvideocapturer_unittest.cc", |
noahric | be850e1 | 2017-01-20 01:07:26 -0800 | [diff] [blame] | 597 | "engine/webrtcvideoencoderfactory_unittest.cc", |
eladalon | f184138 | 2017-06-12 01:16:46 -0700 | [diff] [blame] | 598 | "engine/webrtcvideoengine_unittest.cc", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 599 | ] |
| 600 | |
oprypin | 4519752 | 2017-06-22 01:47:20 -0700 | [diff] [blame] | 601 | # TODO(kthelgason): Reenable this test on iOS. |
| 602 | # See bugs.webrtc.org/5569 |
| 603 | if (!is_ios) { |
| 604 | sources += [ "engine/webrtcvoiceengine_unittest.cc" ] |
| 605 | } |
| 606 | |
deadbeef | 40610e2 | 2016-12-22 10:53:38 -0800 | [diff] [blame] | 607 | if (rtc_enable_sctp) { |
deadbeef | 953c2ce | 2017-01-09 14:53:41 -0800 | [diff] [blame] | 608 | sources += [ "sctp/sctptransport_unittest.cc" ] |
deadbeef | 40610e2 | 2016-12-22 10:53:38 -0800 | [diff] [blame] | 609 | } |
| 610 | |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 611 | configs += [ ":rtc_media_unittests_config" ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 612 | |
johan | 073ece4 | 2016-08-26 02:59:47 -0700 | [diff] [blame] | 613 | if (rtc_use_h264) { |
| 614 | defines += [ "WEBRTC_USE_H264" ] |
| 615 | } |
ossu | 11bfc53 | 2017-02-16 05:37:06 -0800 | [diff] [blame] | 616 | |
| 617 | if (rtc_opus_support_120ms_ptime) { |
| 618 | defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=1" ] |
| 619 | } else { |
| 620 | defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=0" ] |
| 621 | } |
| 622 | |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 623 | if (is_win) { |
| 624 | cflags = [ |
| 625 | "/wd4245", # conversion from int to size_t, signed/unsigned mismatch. |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 626 | "/wd4389", # signed/unsigned mismatch. |
| 627 | ] |
| 628 | } |
| 629 | |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 630 | if (!build_with_chromium && is_clang) { |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 631 | suppressed_configs += [ |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 632 | "//build/config/clang:extra_warnings", |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 633 | |
| 634 | # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 635 | "//build/config/clang:find_bad_constructs", |
| 636 | ] |
| 637 | } |
| 638 | |
ehmaldonado | 3a7f35b | 2016-09-14 05:10:01 -0700 | [diff] [blame] | 639 | data = rtc_media_unittests_resources |
| 640 | |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 641 | if (is_android) { |
| 642 | deps += [ "//testing/android/native_test:native_test_support" ] |
kjellander | 28a0ffd | 2016-08-24 07:48:42 -0700 | [diff] [blame] | 643 | shard_timeout = 900 |
| 644 | } |
kjellander | 32c4a20 | 2016-08-30 02:53:49 -0700 | [diff] [blame] | 645 | |
| 646 | if (is_ios) { |
| 647 | deps += [ ":rtc_media_unittests_bundle_data" ] |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 648 | } |
| 649 | |
| 650 | deps += [ |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 651 | ":rtc_internal_video_codecs", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 652 | ":rtc_media", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 653 | ":rtc_media_base", |
mbonadei | 9087d49 | 2017-04-25 00:35:35 -0700 | [diff] [blame] | 654 | ":rtc_media_tests_utils", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 655 | ":rtc_software_fallback_wrappers", |
Seth Hampson | 24722b3 | 2017-12-22 09:36:42 -0800 | [diff] [blame] | 656 | "../api:libjingle_peerconnection_api", |
Emircan Uysaler | dbcac7f | 2017-10-30 23:10:12 -0700 | [diff] [blame] | 657 | "../api:mock_video_codec_factory", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 658 | "../api:video_frame_api", |
| 659 | "../api/audio_codecs:builtin_audio_decoder_factory", |
ossu | eb1fde4 | 2017-05-02 06:46:30 -0700 | [diff] [blame] | 660 | "../api/audio_codecs:builtin_audio_encoder_factory", |
ilnik | d60d06a | 2017-04-05 03:02:20 -0700 | [diff] [blame] | 661 | "../api/video_codecs:video_codecs_api", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 662 | "../audio", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 663 | "../call:call_interfaces", |
| 664 | "../common_video:common_video", |
| 665 | "../logging:rtc_event_log_api", |
Qingsi Wang | 970b088 | 2018-02-01 11:04:46 -0800 | [diff] [blame] | 666 | "../logging:rtc_event_log_impl_base", |
aleloi | 5de52fd | 2016-11-10 01:05:34 -0800 | [diff] [blame] | 667 | "../modules/audio_device:mock_audio_device", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 668 | "../modules/audio_processing:audio_processing", |
magjed | 6cc2561 | 2017-07-10 03:26:36 -0700 | [diff] [blame] | 669 | "../modules/video_coding:simulcast_test_utility", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 670 | "../modules/video_coding:video_coding_utility", |
Anders Carlsson | a114c88 | 2018-01-04 15:10:22 +0100 | [diff] [blame] | 671 | "../modules/video_coding:webrtc_vp8_helpers", |
deadbeef | 59edb92 | 2017-04-18 15:49:09 -0700 | [diff] [blame] | 672 | "../p2p:p2p_test_utils", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 673 | "../rtc_base:rtc_base", |
| 674 | "../rtc_base:rtc_base_approved", |
| 675 | "../rtc_base:rtc_base_tests_main", |
| 676 | "../rtc_base:rtc_base_tests_utils", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 677 | "../system_wrappers:metrics_default", |
Ilya Nikolaevskiy | 2ffe3e8 | 2018-01-17 19:57:24 +0000 | [diff] [blame] | 678 | "../system_wrappers:runtime_enabled_features_default", |
kwiberg | 37e99fd | 2017-04-10 05:15:48 -0700 | [diff] [blame] | 679 | "../test:audio_codec_mocks", |
kjellander | a2ef4f9 | 2017-03-06 06:04:55 -0800 | [diff] [blame] | 680 | "../test:test_support", |
Ilya Nikolaevskiy | c22a3a6 | 2017-10-25 10:04:54 +0200 | [diff] [blame] | 681 | "../test:video_test_common", |
kjellander | 82a9449 | 2016-06-12 22:12:01 -0700 | [diff] [blame] | 682 | ] |
| 683 | } |
| 684 | } |