blob: a238357edc8c5902d86c25294740124e1500d35a [file] [log] [blame]
hjonaa32c3e2015-12-14 03:58:111# Copyright (c) 2015 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 14:58:229import("../webrtc.gni")
Sami Kalliomaki9c0c75b2016-06-29 12:55:0010if (is_android) {
11 import("//build/config/android/config.gni")
12 import("//build/config/android/rules.gni")
13}
kjellanderc76dc952016-06-03 10:09:3214
15group("api") {
Per Kjellandera7f2d842018-01-10 15:54:5316 visibility = [ "*" ]
Dan Minor9c686132018-01-15 15:20:0017 deps = []
18
19 if (!build_with_mozilla) {
20 deps += [ ":libjingle_peerconnection_api" ]
21 }
kjellanderc76dc952016-06-03 10:09:3222}
23
ehmaldonado38a21322016-09-02 11:10:3424rtc_source_set("call_api") {
Per Kjellandera7f2d842018-01-10 15:54:5325 visibility = [ "*" ]
kjellandera69d9732016-08-31 14:33:0526 sources = [
kjellandera69d9732016-08-31 14:33:0527 "call/audio_sink.h",
kjellandera69d9732016-08-31 14:33:0528 ]
29
kjellandera69d9732016-08-31 14:33:0530 deps = [
31 # TODO(kjellander): Add remaining dependencies when webrtc:4243 is done.
aleloia8eb7562016-11-28 15:02:1332 ":transport_api",
kjellandera69d9732016-08-31 14:33:0533 "..:webrtc_common",
ehmaldonadof6a861a2017-07-19 17:40:4734 "../rtc_base:rtc_base_approved",
Gustaf Ullberg2ae140a2018-02-16 12:43:4935 "audio:audio_mixer_api",
kwiberg087bd342017-02-10 16:15:4436 "audio_codecs:audio_codecs_api",
kjellandera69d9732016-08-31 14:33:0537 ]
38}
39
Niels Möller8366e172018-02-14 11:20:1340rtc_source_set("callfactory_api") {
41 visibility = [ "*" ]
42 sources = [
43 "call/callfactoryinterface.h",
44 ]
45}
46
ossu7bb87ee2017-01-23 12:56:2547rtc_static_library("libjingle_peerconnection_api") {
Per Kjellandera7f2d842018-01-10 15:54:5348 visibility = [ "*" ]
kjellanderc76dc952016-06-03 10:09:3249 cflags = []
50 sources = [
Steve Anton36b28db2017-10-26 18:27:1751 "candidate.cc",
Patrik Höglunde2d6a062017-10-05 12:53:3352 "candidate.h",
Patrik Höglund7aee3d52017-11-15 12:15:1753 "cryptoparams.h",
kjellanderc76dc952016-06-03 10:09:3254 "datachannelinterface.h",
kjellanderc76dc952016-06-03 10:09:3255 "dtmfsenderinterface.h",
Steve Anton845bb732017-12-05 20:50:2656 "jsep.cc",
kjellanderc76dc952016-06-03 10:09:3257 "jsep.h",
kjellanderc76dc952016-06-03 10:09:3258 "jsepicecandidate.h",
kjellanderc76dc952016-06-03 10:09:3259 "jsepsessiondescription.h",
kjellanderc76dc952016-06-03 10:09:3260 "mediaconstraintsinterface.cc",
61 "mediaconstraintsinterface.h",
ossu7bb87ee2017-01-23 12:56:2562 "mediastreaminterface.cc",
Patrik Höglund825249f2018-01-09 09:38:2163 "mediastreaminterface.h",
kjellanderc76dc952016-06-03 10:09:3264 "mediastreamproxy.h",
kjellanderc76dc952016-06-03 10:09:3265 "mediastreamtrackproxy.h",
ossu7bb87ee2017-01-23 12:56:2566 "mediatypes.cc",
67 "mediatypes.h",
kjellanderc76dc952016-06-03 10:09:3268 "notifier.h",
kjellanderc76dc952016-06-03 10:09:3269 "peerconnectionfactoryproxy.h",
Niels Möller8366e172018-02-14 11:20:1370 "peerconnectioninterface.h",
kjellanderc76dc952016-06-03 10:09:3271 "peerconnectionproxy.h",
Steve Antonf2737d22017-10-31 23:27:3472 "proxy.cc",
kjellanderc76dc952016-06-03 10:09:3273 "proxy.h",
deadbeef6038e972017-02-17 07:31:3374 "rtcerror.cc",
75 "rtcerror.h",
Patrik Höglund3e113432017-12-15 13:40:1076 "rtp_headers.cc",
77 "rtp_headers.h",
Stefan Holmer1acbd682017-09-01 13:29:2878 "rtpparameters.cc",
kjellanderc76dc952016-06-03 10:09:3279 "rtpparameters.h",
Danil Chapovalov2a5ce2b2018-02-07 08:38:3180 "rtpreceiverinterface.cc",
kjellanderc76dc952016-06-03 10:09:3281 "rtpreceiverinterface.h",
kjellanderc76dc952016-06-03 10:09:3282 "rtpsenderinterface.h",
Steve Anton6e634bf2017-11-13 18:44:5383 "rtptransceiverinterface.h",
Henrik Boström31638672017-11-23 16:48:3284 "setremotedescriptionobserverinterface.h",
kjellanderc76dc952016-06-03 10:09:3285 "statstypes.cc",
86 "statstypes.h",
Jonas Orelandbdcee282017-10-10 12:01:4087 "turncustomizer.h",
Steve Antonf2737d22017-10-31 23:27:3488 "umametrics.cc",
ossu7bb87ee2017-01-23 12:56:2589 "umametrics.h",
Patrik Höglund9e194032018-01-04 14:58:2090 "videosourceinterface.cc",
91 "videosourceinterface.h",
kjellanderc76dc952016-06-03 10:09:3292 "videosourceproxy.h",
kjellanderc76dc952016-06-03 10:09:3293 ]
94
kjellandere40a7ee2016-10-17 06:56:1295 if (!build_with_chromium && is_clang) {
kjellanderfd5b4e92016-06-13 19:08:3396 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 11:10:3497 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellanderc76dc952016-06-03 10:09:3298 }
99
kjellanderc76dc952016-06-03 10:09:32100 deps = [
Patrik Höglund3e113432017-12-15 13:40:10101 ":array_view",
Niels Möllera6fe2612018-01-19 10:28:54102 ":audio_options_api",
Niels Möller8366e172018-02-14 11:20:13103 ":callfactory_api",
Ying Wang0dd1b0a2018-02-20 11:50:27104 ":fec_controller_api",
Niels Möller8366e172018-02-14 11:20:13105 ":libjingle_logging_api",
Patrik Höglunde2d6a062017-10-05 12:53:33106 ":optional",
hbos74e1a4f2016-09-16 06:33:01107 ":rtc_stats_api",
Patrik Höglundb874a352017-11-27 13:32:41108 ":video_frame_api",
Gustaf Ullberg2ae140a2018-02-16 12:43:49109 "audio:audio_mixer_api",
Patrik Höglundb5b5bce2017-11-13 09:19:58110 "audio_codecs:audio_codecs_api",
111
112 # Basically, don't add stuff here. You might break sensitive downstream
113 # targets like pnacl. API should not depend on anything outside of this
114 # file, really. All these should arguably go away in time.
Patrik Höglund3e113432017-12-15 13:40:10115 "..:typedefs",
kjellander8a116632017-04-21 12:17:08116 "..:webrtc_common",
Niels Möller8366e172018-02-14 11:20:13117 "../logging:rtc_event_log_api",
Niels Möller6daa2782018-01-23 09:37:42118 "../media:rtc_media_config",
Patrik Höglundb874a352017-11-27 13:32:41119 "../modules/audio_processing:audio_processing_statistics",
Patrik Höglund3e113432017-12-15 13:40:10120 "../rtc_base:checks",
121 "../rtc_base:deprecation",
ehmaldonadof6a861a2017-07-19 17:40:47122 "../rtc_base:rtc_base",
123 "../rtc_base:rtc_base_approved",
Patrik Höglund3e113432017-12-15 13:40:10124 "../rtc_base:stringutils",
kjellanderc76dc952016-06-03 10:09:32125 ]
Niels Möller8366e172018-02-14 11:20:13126
kjellander8a116632017-04-21 12:17:08127 if (is_nacl) {
Patrik Höglund30bd03b2017-12-19 10:45:31128 # This is needed by .h files included from rtc_base.
kjellander8a116632017-04-21 12:17:08129 deps += [ "//native_client_sdk/src/libraries/nacl_io" ]
130 }
ossu7bb87ee2017-01-23 12:56:25131}
kjellanderc76dc952016-06-03 10:09:32132
Elad Alon80810732017-10-06 11:07:32133rtc_source_set("libjingle_logging_api") {
Per Kjellandera7f2d842018-01-10 15:54:53134 visibility = [ "*" ]
Elad Alon80810732017-10-06 11:07:32135 sources = [
136 "rtceventlogoutput.h",
137 ]
138}
139
deadbeefe814a0d2017-02-26 02:15:09140rtc_source_set("ortc_api") {
Per Kjellandera7f2d842018-01-10 15:54:53141 visibility = [ "*" ]
deadbeefe814a0d2017-02-26 02:15:09142 sources = [
zhihuang55adc0e2017-03-11 02:33:45143 "ortc/mediadescription.cc",
144 "ortc/mediadescription.h",
deadbeefe814a0d2017-02-26 02:15:09145 "ortc/ortcfactoryinterface.h",
146 "ortc/ortcrtpreceiverinterface.h",
147 "ortc/ortcrtpsenderinterface.h",
148 "ortc/packettransportinterface.h",
149 "ortc/rtptransportcontrollerinterface.h",
150 "ortc/rtptransportinterface.h",
zhihuang55adc0e2017-03-11 02:33:45151 "ortc/sessiondescription.cc",
152 "ortc/sessiondescription.h",
zhihuangd3501ad2017-03-03 22:39:06153 "ortc/srtptransportinterface.h",
deadbeefe814a0d2017-02-26 02:15:09154 "ortc/udptransportinterface.h",
155 ]
156
157 # For mediastreaminterface.h, etc.
158 # TODO(deadbeef): Create a separate target for the common things ORTC and
159 # PeerConnection code shares, so that ortc_api can depend on that instead of
160 # libjingle_peerconnection_api.
Patrik Höglund7aee3d52017-11-15 12:15:17161 deps = [
deadbeefe814a0d2017-02-26 02:15:09162 ":libjingle_peerconnection_api",
Patrik Höglund7aee3d52017-11-15 12:15:17163 ":optional",
164 "..:webrtc_common",
165 "../rtc_base:rtc_base",
deadbeefe814a0d2017-02-26 02:15:09166 ]
zhihuang55adc0e2017-03-11 02:33:45167 if (!build_with_chromium && is_clang) {
168 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
169 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
170 }
deadbeefe814a0d2017-02-26 02:15:09171}
172
hbos74e1a4f2016-09-16 06:33:01173rtc_source_set("rtc_stats_api") {
Per Kjellandera7f2d842018-01-10 15:54:53174 visibility = [ "*" ]
hbos74e1a4f2016-09-16 06:33:01175 cflags = []
176 sources = [
177 "stats/rtcstats.h",
178 "stats/rtcstats_objects.h",
ossu7bb87ee2017-01-23 12:56:25179 "stats/rtcstatscollectorcallback.h",
hbos74e1a4f2016-09-16 06:33:01180 "stats/rtcstatsreport.h",
181 ]
182
183 deps = [
Patrik Höglunda8005cf2017-12-13 15:05:42184 "../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 17:40:47185 "../rtc_base:rtc_base_approved",
hbos74e1a4f2016-09-16 06:33:01186 ]
187}
188
Niels Möllera6fe2612018-01-19 10:28:54189rtc_source_set("audio_options_api") {
190 visibility = [ "*" ]
191 sources = [
192 "audio_options.h",
193 ]
194
195 deps = [
196 ":optional",
197 "../rtc_base:rtc_base_approved",
198 ]
199}
200
aleloia8eb7562016-11-28 15:02:13201rtc_source_set("transport_api") {
Per Kjellandera7f2d842018-01-10 15:54:53202 visibility = [ "*" ]
aleloia8eb7562016-11-28 15:02:13203 sources = [
Dino Radaković1807d572018-02-22 13:18:06204 "call/transport.cc",
aleloia8eb7562016-11-28 15:02:13205 "call/transport.h",
206 ]
207}
nisseb2250e52016-12-02 12:01:14208
Ying Wang3b790f32018-01-19 16:58:57209rtc_source_set("fec_controller_api") {
210 visibility = [ "*" ]
211 sources = [
212 "fec_controller.h",
213 ]
214
215 deps = [
Ying Wang0dd1b0a2018-02-20 11:50:27216 "..:webrtc_common",
217 "../modules:module_fec_api",
Ying Wang3b790f32018-01-19 16:58:57218 ]
219}
220
nisseb2250e52016-12-02 12:01:14221rtc_source_set("video_frame_api") {
Per Kjellandera7f2d842018-01-10 15:54:53222 visibility = [ "*" ]
nisseb2250e52016-12-02 12:01:14223 sources = [
ilnik6d5b4d62017-08-30 10:32:14224 "video/video_content_type.cc",
225 "video/video_content_type.h",
nisseaf916892017-01-10 15:44:26226 "video/video_frame.cc",
227 "video/video_frame.h",
magjed712338e2017-05-11 12:11:57228 "video/video_frame_buffer.cc",
nisseaf916892017-01-10 15:44:26229 "video/video_frame_buffer.h",
nisseb2250e52016-12-02 12:01:14230 "video/video_rotation.h",
ilnik2edc6842017-07-06 10:06:50231 "video/video_timing.cc",
ilnik04f4d122017-06-19 14:18:55232 "video/video_timing.h",
Niels Möller9d138fc2018-02-15 15:58:43233 "videosinkinterface.h",
nisseb2250e52016-12-02 12:01:14234 ]
235
236 deps = [
Patrik Höglunda8005cf2017-12-13 15:05:42237 "../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 17:40:47238 "../rtc_base:rtc_base_approved",
nisseb2250e52016-12-02 12:01:14239 ]
nisseb2250e52016-12-02 12:01:14240}
241
philipeld5a272f2018-02-21 13:30:34242rtc_source_set("encoded_frame_api") {
243 visibility = [ "*" ]
244 sources = [
245 "video/encoded_frame.h",
246 ]
247
248 deps = [
249 "../modules/video_coding:encoded_frame",
250 ]
251}
252
Patrik Höglundb5b5bce2017-11-13 09:19:58253rtc_source_set("video_frame_api_i420") {
Per Kjellandera7f2d842018-01-10 15:54:53254 visibility = [ "*" ]
Patrik Höglundb5b5bce2017-11-13 09:19:58255 sources = [
Patrik Höglundb874a352017-11-27 13:32:41256 "video/i420_buffer.cc",
Patrik Höglundb5b5bce2017-11-13 09:19:58257 "video/i420_buffer.h",
258 ]
259 deps = [
260 ":video_frame_api",
Patrik Höglunda8005cf2017-12-13 15:05:42261 "../rtc_base:checks",
Patrik Höglund76df0df2017-12-19 10:50:21262 "../rtc_base:rtc_base",
Patrik Höglundb5b5bce2017-11-13 09:19:58263 "../system_wrappers",
Mirko Bonadei401d0562017-12-14 10:24:00264 "//third_party/libyuv",
Patrik Höglundb5b5bce2017-11-13 09:19:58265 ]
266}
267
kwiberg529662a2017-09-04 12:43:17268rtc_source_set("array_view") {
Per Kjellandera7f2d842018-01-10 15:54:53269 visibility = [ "*" ]
kwiberg529662a2017-09-04 12:43:17270 sources = [
271 "array_view.h",
272 ]
273 deps = [
Patrik Höglunda8005cf2017-12-13 15:05:42274 "../rtc_base:checks",
275 "../rtc_base:type_traits",
kwiberg529662a2017-09-04 12:43:17276 ]
277}
278
kwiberg84f6a3f2017-09-05 15:43:13279rtc_source_set("optional") {
Per Kjellandera7f2d842018-01-10 15:54:53280 visibility = [ "*" ]
kwiberg84f6a3f2017-09-05 15:43:13281 sources = [
282 "optional.cc",
283 "optional.h",
284 ]
285 deps = [
286 ":array_view",
Patrik Höglunda8005cf2017-12-13 15:05:42287 "../rtc_base:checks",
288 "../rtc_base:sanitizer",
kwiberg84f6a3f2017-09-05 15:43:13289 ]
290}
291
Niels Möller9155e492017-10-23 09:22:30292rtc_source_set("refcountedbase") {
Per Kjellandera7f2d842018-01-10 15:54:53293 visibility = [ "*" ]
Niels Möller9155e492017-10-23 09:22:30294 sources = [
295 "refcountedbase.h",
296 ]
297 deps = [
298 "../rtc_base:rtc_base_approved",
299 ]
300}
301
kjellander1993b1d2017-03-06 08:29:21302rtc_source_set("libjingle_peerconnection_test_api") {
Per Kjellandera7f2d842018-01-10 15:54:53303 visibility = [ "*" ]
kjellander1993b1d2017-03-06 08:29:21304 testonly = true
305 sources = [
306 "test/fakeconstraints.h",
307 ]
308
kjellander1993b1d2017-03-06 08:29:21309 deps = [
Mirko Bonadei34814c72018-01-11 09:13:56310 ":libjingle_peerconnection_api",
ehmaldonadof6a861a2017-07-19 17:40:47311 "../rtc_base:rtc_base_approved",
kjellander1993b1d2017-03-06 08:29:21312 ]
313}
314
kjellanderfd5b4e92016-06-13 19:08:33315if (rtc_include_tests) {
kjellander2f6af9c2017-03-03 06:26:23316 rtc_source_set("mock_audio_mixer") {
317 testonly = true
318 sources = [
319 "test/mock_audio_mixer.h",
320 ]
321
kjellander2f6af9c2017-03-03 06:26:23322 deps = [
jianjun.zhuc0247402017-07-11 13:20:45323 "../test:test_support",
Gustaf Ullberg2ae140a2018-02-16 12:43:49324 "audio:audio_mixer_api",
kjellander2f6af9c2017-03-03 06:26:23325 ]
326 }
327
Patrik Höglund4b9e6ba2017-12-19 09:32:11328 rtc_source_set("mock_rtp") {
329 testonly = true
330 sources = [
331 "test/mock_rtpreceiver.h",
332 "test/mock_rtpsender.h",
333 ]
334
335 deps = [
336 ":libjingle_peerconnection_api",
337 "../test:test_support",
Patrik Höglund4b9e6ba2017-12-19 09:32:11338 ]
339 }
340
Emircan Uysalerdbcac7f2017-10-31 06:10:12341 rtc_source_set("mock_video_codec_factory") {
342 testonly = true
343 sources = [
344 "test/mock_video_decoder_factory.h",
345 "test/mock_video_encoder_factory.h",
346 ]
347
Emircan Uysalerdbcac7f2017-10-31 06:10:12348 deps = [
Mirko Bonadei34814c72018-01-11 09:13:56349 "../api/video_codecs:video_codecs_api",
Emircan Uysalerdbcac7f2017-10-31 06:10:12350 "../test:test_support",
Emircan Uysalerdbcac7f2017-10-31 06:10:12351 ]
352 }
353
kjellander2f6af9c2017-03-03 06:26:23354 rtc_source_set("fakemetricsobserver") {
355 testonly = true
356 sources = [
357 "fakemetricsobserver.cc",
358 "fakemetricsobserver.h",
359 ]
360 deps = [
Edward Lemur872cf382017-11-20 17:41:50361 "../media:rtc_media_base",
Patrik Höglunda8005cf2017-12-13 15:05:42362 "../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 17:40:47363 "../rtc_base:rtc_base_approved",
kjellander2f6af9c2017-03-03 06:26:23364 ]
365 if (!build_with_chromium && is_clang) {
366 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
367 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
368 }
Dan Minor9c686132018-01-15 15:20:00369 if (!build_with_mozilla) {
370 deps += [ ":libjingle_peerconnection_api" ]
371 }
kjellander2f6af9c2017-03-03 06:26:23372 }
373
deadbeefb5388d72017-02-24 09:17:43374 rtc_source_set("rtc_api_unittests") {
deadbeef6038e972017-02-17 07:31:33375 testonly = true
kjellandere0629c02017-04-25 11:04:50376
deadbeef6038e972017-02-17 07:31:33377 sources = [
kwiberg529662a2017-09-04 12:43:17378 "array_view_unittest.cc",
kwiberg84f6a3f2017-09-05 15:43:13379 "optional_unittest.cc",
zhihuang55adc0e2017-03-11 02:33:45380 "ortc/mediadescription_unittest.cc",
381 "ortc/sessiondescription_unittest.cc",
deadbeef6038e972017-02-17 07:31:33382 "rtcerror_unittest.cc",
Stefan Holmer1acbd682017-09-01 13:29:28383 "rtpparameters_unittest.cc",
deadbeef6038e972017-02-17 07:31:33384 ]
385
386 if (!build_with_chromium && is_clang) {
387 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
388 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
389 }
390
391 deps = [
kwiberg529662a2017-09-04 12:43:17392 ":array_view",
deadbeef6038e972017-02-17 07:31:33393 ":libjingle_peerconnection_api",
Henrik Boström31638672017-11-23 16:48:32394 ":libjingle_peerconnection_test_api",
kwiberg84f6a3f2017-09-05 15:43:13395 ":optional",
zhihuang55adc0e2017-03-11 02:33:45396 ":ortc_api",
Patrik Höglunda8005cf2017-12-13 15:05:42397 "../rtc_base:checks",
kwiberg529662a2017-09-04 12:43:17398 "../rtc_base:rtc_base_approved",
399 "../rtc_base:rtc_base_tests_utils",
jianjun.zhuc0247402017-07-11 13:20:45400 "../test:test_support",
deadbeef6038e972017-02-17 07:31:33401 ]
deadbeef6038e972017-02-17 07:31:33402 }
kjellanderfd5b4e92016-06-13 19:08:33403}