1 # 2 # libjingle 3 # Copyright 2012 Google Inc. 4 # 5 # Redistribution and use in source and binary forms, with or without 6 # modification, are permitted provided that the following conditions are met: 7 # 8 # 1. Redistributions of source code must retain the above copyright notice, 9 # this list of conditions and the following disclaimer. 10 # 2. Redistributions in binary form must reproduce the above copyright notice, 11 # this list of conditions and the following disclaimer in the documentation 12 # and/or other materials provided with the distribution. 13 # 3. The name of the author may not be used to endorse or promote products 14 # derived from this software without specific prior written permission. 15 # 16 # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED 17 # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 19 # EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 20 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 21 # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 22 # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 23 # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 24 # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 25 # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 27 { 28 'includes': ['build/common.gypi'], 29 'conditions': [ 30 ['os_posix == 1 and OS != "mac" and OS != "ios"', { 31 'conditions': [ 32 ['sysroot!=""', { 33 'variables': { 34 'pkg-config': '../../../build/linux/pkg-config-wrapper "<(sysroot)" "<(target_arch)"', 35 }, 36 }, { 37 'variables': { 38 'pkg-config': 'pkg-config' 39 }, 40 }], 41 ], 42 }], 43 ['OS=="linux" or OS=="android"', { 44 'targets': [ 45 { 46 'target_name': 'libjingle_peerconnection_jni', 47 'type': 'static_library', 48 'dependencies': [ 49 '<(webrtc_root)/system_wrappers/system_wrappers.gyp:field_trial_default', 50 'libjingle_peerconnection', 51 ], 52 'sources': [ 53 'app/webrtc/java/jni/classreferenceholder.cc', 54 'app/webrtc/java/jni/classreferenceholder.h', 55 'app/webrtc/java/jni/jni_helpers.cc', 56 'app/webrtc/java/jni/jni_helpers.h', 57 'app/webrtc/java/jni/native_handle_impl.cc', 58 'app/webrtc/java/jni/native_handle_impl.h', 59 'app/webrtc/java/jni/peerconnection_jni.cc', 60 ], 61 'include_dirs': [ 62 '<(libyuv_dir)/include', 63 ], 64 'conditions': [ 65 ['OS=="linux"', { 66 'include_dirs': [ 67 '<(java_home)/include', 68 '<(java_home)/include/linux', 69 ], 70 }], 71 ['build_json==1', { 72 'dependencies': [ 73 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', 74 ], 75 'export_dependent_settings': [ 76 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', 77 ], 78 }], 79 ['OS=="android"', { 80 'sources': [ 81 'app/webrtc/androidvideocapturer.cc', 82 'app/webrtc/androidvideocapturer.h', 83 'app/webrtc/java/jni/androidmediacodeccommon.h', 84 'app/webrtc/java/jni/androidmediadecoder_jni.cc', 85 'app/webrtc/java/jni/androidmediadecoder_jni.h', 86 'app/webrtc/java/jni/androidmediaencoder_jni.cc', 87 'app/webrtc/java/jni/androidmediaencoder_jni.h', 88 'app/webrtc/java/jni/androidnetworkmonitor_jni.cc', 89 'app/webrtc/java/jni/androidnetworkmonitor_jni.h', 90 'app/webrtc/java/jni/androidvideocapturer_jni.cc', 91 'app/webrtc/java/jni/androidvideocapturer_jni.h', 92 'app/webrtc/java/jni/surfacetexturehelper_jni.cc', 93 'app/webrtc/java/jni/surfacetexturehelper_jni.h', 94 ] 95 }], 96 ], 97 }, 98 { 99 'target_name': 'libjingle_peerconnection_so', 100 'type': 'shared_library', 101 'dependencies': [ 102 'libjingle_peerconnection', 103 'libjingle_peerconnection_jni', 104 ], 105 'sources': [ 106 'app/webrtc/java/jni/jni_onload.cc', 107 ], 108 'variables': { 109 # This library uses native JNI exports; tell GYP so that the 110 # required symbols will be kept. 111 'use_native_jni_exports': 1, 112 }, 113 'conditions': [ 114 ['OS=="linux"', { 115 'defines': [ 116 'HAVE_GTK', 117 ], 118 'include_dirs': [ 119 '<(java_home)/include', 120 '<(java_home)/include/linux', 121 ], 122 'conditions': [ 123 ['use_gtk==1', { 124 'link_settings': { 125 'libraries': [ 126 '<!@(pkg-config --libs-only-l gobject-2.0 gthread-2.0' 127 ' gtk+-2.0)', 128 ], 129 }, 130 }], 131 ], 132 }], 133 ], 134 }, 135 { 136 'target_name': 'libjingle_peerconnection_jar', 137 'type': 'none', 138 'actions': [ 139 { 140 # TODO(jiayl): extract peerconnection_java_files and android_java_files into a webrtc 141 # gyp var that can be included here, or better yet, build a proper .jar in webrtc 142 # and include it here. 143 'variables': { 144 'java_src_dir': 'app/webrtc/java/src', 145 'webrtc_base_dir': '<(webrtc_root)/base', 146 'webrtc_modules_dir': '<(webrtc_root)/modules', 147 'build_jar_log': '<(INTERMEDIATE_DIR)/build_jar.log', 148 'peerconnection_java_files': [ 149 'app/webrtc/java/src/org/webrtc/AudioSource.java', 150 'app/webrtc/java/src/org/webrtc/AudioTrack.java', 151 'app/webrtc/java/src/org/webrtc/CallSessionFileRotatingLogSink.java', 152 'app/webrtc/java/src/org/webrtc/DataChannel.java', 153 'app/webrtc/java/src/org/webrtc/IceCandidate.java', 154 'app/webrtc/java/src/org/webrtc/MediaConstraints.java', 155 'app/webrtc/java/src/org/webrtc/MediaSource.java', 156 'app/webrtc/java/src/org/webrtc/MediaStream.java', 157 'app/webrtc/java/src/org/webrtc/MediaStreamTrack.java', 158 'app/webrtc/java/src/org/webrtc/PeerConnectionFactory.java', 159 'app/webrtc/java/src/org/webrtc/PeerConnection.java', 160 'app/webrtc/java/src/org/webrtc/RtpReceiver.java', 161 'app/webrtc/java/src/org/webrtc/RtpSender.java', 162 'app/webrtc/java/src/org/webrtc/SdpObserver.java', 163 'app/webrtc/java/src/org/webrtc/StatsObserver.java', 164 'app/webrtc/java/src/org/webrtc/StatsReport.java', 165 'app/webrtc/java/src/org/webrtc/SessionDescription.java', 166 'app/webrtc/java/src/org/webrtc/VideoCapturer.java', 167 'app/webrtc/java/src/org/webrtc/VideoRenderer.java', 168 'app/webrtc/java/src/org/webrtc/VideoSource.java', 169 'app/webrtc/java/src/org/webrtc/VideoTrack.java', 170 '<(webrtc_base_dir)/java/src/org/webrtc/Logging.java', 171 ], 172 'android_java_files': [ 173 'app/webrtc/java/android/org/webrtc/Camera2Enumerator.java', 174 'app/webrtc/java/android/org/webrtc/CameraEnumerationAndroid.java', 175 'app/webrtc/java/android/org/webrtc/CameraEnumerator.java', 176 'app/webrtc/java/android/org/webrtc/EglBase.java', 177 'app/webrtc/java/android/org/webrtc/EglBase10.java', 178 'app/webrtc/java/android/org/webrtc/EglBase14.java', 179 'app/webrtc/java/android/org/webrtc/GlRectDrawer.java', 180 'app/webrtc/java/android/org/webrtc/GlShader.java', 181 'app/webrtc/java/android/org/webrtc/GlUtil.java', 182 'app/webrtc/java/android/org/webrtc/GlTextureFrameBuffer.java', 183 'app/webrtc/java/android/org/webrtc/NetworkMonitor.java', 184 'app/webrtc/java/android/org/webrtc/NetworkMonitorAutoDetect.java', 185 'app/webrtc/java/android/org/webrtc/RendererCommon.java', 186 'app/webrtc/java/android/org/webrtc/SurfaceTextureHelper.java', 187 'app/webrtc/java/android/org/webrtc/SurfaceViewRenderer.java', 188 'app/webrtc/java/android/org/webrtc/ThreadUtils.java', 189 'app/webrtc/java/android/org/webrtc/VideoCapturerAndroid.java', 190 'app/webrtc/java/android/org/webrtc/VideoRendererGui.java', 191 'app/webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java', 192 'app/webrtc/java/src/org/webrtc/MediaCodecVideoEncoder.java', 193 '<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViEAndroidGLES20.java', 194 '<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViERenderer.java', 195 '<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViESurfaceRenderer.java', 196 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/BuildInfo.java', 197 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRtcAudioEffects.java', 198 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRtcAudioManager.java', 199 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRtcAudioUtils.java', 200 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRtcAudioRecord.java', 201 '<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRtcAudioTrack.java', 202 ], 203 }, 204 'action_name': 'create_jar', 205 'inputs': [ 206 'build/build_jar.sh', 207 '<@(java_files)', 208 ], 209 'outputs': [ 210 '<(PRODUCT_DIR)/libjingle_peerconnection.jar', 211 ], 212 'conditions': [ 213 ['OS=="android"', { 214 'variables': { 215 'java_files': ['<@(peerconnection_java_files)', '<@(android_java_files)'], 216 'build_classpath': '<(java_src_dir):<(DEPTH)/third_party/android_tools/sdk/platforms/android-<(android_sdk_version)/android.jar', 217 }, 218 }, { 219 'variables': { 220 'java_files': ['<@(peerconnection_java_files)'], 221 'build_classpath': '<(java_src_dir)', 222 }, 223 }], 224 ], 225 'action': [ 226 'bash', '-ec', 227 'mkdir -p <(INTERMEDIATE_DIR) && ' 228 '{ build/build_jar.sh <(java_home) <@(_outputs) ' 229 ' <(INTERMEDIATE_DIR)/build_jar.tmp ' 230 ' <(build_classpath) <@(java_files) ' 231 ' > <(build_jar_log) 2>&1 || ' 232 ' { cat <(build_jar_log) ; exit 1; } }' 233 ], 234 }, 235 ], 236 'dependencies': [ 237 'libjingle_peerconnection_so', 238 ], 239 }, 240 ], 241 }], 242 ['OS=="android"', { 243 'targets': [ 244 { 245 # |libjingle_peerconnection_java| builds a jar file with name 246 # libjingle_peerconnection_java.jar using Chromes build system. 247 # It includes all Java files needed to setup a PeeerConnection call 248 # from Android. 249 # TODO(perkj): Consider replacing the use of 250 # libjingle_peerconnection_jar with this target everywhere. 251 'target_name': 'libjingle_peerconnection_java', 252 'type': 'none', 253 'dependencies': [ 254 'libjingle_peerconnection_so', 255 ], 256 'variables': { 257 # Designate as Chromium code and point to our lint settings to 258 # enable linting of the WebRTC code (this is the only way to make 259 # lint_action invoke the Android linter). 260 'android_manifest_path': '<(webrtc_root)/build/android/AndroidManifest.xml', 261 'suppressions_file': '<(webrtc_root)/build/android/suppressions.xml', 262 'chromium_code': 1, 263 'java_in_dir': 'app/webrtc/java', 264 'webrtc_base_dir': '<(webrtc_root)/base', 265 'webrtc_modules_dir': '<(webrtc_root)/modules', 266 'additional_src_dirs' : [ 267 'app/webrtc/java/android', 268 '<(webrtc_base_dir)/java/src', 269 '<(webrtc_modules_dir)/audio_device/android/java/src', 270 '<(webrtc_modules_dir)/video_render/android/java/src', 271 ], 272 }, 273 'includes': ['../build/java.gypi'], 274 }, # libjingle_peerconnection_java 275 ] 276 }], 277 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', { 278 # The >= 10.7 above is required for ARC. 279 'targets': [ 280 { 281 'target_name': 'libjingle_peerconnection_objc', 282 'type': 'static_library', 283 'dependencies': [ 284 'libjingle_peerconnection', 285 ], 286 'sources': [ 287 'app/webrtc/objc/RTCAudioTrack+Internal.h', 288 'app/webrtc/objc/RTCAudioTrack.mm', 289 'app/webrtc/objc/RTCDataChannel+Internal.h', 290 'app/webrtc/objc/RTCDataChannel.mm', 291 'app/webrtc/objc/RTCEnumConverter.h', 292 'app/webrtc/objc/RTCEnumConverter.mm', 293 'app/webrtc/objc/RTCFileLogger.mm', 294 'app/webrtc/objc/RTCI420Frame+Internal.h', 295 'app/webrtc/objc/RTCI420Frame.mm', 296 'app/webrtc/objc/RTCICECandidate+Internal.h', 297 'app/webrtc/objc/RTCICECandidate.mm', 298 'app/webrtc/objc/RTCICEServer+Internal.h', 299 'app/webrtc/objc/RTCICEServer.mm', 300 'app/webrtc/objc/RTCLogging.mm', 301 'app/webrtc/objc/RTCMediaConstraints+Internal.h', 302 'app/webrtc/objc/RTCMediaConstraints.mm', 303 'app/webrtc/objc/RTCMediaConstraintsNative.cc', 304 'app/webrtc/objc/RTCMediaConstraintsNative.h', 305 'app/webrtc/objc/RTCMediaSource+Internal.h', 306 'app/webrtc/objc/RTCMediaSource.mm', 307 'app/webrtc/objc/RTCMediaStream+Internal.h', 308 'app/webrtc/objc/RTCMediaStream.mm', 309 'app/webrtc/objc/RTCMediaStreamTrack+Internal.h', 310 'app/webrtc/objc/RTCMediaStreamTrack.mm', 311 'app/webrtc/objc/RTCOpenGLVideoRenderer.mm', 312 'app/webrtc/objc/RTCPair.m', 313 'app/webrtc/objc/RTCPeerConnection+Internal.h', 314 'app/webrtc/objc/RTCPeerConnection.mm', 315 'app/webrtc/objc/RTCPeerConnectionFactory.mm', 316 'app/webrtc/objc/RTCPeerConnectionInterface+Internal.h', 317 'app/webrtc/objc/RTCPeerConnectionInterface.mm', 318 'app/webrtc/objc/RTCPeerConnectionObserver.h', 319 'app/webrtc/objc/RTCPeerConnectionObserver.mm', 320 'app/webrtc/objc/RTCSessionDescription+Internal.h', 321 'app/webrtc/objc/RTCSessionDescription.mm', 322 'app/webrtc/objc/RTCStatsReport+Internal.h', 323 'app/webrtc/objc/RTCStatsReport.mm', 324 'app/webrtc/objc/RTCVideoCapturer+Internal.h', 325 'app/webrtc/objc/RTCVideoCapturer.mm', 326 'app/webrtc/objc/RTCVideoRendererAdapter.h', 327 'app/webrtc/objc/RTCVideoRendererAdapter.mm', 328 'app/webrtc/objc/RTCVideoSource+Internal.h', 329 'app/webrtc/objc/RTCVideoSource.mm', 330 'app/webrtc/objc/RTCVideoTrack+Internal.h', 331 'app/webrtc/objc/RTCVideoTrack.mm', 332 'app/webrtc/objc/public/RTCAudioSource.h', 333 'app/webrtc/objc/public/RTCAudioTrack.h', 334 'app/webrtc/objc/public/RTCDataChannel.h', 335 'app/webrtc/objc/public/RTCFileLogger.h', 336 'app/webrtc/objc/public/RTCI420Frame.h', 337 'app/webrtc/objc/public/RTCICECandidate.h', 338 'app/webrtc/objc/public/RTCICEServer.h', 339 'app/webrtc/objc/public/RTCLogging.h', 340 'app/webrtc/objc/public/RTCMediaConstraints.h', 341 'app/webrtc/objc/public/RTCMediaSource.h', 342 'app/webrtc/objc/public/RTCMediaStream.h', 343 'app/webrtc/objc/public/RTCMediaStreamTrack.h', 344 'app/webrtc/objc/public/RTCOpenGLVideoRenderer.h', 345 'app/webrtc/objc/public/RTCPair.h', 346 'app/webrtc/objc/public/RTCPeerConnection.h', 347 'app/webrtc/objc/public/RTCPeerConnectionDelegate.h', 348 'app/webrtc/objc/public/RTCPeerConnectionFactory.h', 349 'app/webrtc/objc/public/RTCPeerConnectionInterface.h', 350 'app/webrtc/objc/public/RTCSessionDescription.h', 351 'app/webrtc/objc/public/RTCSessionDescriptionDelegate.h', 352 'app/webrtc/objc/public/RTCStatsDelegate.h', 353 'app/webrtc/objc/public/RTCStatsReport.h', 354 'app/webrtc/objc/public/RTCTypes.h', 355 'app/webrtc/objc/public/RTCVideoCapturer.h', 356 'app/webrtc/objc/public/RTCVideoRenderer.h', 357 'app/webrtc/objc/public/RTCVideoSource.h', 358 'app/webrtc/objc/public/RTCVideoTrack.h', 359 ], 360 'direct_dependent_settings': { 361 'include_dirs': [ 362 '<(DEPTH)/talk/app/webrtc/objc/public', 363 ], 364 }, 365 'include_dirs': [ 366 '<(DEPTH)/talk/app/webrtc', 367 '<(DEPTH)/talk/app/webrtc/objc', 368 '<(DEPTH)/talk/app/webrtc/objc/public', 369 ], 370 'link_settings': { 371 'libraries': [ 372 '-lstdc++', 373 ], 374 }, 375 'all_dependent_settings': { 376 'xcode_settings': { 377 'CLANG_ENABLE_OBJC_ARC': 'YES', 378 }, 379 }, 380 'xcode_settings': { 381 'CLANG_ENABLE_OBJC_ARC': 'YES', 382 # common.gypi enables this for mac but we want this to be disabled 383 # like it is for ios. 384 'CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS': 'NO', 385 # Disabled due to failing when compiled with -Wall, see 386 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5397 387 'WARNING_CFLAGS': ['-Wno-unused-property-ivar'], 388 }, 389 'conditions': [ 390 ['OS=="ios"', { 391 'sources': [ 392 'app/webrtc/objc/avfoundationvideocapturer.h', 393 'app/webrtc/objc/avfoundationvideocapturer.mm', 394 'app/webrtc/objc/RTCAVFoundationVideoSource+Internal.h', 395 'app/webrtc/objc/RTCAVFoundationVideoSource.mm', 396 'app/webrtc/objc/RTCEAGLVideoView.m', 397 'app/webrtc/objc/public/RTCEAGLVideoView.h', 398 'app/webrtc/objc/public/RTCAVFoundationVideoSource.h', 399 ], 400 'dependencies': [ 401 '<(webrtc_root)/base/base.gyp:rtc_base_objc', 402 ], 403 'link_settings': { 404 'xcode_settings': { 405 'OTHER_LDFLAGS': [ 406 '-framework CoreGraphics', 407 '-framework GLKit', 408 ], 409 }, 410 }, 411 }], 412 ['OS=="mac"', { 413 'sources': [ 414 'app/webrtc/objc/RTCNSGLVideoView.m', 415 'app/webrtc/objc/public/RTCNSGLVideoView.h', 416 ], 417 'xcode_settings': { 418 # Need to build against 10.7 framework for full ARC support 419 # on OSX. 420 'MACOSX_DEPLOYMENT_TARGET' : '10.7', 421 # RTCVideoTrack.mm uses code with partial availability. 422 # https://code.google.com/p/webrtc/issues/detail?id=4695 423 'WARNING_CFLAGS!': ['-Wpartial-availability'], 424 }, 425 'link_settings': { 426 'xcode_settings': { 427 'OTHER_LDFLAGS': [ 428 '-framework Cocoa', 429 ], 430 }, 431 }, 432 }], 433 ], 434 }, # target libjingle_peerconnection_objc 435 ], 436 }], 437 ], 438 439 'targets': [ 440 { 441 'target_name': 'libjingle', 442 'type': 'none', 443 'dependencies': [ 444 '<(webrtc_root)/base/base.gyp:rtc_base', 445 ], 446 'conditions': [ 447 ['build_json==1', { 448 'dependencies': [ 449 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', 450 ], 451 'export_dependent_settings': [ 452 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', 453 ], 454 }], 455 ['build_expat==1', { 456 'dependencies': [ 457 '<(DEPTH)/third_party/expat/expat.gyp:expat', 458 ], 459 'export_dependent_settings': [ 460 '<(DEPTH)/third_party/expat/expat.gyp:expat', 461 ], 462 }], 463 ], 464 }, # target libjingle 465 { 466 'target_name': 'libjingle_media', 467 'type': 'static_library', 468 'dependencies': [ 469 '<(webrtc_root)/common.gyp:webrtc_common', 470 '<(webrtc_root)/modules/modules.gyp:video_render_module', 471 '<(webrtc_root)/webrtc.gyp:webrtc', 472 '<(webrtc_root)/voice_engine/voice_engine.gyp:voice_engine', 473 '<(webrtc_root)/sound/sound.gyp:rtc_sound', 474 '<(webrtc_root)/system_wrappers/system_wrappers.gyp:metrics_default', 475 '<(webrtc_root)/system_wrappers/system_wrappers.gyp:system_wrappers', 476 '<(webrtc_root)/libjingle/xmllite/xmllite.gyp:rtc_xmllite', 477 '<(webrtc_root)/libjingle/xmpp/xmpp.gyp:rtc_xmpp', 478 '<(webrtc_root)/p2p/p2p.gyp:rtc_p2p', 479 'libjingle', 480 ], 481 'direct_dependent_settings': { 482 'include_dirs': [ 483 '<(libyuv_dir)/include', 484 ], 485 }, 486 'sources': [ 487 'media/base/audioframe.h', 488 'media/base/audiorenderer.h', 489 'media/base/capturemanager.cc', 490 'media/base/capturemanager.h', 491 'media/base/capturerenderadapter.cc', 492 'media/base/capturerenderadapter.h', 493 'media/base/codec.cc', 494 'media/base/codec.h', 495 'media/base/constants.cc', 496 'media/base/constants.h', 497 'media/base/cpuid.cc', 498 'media/base/cpuid.h', 499 'media/base/cryptoparams.h', 500 'media/base/device.h', 501 'media/base/fakescreencapturerfactory.h', 502 'media/base/hybriddataengine.h', 503 'media/base/mediachannel.h', 504 'media/base/mediacommon.h', 505 'media/base/mediaengine.cc', 506 'media/base/mediaengine.h', 507 'media/base/rtpdataengine.cc', 508 'media/base/rtpdataengine.h', 509 'media/base/rtpdump.cc', 510 'media/base/rtpdump.h', 511 'media/base/rtputils.cc', 512 'media/base/rtputils.h', 513 'media/base/screencastid.h', 514 'media/base/streamparams.cc', 515 'media/base/streamparams.h', 516 'media/base/videoadapter.cc', 517 'media/base/videoadapter.h', 518 'media/base/videocapturer.cc', 519 'media/base/videocapturer.h', 520 'media/base/videocapturerfactory.h', 521 'media/base/videocommon.cc', 522 'media/base/videocommon.h', 523 'media/base/videoframe.cc', 524 'media/base/videoframe.h', 525 'media/base/videoframefactory.cc', 526 'media/base/videoframefactory.h', 527 'media/base/videorenderer.h', 528 'media/base/yuvframegenerator.cc', 529 'media/base/yuvframegenerator.h', 530 'media/devices/deviceinfo.h', 531 'media/devices/devicemanager.cc', 532 'media/devices/devicemanager.h', 533 'media/devices/dummydevicemanager.h', 534 'media/devices/filevideocapturer.cc', 535 'media/devices/filevideocapturer.h', 536 'media/devices/videorendererfactory.h', 537 'media/devices/yuvframescapturer.cc', 538 'media/devices/yuvframescapturer.h', 539 'media/sctp/sctpdataengine.cc', 540 'media/sctp/sctpdataengine.h', 541 'media/webrtc/simulcast.cc', 542 'media/webrtc/simulcast.h', 543 'media/webrtc/webrtccommon.h', 544 'media/webrtc/webrtcmediaengine.cc', 545 'media/webrtc/webrtcmediaengine.h', 546 'media/webrtc/webrtcmediaengine.cc', 547 'media/webrtc/webrtcvideocapturer.cc', 548 'media/webrtc/webrtcvideocapturer.h', 549 'media/webrtc/webrtcvideocapturerfactory.h', 550 'media/webrtc/webrtcvideocapturerfactory.cc', 551 'media/webrtc/webrtcvideodecoderfactory.h', 552 'media/webrtc/webrtcvideoencoderfactory.h', 553 'media/webrtc/webrtcvideoengine2.cc', 554 'media/webrtc/webrtcvideoengine2.h', 555 'media/webrtc/webrtcvideoframe.cc', 556 'media/webrtc/webrtcvideoframe.h', 557 'media/webrtc/webrtcvideoframefactory.cc', 558 'media/webrtc/webrtcvideoframefactory.h', 559 'media/webrtc/webrtcvoe.h', 560 'media/webrtc/webrtcvoiceengine.cc', 561 'media/webrtc/webrtcvoiceengine.h', 562 ], 563 'conditions': [ 564 ['build_libyuv==1', { 565 'dependencies': ['<(DEPTH)/third_party/libyuv/libyuv.gyp:libyuv',], 566 }], 567 ['build_usrsctp==1', { 568 'include_dirs': [ 569 # TODO(jiayl): move this into the direct_dependent_settings of 570 # usrsctp.gyp. 571 '<(DEPTH)/third_party/usrsctp/usrsctplib', 572 ], 573 'dependencies': [ 574 '<(DEPTH)/third_party/usrsctp/usrsctp.gyp:usrsctplib', 575 ], 576 }], 577 ['build_with_chromium==1', { 578 'dependencies': [ 579 '<(webrtc_root)/modules/modules.gyp:video_capture', 580 '<(webrtc_root)/modules/modules.gyp:video_render', 581 ], 582 }, { 583 'dependencies': [ 584 '<(webrtc_root)/modules/modules.gyp:video_capture_module_internal_impl', 585 '<(webrtc_root)/modules/modules.gyp:video_render_module_internal_impl', 586 ], 587 }], 588 ['OS=="linux"', { 589 'sources': [ 590 'media/devices/libudevsymboltable.cc', 591 'media/devices/libudevsymboltable.h', 592 'media/devices/linuxdeviceinfo.cc', 593 'media/devices/linuxdevicemanager.cc', 594 'media/devices/linuxdevicemanager.h', 595 'media/devices/v4llookup.cc', 596 'media/devices/v4llookup.h', 597 ], 598 'conditions': [ 599 ['use_gtk==1', { 600 'sources': [ 601 'media/devices/gtkvideorenderer.cc', 602 'media/devices/gtkvideorenderer.h', 603 ], 604 'cflags': [ 605 '<!@(pkg-config --cflags gobject-2.0 gthread-2.0 gtk+-2.0)', 606 ], 607 }], 608 ], 609 'include_dirs': [ 610 'third_party/libudev' 611 ], 612 'libraries': [ 613 '-lrt', 614 ], 615 }], 616 ['OS=="win"', { 617 'sources': [ 618 'media/devices/gdivideorenderer.cc', 619 'media/devices/gdivideorenderer.h', 620 'media/devices/win32deviceinfo.cc', 621 'media/devices/win32devicemanager.cc', 622 'media/devices/win32devicemanager.h', 623 ], 624 'msvs_settings': { 625 'VCLibrarianTool': { 626 'AdditionalDependencies': [ 627 'd3d9.lib', 628 'gdi32.lib', 629 'strmiids.lib', 630 'winmm.lib', 631 ], 632 }, 633 }, 634 }], 635 ['OS=="mac"', { 636 'sources': [ 637 'media/devices/macdeviceinfo.cc', 638 'media/devices/macdevicemanager.cc', 639 'media/devices/macdevicemanager.h', 640 'media/devices/macdevicemanagermm.mm', 641 ], 642 'conditions': [ 643 ['target_arch=="ia32"', { 644 'sources': [ 645 'media/devices/carbonvideorenderer.cc', 646 'media/devices/carbonvideorenderer.h', 647 ], 648 'link_settings': { 649 'xcode_settings': { 650 'OTHER_LDFLAGS': [ 651 '-framework Carbon', 652 ], 653 }, 654 }, 655 }], 656 ], 657 'xcode_settings': { 658 'WARNING_CFLAGS': [ 659 # TODO(ronghuawu): Update macdevicemanager.cc to stop using 660 # deprecated functions and remove this flag. 661 '-Wno-deprecated-declarations', 662 ], 663 # Disable partial availability warning to prevent errors 664 # in macdevicemanagermm.mm using AVFoundation. 665 # https://code.google.com/p/webrtc/issues/detail?id=4695 666 'WARNING_CFLAGS!': ['-Wpartial-availability'], 667 }, 668 'link_settings': { 669 'xcode_settings': { 670 'OTHER_LDFLAGS': [ 671 '-weak_framework AVFoundation', 672 '-framework Cocoa', 673 '-framework CoreAudio', 674 '-framework CoreVideo', 675 '-framework OpenGL', 676 '-framework QTKit', 677 ], 678 }, 679 }, 680 }], 681 ['OS=="ios"', { 682 'sources': [ 683 'media/devices/mobiledevicemanager.cc', 684 ], 685 'include_dirs': [ 686 # TODO(sjlee) Remove when vp8 is building for iOS. vp8 pulls in 687 # libjpeg which pulls in libyuv which currently disabled. 688 '../third_party/libyuv/include', 689 ], 690 }], 691 ['OS=="android"', { 692 'sources': [ 693 'media/devices/mobiledevicemanager.cc', 694 ], 695 }], 696 ], 697 }, # target libjingle_media 698 { 699 'target_name': 'libjingle_p2p', 700 'type': 'static_library', 701 'dependencies': [ 702 'libjingle', 703 'libjingle_media', 704 ], 705 'conditions': [ 706 ['build_libsrtp==1', { 707 'dependencies': [ 708 '<(DEPTH)/third_party/libsrtp/libsrtp.gyp:libsrtp', 709 ], 710 }], 711 ], 712 'include_dirs': [ 713 '<(DEPTH)/testing/gtest/include', 714 ], 715 'include_dirs!': [ 716 '<(DEPTH)/webrtc', 717 ], 718 'direct_dependent_settings': { 719 'include_dirs': [ 720 '<(DEPTH)/testing/gtest/include', 721 ], 722 'include_dirs!': [ 723 '<(DEPTH)/webrtc', 724 ], 725 }, 726 'sources': [ 727 'session/media/audiomonitor.cc', 728 'session/media/audiomonitor.h', 729 'session/media/bundlefilter.cc', 730 'session/media/bundlefilter.h', 731 'session/media/channel.cc', 732 'session/media/channel.h', 733 'session/media/channelmanager.cc', 734 'session/media/channelmanager.h', 735 'session/media/currentspeakermonitor.cc', 736 'session/media/currentspeakermonitor.h', 737 'session/media/mediamonitor.cc', 738 'session/media/mediamonitor.h', 739 'session/media/mediasession.cc', 740 'session/media/mediasession.h', 741 'session/media/mediasink.h', 742 'session/media/rtcpmuxfilter.cc', 743 'session/media/rtcpmuxfilter.h', 744 'session/media/srtpfilter.cc', 745 'session/media/srtpfilter.h', 746 'session/media/voicechannel.h', 747 ], 748 }, # target libjingle_p2p 749 { 750 'target_name': 'libjingle_peerconnection', 751 'type': 'static_library', 752 'dependencies': [ 753 'libjingle', 754 'libjingle_media', 755 'libjingle_p2p', 756 ], 757 'sources': [ 758 'app/webrtc/audiotrack.cc', 759 'app/webrtc/audiotrack.h', 760 'app/webrtc/datachannel.cc', 761 'app/webrtc/datachannel.h', 762 'app/webrtc/datachannelinterface.h', 763 'app/webrtc/dtlsidentitystore.cc', 764 'app/webrtc/dtlsidentitystore.h', 765 'app/webrtc/dtmfsender.cc', 766 'app/webrtc/dtmfsender.h', 767 'app/webrtc/dtmfsenderinterface.h', 768 'app/webrtc/jsep.h', 769 'app/webrtc/jsepicecandidate.cc', 770 'app/webrtc/jsepicecandidate.h', 771 'app/webrtc/jsepsessiondescription.cc', 772 'app/webrtc/jsepsessiondescription.h', 773 'app/webrtc/localaudiosource.cc', 774 'app/webrtc/localaudiosource.h', 775 'app/webrtc/mediaconstraintsinterface.cc', 776 'app/webrtc/mediaconstraintsinterface.h', 777 'app/webrtc/mediacontroller.cc', 778 'app/webrtc/mediacontroller.h', 779 'app/webrtc/mediastream.cc', 780 'app/webrtc/mediastream.h', 781 'app/webrtc/mediastreaminterface.h', 782 'app/webrtc/mediastreamobserver.cc', 783 'app/webrtc/mediastreamobserver.h', 784 'app/webrtc/mediastreamprovider.h', 785 'app/webrtc/mediastreamproxy.h', 786 'app/webrtc/mediastreamtrack.h', 787 'app/webrtc/mediastreamtrackproxy.h', 788 'app/webrtc/notifier.h', 789 'app/webrtc/peerconnection.cc', 790 'app/webrtc/peerconnection.h', 791 'app/webrtc/peerconnectionfactory.cc', 792 'app/webrtc/peerconnectionfactory.h', 793 'app/webrtc/peerconnectionfactoryproxy.h', 794 'app/webrtc/peerconnectioninterface.h', 795 'app/webrtc/peerconnectionproxy.h', 796 'app/webrtc/proxy.h', 797 'app/webrtc/remoteaudiosource.cc', 798 'app/webrtc/remoteaudiosource.h', 799 'app/webrtc/remotevideocapturer.cc', 800 'app/webrtc/remotevideocapturer.h', 801 'app/webrtc/rtpreceiver.cc', 802 'app/webrtc/rtpreceiver.h', 803 'app/webrtc/rtpreceiverinterface.h', 804 'app/webrtc/rtpsender.cc', 805 'app/webrtc/rtpsender.h', 806 'app/webrtc/rtpsenderinterface.h', 807 'app/webrtc/sctputils.cc', 808 'app/webrtc/sctputils.h', 809 'app/webrtc/statscollector.cc', 810 'app/webrtc/statscollector.h', 811 'app/webrtc/statstypes.cc', 812 'app/webrtc/statstypes.h', 813 'app/webrtc/streamcollection.h', 814 'app/webrtc/videosource.cc', 815 'app/webrtc/videosource.h', 816 'app/webrtc/videosourceinterface.h', 817 'app/webrtc/videosourceproxy.h', 818 'app/webrtc/videotrack.cc', 819 'app/webrtc/videotrack.h', 820 'app/webrtc/videotrackrenderers.cc', 821 'app/webrtc/videotrackrenderers.h', 822 'app/webrtc/webrtcsdp.cc', 823 'app/webrtc/webrtcsdp.h', 824 'app/webrtc/webrtcsession.cc', 825 'app/webrtc/webrtcsession.h', 826 'app/webrtc/webrtcsessiondescriptionfactory.cc', 827 'app/webrtc/webrtcsessiondescriptionfactory.h', 828 ], 829 }, # target libjingle_peerconnection 830 ], 831 } 832