blob: 4b956c8edc283aedafd93c9dbecb4fb89c71bbb9 [file] [log] [blame]
kjellanderc76dc952016-06-03 10:09:321# 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
9import("//build/config/linux/pkg_config.gni")
mbonadei9aa3f0a2017-01-24 14:58:2210import("../webrtc.gni")
kjellanderc76dc952016-06-03 10:09:3211
12group("media") {
kjellander705ecc52016-09-15 07:53:2613 public_deps = [
kjellanderc76dc952016-06-03 10:09:3214 ":rtc_media",
magjed0928a3c2016-11-25 08:40:1815 ":rtc_media_base",
kjellanderc76dc952016-06-03 10:09:3216 ]
17}
18
19config("rtc_media_defines_config") {
20 defines = [
21 "HAVE_WEBRTC_VIDEO",
22 "HAVE_WEBRTC_VOICE",
23 ]
24}
25
zhihuang38ede132017-06-15 19:52:3226config("rtc_media_warnings_config") {
27 # GN orders flags on a target before flags from configs. The default config
28 # adds these flags so to cancel them out they need to come from a config and
29 # cannot be on the target directly.
30 if (!is_win) {
31 cflags = [ "-Wno-deprecated-declarations" ]
32 }
33}
34
zhihuang130ca7e2017-06-21 08:02:5935rtc_source_set("rtc_h264_profile_id") {
36 sources = [
37 "base/h264_profile_level_id.cc",
38 "base/h264_profile_level_id.h",
39 ]
40
41 if (!build_with_chromium && is_clang) {
42 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
43 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
44 }
45
46 deps = [
47 "..:webrtc_common",
kwiberg84f6a3f2017-09-05 15:43:1348 "../api:optional",
ehmaldonadof6a861a2017-07-19 17:40:4749 "../rtc_base:rtc_base",
50 "../rtc_base:rtc_base_approved",
zhihuang130ca7e2017-06-21 08:02:5951 ]
52}
53
zhihuangab97e182017-06-22 08:28:5954rtc_static_library("rtc_media_base") {
kjellandera2ef4f92017-03-06 14:04:5555 # TODO(kjellander): Remove (bugs.webrtc.org/6828)
56 # Enabling GN check triggers cyclic dependency error:
Jianjun Zhu037f3e42017-08-15 13:48:3757 # :rtc_media_base ->
58 # ../pc:rtc_pc_base ->
59 # :rtc_data ->
60 # :rtc_media_base
kjellandera2ef4f92017-03-06 14:04:5561 check_includes = false
kjellanderc76dc952016-06-03 10:09:3262 defines = []
63 libs = []
64 deps = []
emircan82fac892017-08-23 21:19:5065 public_deps = []
kjellanderc76dc952016-06-03 10:09:3266 sources = [
nisse6f5a6c32016-09-22 08:25:5967 "base/adaptedvideotracksource.cc",
68 "base/adaptedvideotracksource.h",
kjellanderc76dc952016-06-03 10:09:3269 "base/audiosource.h",
70 "base/codec.cc",
71 "base/codec.h",
kjellanderc76dc952016-06-03 10:09:3272 "base/cryptoparams.h",
73 "base/device.h",
kjellanderc76dc952016-06-03 10:09:3274 "base/mediachannel.h",
kjellanderc76dc952016-06-03 10:09:3275 "base/mediaconstants.cc",
76 "base/mediaconstants.h",
77 "base/mediaengine.cc",
78 "base/mediaengine.h",
79 "base/rtpdataengine.cc",
80 "base/rtpdataengine.h",
kjellanderc76dc952016-06-03 10:09:3281 "base/rtputils.cc",
82 "base/rtputils.h",
kjellanderc76dc952016-06-03 10:09:3283 "base/streamparams.cc",
84 "base/streamparams.h",
85 "base/turnutils.cc",
86 "base/turnutils.h",
87 "base/videoadapter.cc",
88 "base/videoadapter.h",
89 "base/videobroadcaster.cc",
90 "base/videobroadcaster.h",
91 "base/videocapturer.cc",
92 "base/videocapturer.h",
93 "base/videocapturerfactory.h",
94 "base/videocommon.cc",
95 "base/videocommon.h",
kjellanderc76dc952016-06-03 10:09:3296 "base/videosourcebase.cc",
97 "base/videosourcebase.h",
aleloi440b6d92017-08-22 12:43:2398
99 # TODO(aleloi): add "base/videosinkinterface.h"
100 "base/videosourceinterface.cc",
101
102 # TODO(aleloi): add "base/videosourceinterface.h"
magjed0928a3c2016-11-25 08:40:18103 ]
104
magjed0928a3c2016-11-25 08:40:18105 if (!build_with_chromium && is_clang) {
106 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
107 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
108 }
109
110 include_dirs = []
111 if (rtc_build_libyuv) {
112 deps += [ "$rtc_libyuv_dir" ]
emircan82fac892017-08-23 21:19:50113 public_deps += [ "$rtc_libyuv_dir" ]
magjed0928a3c2016-11-25 08:40:18114 } else {
115 # Need to add a directory normally exported by libyuv.
116 include_dirs += [ "$rtc_libyuv_dir/include" ]
117 }
118
119 deps += [
120 "..:webrtc_common",
kjellandera2ef4f92017-03-06 14:04:55121 "../api:libjingle_peerconnection_api",
magjed0928a3c2016-11-25 08:40:18122 "../p2p",
ehmaldonadof6a861a2017-07-19 17:40:47123 "../rtc_base:rtc_base",
124 "../rtc_base:rtc_base_approved",
magjed0928a3c2016-11-25 08:40:18125 ]
kjellander8a116632017-04-21 12:17:08126
emircan82fac892017-08-23 21:19:50127 public_deps += [ ":rtc_h264_profile_id" ]
128
kjellander8a116632017-04-21 12:17:08129 if (is_nacl) {
130 deps += [ "//native_client_sdk/src/libraries/nacl_io" ]
131 }
magjed0928a3c2016-11-25 08:40:18132}
133
zhihuang38ede132017-06-15 19:52:32134rtc_static_library("rtc_audio_video") {
magjed0928a3c2016-11-25 08:40:18135 defines = []
136 libs = []
charujaincb728ea2017-09-18 10:08:08137 deps = [
138 "../modules/video_coding:video_coding_utility",
139 ]
magjed0928a3c2016-11-25 08:40:18140 sources = [
solenberg9a5f032222017-03-15 13:14:12141 "engine/adm_helpers.cc",
142 "engine/adm_helpers.h",
solenberg76377c52017-02-21 08:54:31143 "engine/apm_helpers.cc",
144 "engine/apm_helpers.h",
charujain66748462017-09-14 20:53:02145 "engine/constants.h",
magjeddd407022016-12-01 08:27:27146 "engine/internaldecoderfactory.cc",
147 "engine/internaldecoderfactory.h",
magjed509e4fe2016-11-18 09:34:11148 "engine/internalencoderfactory.cc",
149 "engine/internalencoderfactory.h",
kjellanderc76dc952016-06-03 10:09:32150 "engine/nullwebrtcvideoengine.h",
ossu6f06cca2016-07-13 17:06:22151 "engine/payload_type_mapper.cc",
152 "engine/payload_type_mapper.h",
andersc063f0c02017-09-11 18:50:51153 "engine/scopedvideodecoder.cc",
154 "engine/scopedvideodecoder.h",
magjed3f897582017-08-28 15:05:42155 "engine/scopedvideoencoder.cc",
156 "engine/scopedvideoencoder.h",
kjellanderc76dc952016-06-03 10:09:32157 "engine/simulcast.cc",
158 "engine/simulcast.h",
magjed6cc25612017-07-10 10:26:36159 "engine/simulcast_encoder_adapter.cc",
160 "engine/simulcast_encoder_adapter.h",
magjedf6acc2a2016-11-22 09:43:03161 "engine/videodecodersoftwarefallbackwrapper.cc",
162 "engine/videodecodersoftwarefallbackwrapper.h",
magjed614d5b72016-11-15 14:30:54163 "engine/videoencodersoftwarefallbackwrapper.cc",
164 "engine/videoencodersoftwarefallbackwrapper.h",
kjellanderc76dc952016-06-03 10:09:32165 "engine/webrtcmediaengine.cc",
166 "engine/webrtcmediaengine.h",
167 "engine/webrtcvideocapturer.cc",
168 "engine/webrtcvideocapturer.h",
169 "engine/webrtcvideocapturerfactory.cc",
170 "engine/webrtcvideocapturerfactory.h",
171 "engine/webrtcvideodecoderfactory.h",
172 "engine/webrtcvideoencoderfactory.h",
eladalonf1841382017-06-12 08:16:46173 "engine/webrtcvideoengine.cc",
174 "engine/webrtcvideoengine.h",
kjellanderc76dc952016-06-03 10:09:32175 "engine/webrtcvoe.h",
176 "engine/webrtcvoiceengine.cc",
177 "engine/webrtcvoiceengine.h",
kjellanderc76dc952016-06-03 10:09:32178 ]
179
zhihuang38ede132017-06-15 19:52:32180 configs += [ ":rtc_media_warnings_config" ]
deadbeef40610e22016-12-22 18:53:38181
kjellandere40a7ee2016-10-17 06:56:12182 if (!build_with_chromium && is_clang) {
kjellander82a94492016-06-13 05:12:01183 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
kjellander660312b2016-09-26 13:11:53184 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellanderc76dc952016-06-03 10:09:32185 }
186
187 if (is_win) {
188 cflags = [
189 "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch.
190 "/wd4267", # conversion from "size_t" to "int", possible loss of data.
191 "/wd4389", # signed/unsigned mismatch.
192 ]
193 }
194
peah1bcfce52016-08-26 14:16:04195 if (rtc_enable_intelligibility_enhancer) {
196 defines += [ "WEBRTC_INTELLIGIBILITY_ENHANCER=1" ]
197 } else {
198 defines += [ "WEBRTC_INTELLIGIBILITY_ENHANCER=0" ]
199 }
200
minyue2e03c662017-02-02 01:31:11201 if (rtc_opus_support_120ms_ptime) {
202 defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=1" ]
203 } else {
204 defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=0" ]
205 }
206
kjellanderec5c9062016-08-19 08:07:30207 include_dirs = []
kjellanderc76dc952016-06-03 10:09:32208 if (rtc_build_libyuv) {
209 deps += [ "$rtc_libyuv_dir" ]
210 public_deps = [
211 "$rtc_libyuv_dir",
212 ]
213 } else {
214 # Need to add a directory normally exported by libyuv.
215 include_dirs += [ "$rtc_libyuv_dir/include" ]
216 }
217
ehmaldonadoe9cc6862016-09-05 13:10:18218 public_configs = []
kjellanderc76dc952016-06-03 10:09:32219 if (build_with_chromium) {
220 deps += [ "../modules/video_capture:video_capture" ]
221 } else {
kjellanderc76dc952016-06-03 10:09:32222 public_configs += [ ":rtc_media_defines_config" ]
223 deps += [ "../modules/video_capture:video_capture_internal_impl" ]
224 }
aleloi048cbdd2017-05-29 09:56:27225 if (rtc_enable_protobuf) {
226 deps += [ "../modules/audio_processing/aec_dump:aec_dump_impl" ]
227 } else {
228 deps += [ "../modules/audio_processing/aec_dump:null_aec_dump_factory" ]
229 }
kjellanderc76dc952016-06-03 10:09:32230 deps += [
magjed0928a3c2016-11-25 08:40:18231 ":rtc_media_base",
kjellanderc76dc952016-06-03 10:09:32232 "..:webrtc_common",
kjellandera69d9732016-08-31 14:33:05233 "../api:call_api",
zhihuang38ede132017-06-15 19:52:32234 "../api:libjingle_peerconnection_api",
kwiberg84f6a3f2017-09-05 15:43:13235 "../api:optional",
aleloia8eb7562016-11-28 15:02:13236 "../api:transport_api",
kjellandera2ef4f92017-03-06 14:04:55237 "../api:video_frame_api",
238 "../api/audio_codecs:audio_codecs_api",
239 "../api/audio_codecs:builtin_audio_decoder_factory",
zhihuang38ede132017-06-15 19:52:32240 "../api/audio_codecs:builtin_audio_encoder_factory",
ilnikd60d06a2017-04-05 10:02:20241 "../api/video_codecs:video_codecs_api",
kjellander82a94492016-06-13 05:12:01242 "../call",
aleloi440b6d92017-08-22 12:43:23243 "../call:video_stream_api",
kjellandera2ef4f92017-03-06 14:04:55244 "../common_video:common_video",
245 "../modules/audio_coding:rent_a_codec",
246 "../modules/audio_device:audio_device",
aleloi10111bc2016-11-17 14:48:48247 "../modules/audio_mixer:audio_mixer_impl",
kjellandera2ef4f92017-03-06 14:04:55248 "../modules/audio_processing:audio_processing",
aleloi048cbdd2017-05-29 09:56:27249 "../modules/audio_processing/aec_dump",
kjellandera2ef4f92017-03-06 14:04:55250 "../modules/video_capture:video_capture_module",
kjellander82a94492016-06-13 05:12:01251 "../modules/video_coding",
kjellandera2ef4f92017-03-06 14:04:55252 "../modules/video_coding:webrtc_h264",
253 "../modules/video_coding:webrtc_vp8",
254 "../modules/video_coding:webrtc_vp9",
255 "../p2p:rtc_p2p",
zhihuang38ede132017-06-15 19:52:32256 "../pc:rtc_pc_base",
ehmaldonadof6a861a2017-07-19 17:40:47257 "../rtc_base:rtc_base",
258 "../rtc_base:rtc_base_approved",
259 "../rtc_base:rtc_task_queue",
260 "../rtc_base:sequenced_task_checker",
kjellanderc76dc952016-06-03 10:09:32261 "../system_wrappers",
kjellandera2ef4f92017-03-06 14:04:55262 "../video",
kjellanderc76dc952016-06-03 10:09:32263 "../voice_engine",
264 ]
265}
kjellander82a94492016-06-13 05:12:01266
zhihuang38ede132017-06-15 19:52:32267rtc_static_library("rtc_data") {
268 defines = []
269 deps = []
270
271 if (rtc_enable_sctp) {
272 sources = [
273 "sctp/sctptransport.cc",
274 "sctp/sctptransport.h",
275 "sctp/sctptransportinternal.h",
276 ]
277 }
278
279 configs += [ ":rtc_media_warnings_config" ]
280
281 if (!build_with_chromium && is_clang) {
282 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
283 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
284 }
285
286 if (is_win) {
287 cflags = [
288 "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch.
289 "/wd4267", # conversion from "size_t" to "int", possible loss of data.
290 "/wd4389", # signed/unsigned mismatch.
291 ]
292 }
293
294 if (rtc_enable_sctp && rtc_build_usrsctp) {
295 include_dirs = [
296 # TODO(jiayl): move this into the public_configs of
297 # //third_party/usrsctp/BUILD.gn.
298 "//third_party/usrsctp/usrsctplib",
299 ]
300 deps += [ "//third_party/usrsctp" ]
301 }
302
303 deps += [
304 ":rtc_media_base",
305 "..:webrtc_common",
306 "../api:call_api",
307 "../api:transport_api",
zhihuang38ede132017-06-15 19:52:32308 "../p2p:rtc_p2p",
ehmaldonadof6a861a2017-07-19 17:40:47309 "../rtc_base:rtc_base",
310 "../rtc_base:rtc_base_approved",
zhihuang38ede132017-06-15 19:52:32311 "../system_wrappers",
312 ]
313}
314
315rtc_source_set("rtc_media") {
316 public_deps = [
317 ":rtc_audio_video",
318 ":rtc_data",
319 ]
320}
321
kjellander82a94492016-06-13 05:12:01322if (rtc_include_tests) {
323 config("rtc_unittest_main_config") {
324 # GN orders flags on a target before flags from configs. The default config
325 # adds -Wall, and this flag have to be after -Wall -- so they need to
326 # come from a config and can"t be on the target directly.
327 if (is_clang && is_ios) {
328 cflags = [ "-Wno-unused-variable" ]
329 }
330 }
331
mbonadei9087d492017-04-25 07:35:35332 rtc_source_set("rtc_media_tests_utils") {
kjellander82a94492016-06-13 05:12:01333 testonly = true
334
kjellanderec5c9062016-08-19 08:07:30335 include_dirs = []
336 public_deps = []
kjellandera2ef4f92017-03-06 14:04:55337 deps = [
aleloi440b6d92017-08-22 12:43:23338 "../call:video_stream_api",
kjellandera2ef4f92017-03-06 14:04:55339 "../modules/audio_coding:rent_a_codec",
340 "../modules/audio_processing:audio_processing",
eladalonc0d481a2017-08-02 14:39:07341 "../modules/rtp_rtcp:rtp_rtcp",
charujaincb728ea2017-09-18 10:08:08342 "../modules/video_coding:video_coding_utility",
kjellandera2ef4f92017-03-06 14:04:55343 "../p2p:rtc_p2p",
344 ]
kjellander82a94492016-06-13 05:12:01345 sources = [
346 "base/fakemediaengine.h",
347 "base/fakenetworkinterface.h",
jbauch5869f502017-06-29 19:31:36348 "base/fakertp.cc",
kjellander82a94492016-06-13 05:12:01349 "base/fakertp.h",
350 "base/fakevideocapturer.h",
351 "base/fakevideorenderer.h",
hbosb24b1ce2016-08-16 08:19:43352 "base/test/mock_mediachannel.h",
kjellander82a94492016-06-13 05:12:01353 "base/testutils.cc",
354 "base/testutils.h",
355 "engine/fakewebrtccall.cc",
356 "engine/fakewebrtccall.h",
kjellander82a94492016-06-13 05:12:01357 "engine/fakewebrtcdeviceinfo.h",
358 "engine/fakewebrtcvcmfactory.h",
359 "engine/fakewebrtcvideocapturemodule.h",
360 "engine/fakewebrtcvideoengine.h",
361 "engine/fakewebrtcvoiceengine.h",
362 ]
363
ehmaldonado7a2ce0b2016-09-05 08:35:44364 configs += [ ":rtc_unittest_main_config" ]
kjellander82a94492016-06-13 05:12:01365
366 if (rtc_build_libyuv) {
367 deps += [ "$rtc_libyuv_dir" ]
kjellanderec5c9062016-08-19 08:07:30368 public_deps += [ "$rtc_libyuv_dir" ]
kjellander82a94492016-06-13 05:12:01369 } else {
370 # Need to add a directory normally exported by libyuv.
371 include_dirs += [ "$rtc_libyuv_dir/include" ]
372 }
373
kjellandere40a7ee2016-10-17 06:56:12374 if (!build_with_chromium && is_clang) {
375 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 11:10:34376 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellander82a94492016-06-13 05:12:01377 }
378
379 deps += [
kjellandera2ef4f92017-03-06 14:04:55380 ":rtc_media",
381 ":rtc_media_base",
382 "..:webrtc_common",
383 "../api:call_api",
384 "../api:video_frame_api",
ilnikd60d06a2017-04-05 10:02:20385 "../api/video_codecs:video_codecs_api",
kjellandera2ef4f92017-03-06 14:04:55386 "../call:call_interfaces",
ehmaldonadof6a861a2017-07-19 17:40:47387 "../rtc_base:rtc_base",
388 "../rtc_base:rtc_base_approved",
389 "../rtc_base:rtc_base_tests_utils",
kjellandera2ef4f92017-03-06 14:04:55390 "../test:test_support",
kjellander82a94492016-06-13 05:12:01391 "//testing/gtest",
392 ]
393 public_deps += [ "//testing/gmock" ]
394 }
395
396 config("rtc_media_unittests_config") {
397 # GN orders flags on a target before flags from configs. The default config
398 # adds -Wall, and this flag have to be after -Wall -- so they need to
399 # come from a config and can"t be on the target directly.
400 # TODO(kjellander): Make the code compile without disabling these flags.
401 # See https://bugs.webrtc.org/3307.
402 if (is_clang && is_win) {
ehmaldonadod02fe4b2016-08-26 20:31:24403 cflags = [
404 # See https://bugs.chromium.org/p/webrtc/issues/detail?id=6266
405 # for -Wno-sign-compare
406 "-Wno-sign-compare",
ehmaldonadod02fe4b2016-08-26 20:31:24407 ]
kjellander82a94492016-06-13 05:12:01408 }
409 if (!is_win) {
410 cflags = [ "-Wno-sign-compare" ]
kjellander82a94492016-06-13 05:12:01411 }
412 }
413
ehmaldonado3a7f35b2016-09-14 12:10:01414 rtc_media_unittests_resources = [
Mirko Bonadei92ea95e2017-09-15 04:47:31415 "../resources/media/captured-320x240-2s-48.frames",
416 "../resources/media/faces.1280x720_P420.yuv",
417 "../resources/media/faces_I420.jpg",
418 "../resources/media/faces_I422.jpg",
419 "../resources/media/faces_I444.jpg",
420 "../resources/media/faces_I411.jpg",
421 "../resources/media/faces_I400.jpg",
ehmaldonado3a7f35b2016-09-14 12:10:01422 ]
kjellander32c4a202016-08-30 09:53:49423
424 if (is_ios) {
425 bundle_data("rtc_media_unittests_bundle_data") {
426 testonly = true
427 sources = rtc_media_unittests_resources
428 outputs = [
429 "{{bundle_resources_dir}}/{{source_file_part}}",
430 ]
431 }
432 }
433
ehmaldonado38a21322016-09-02 11:10:34434 rtc_test("rtc_media_unittests") {
kjellander82a94492016-06-13 05:12:01435 testonly = true
436
johan073ece42016-08-26 09:59:47437 defines = []
kjellandera2ef4f92017-03-06 14:04:55438 deps = [
439 "../pc:rtc_pc",
440 "../test:field_trial",
441 ]
kjellander82a94492016-06-13 05:12:01442 sources = [
443 "base/codec_unittest.cc",
444 "base/rtpdataengine_unittest.cc",
kjellander82a94492016-06-13 05:12:01445 "base/rtputils_unittest.cc",
446 "base/streamparams_unittest.cc",
447 "base/turnutils_unittest.cc",
448 "base/videoadapter_unittest.cc",
449 "base/videobroadcaster_unittest.cc",
450 "base/videocapturer_unittest.cc",
451 "base/videocommon_unittest.cc",
452 "base/videoengine_unittest.h",
solenberg76377c52017-02-21 08:54:31453 "engine/apm_helpers_unittest.cc",
magjeddd407022016-12-01 08:27:27454 "engine/internaldecoderfactory_unittest.cc",
kjellander82a94492016-06-13 05:12:01455 "engine/nullwebrtcvideoengine_unittest.cc",
ossuc54071d2016-08-17 09:45:41456 "engine/payload_type_mapper_unittest.cc",
magjed6cc25612017-07-10 10:26:36457 "engine/simulcast_encoder_adapter_unittest.cc",
kjellander82a94492016-06-13 05:12:01458 "engine/simulcast_unittest.cc",
magjedf6acc2a2016-11-22 09:43:03459 "engine/videodecodersoftwarefallbackwrapper_unittest.cc",
magjed614d5b72016-11-15 14:30:54460 "engine/videoencodersoftwarefallbackwrapper_unittest.cc",
kjellander82a94492016-06-13 05:12:01461 "engine/webrtcmediaengine_unittest.cc",
462 "engine/webrtcvideocapturer_unittest.cc",
noahricbe850e12017-01-20 09:07:26463 "engine/webrtcvideoencoderfactory_unittest.cc",
eladalonf1841382017-06-12 08:16:46464 "engine/webrtcvideoengine_unittest.cc",
kjellander82a94492016-06-13 05:12:01465 ]
466
oprypin45197522017-06-22 08:47:20467 # TODO(kthelgason): Reenable this test on iOS.
468 # See bugs.webrtc.org/5569
469 if (!is_ios) {
470 sources += [ "engine/webrtcvoiceengine_unittest.cc" ]
471 }
472
deadbeef40610e22016-12-22 18:53:38473 if (rtc_enable_sctp) {
deadbeef953c2ce2017-01-09 22:53:41474 sources += [ "sctp/sctptransport_unittest.cc" ]
deadbeef40610e22016-12-22 18:53:38475 }
476
ehmaldonado7a2ce0b2016-09-05 08:35:44477 configs += [ ":rtc_media_unittests_config" ]
kjellander82a94492016-06-13 05:12:01478
johan073ece42016-08-26 09:59:47479 if (rtc_use_h264) {
480 defines += [ "WEBRTC_USE_H264" ]
481 }
ossu11bfc532017-02-16 13:37:06482
483 if (rtc_opus_support_120ms_ptime) {
484 defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=1" ]
485 } else {
486 defines += [ "WEBRTC_OPUS_SUPPORT_120MS_PTIME=0" ]
487 }
488
kjellander82a94492016-06-13 05:12:01489 if (is_win) {
490 cflags = [
491 "/wd4245", # conversion from int to size_t, signed/unsigned mismatch.
492 "/wd4373", # virtual function override.
493 "/wd4389", # signed/unsigned mismatch.
494 ]
495 }
496
kjellandere40a7ee2016-10-17 06:56:12497 if (!build_with_chromium && is_clang) {
ehmaldonado38a21322016-09-02 11:10:34498 suppressed_configs += [
kjellander82a94492016-06-13 05:12:01499 "//build/config/clang:extra_warnings",
kjellandere40a7ee2016-10-17 06:56:12500
501 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
kjellander82a94492016-06-13 05:12:01502 "//build/config/clang:find_bad_constructs",
503 ]
504 }
505
ehmaldonado3a7f35b2016-09-14 12:10:01506 data = rtc_media_unittests_resources
507
kjellander82a94492016-06-13 05:12:01508 if (is_android) {
509 deps += [ "//testing/android/native_test:native_test_support" ]
kjellander28a0ffd2016-08-24 14:48:42510 shard_timeout = 900
511 }
kjellander32c4a202016-08-30 09:53:49512
513 if (is_ios) {
514 deps += [ ":rtc_media_unittests_bundle_data" ]
kjellander82a94492016-06-13 05:12:01515 }
516
517 deps += [
kjellander82a94492016-06-13 05:12:01518 ":rtc_media",
kjellandera2ef4f92017-03-06 14:04:55519 ":rtc_media_base",
mbonadei9087d492017-04-25 07:35:35520 ":rtc_media_tests_utils",
kjellandera2ef4f92017-03-06 14:04:55521 "../api:video_frame_api",
522 "../api/audio_codecs:builtin_audio_decoder_factory",
ossueb1fde42017-05-02 13:46:30523 "../api/audio_codecs:builtin_audio_encoder_factory",
ilnikd60d06a2017-04-05 10:02:20524 "../api/video_codecs:video_codecs_api",
kjellander82a94492016-06-13 05:12:01525 "../audio",
kjellandera2ef4f92017-03-06 14:04:55526 "../call:call_interfaces",
527 "../common_video:common_video",
528 "../logging:rtc_event_log_api",
aleloi5de52fd2016-11-10 09:05:34529 "../modules/audio_device:mock_audio_device",
kjellandera2ef4f92017-03-06 14:04:55530 "../modules/audio_processing:audio_processing",
magjed6cc25612017-07-10 10:26:36531 "../modules/video_coding:simulcast_test_utility",
kjellandera2ef4f92017-03-06 14:04:55532 "../modules/video_coding:video_coding_utility",
533 "../modules/video_coding:webrtc_vp8",
deadbeef59edb922017-04-18 22:49:09534 "../p2p:p2p_test_utils",
ehmaldonadof6a861a2017-07-19 17:40:47535 "../rtc_base:rtc_base",
536 "../rtc_base:rtc_base_approved",
537 "../rtc_base:rtc_base_tests_main",
538 "../rtc_base:rtc_base_tests_utils",
kjellander82a94492016-06-13 05:12:01539 "../system_wrappers:metrics_default",
kwiberg37e99fd2017-04-10 12:15:48540 "../test:audio_codec_mocks",
kjellandera2ef4f92017-03-06 14:04:55541 "../test:test_support",
542 "../voice_engine:voice_engine",
kjellander82a94492016-06-13 05:12:01543 ]
544 }
545}