Roll DEPS for libelf clang compilation fix.
[chromium-blink-merge.git] / third_party / libjingle / libjingle.gyp
blob15383056ac308dffad3aae9b5ca361c2d9b285f9
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6   'includes': [
7     '../../build/win_precompile.gypi',
8   ],
9   'variables': {
10     'enabled_libjingle_device_manager%': 0,
11     'libjingle_additional_deps%': [],
12     'libjingle_peerconnection_additional_deps%': [],
13     'libjingle_source%': "source",
14     'libpeer_target_type%': 'static_library',
15     'libpeer_allocator_shim%': 0,
16   },
17   'target_defaults': {
18     'defines': [
19       'EXPAT_RELATIVE_PATH',
20       'FEATURE_ENABLE_SSL',
21       'GTEST_RELATIVE_PATH',
22       'HAVE_SRTP',
23       'HAVE_WEBRTC_VIDEO',
24       'HAVE_WEBRTC_VOICE',
25       'LOGGING_INSIDE_LIBJINGLE',
26       'NO_MAIN_THREAD_WRAPPING',
27       'NO_SOUND_SYSTEM',
28       'SRTP_RELATIVE_PATH',
29       'USE_WEBRTC_DEV_BRANCH',
30       'ENABLE_EXTERNAL_AUTH',
31     ],
32     'configurations': {
33       'Debug': {
34         'defines': [
35           # TODO(sergeyu): Fix libjingle to use NDEBUG instead of
36           # _DEBUG and remove this define. See below as well.
37           '_DEBUG',
38         ],
39       }
40     },
41     'include_dirs': [
42       './overrides',
43       './<(libjingle_source)',
44       '../../third_party/webrtc/overrides',
45       '../..',
46       '../../testing/gtest/include',
47       '../../third_party',
48       '../../third_party/libyuv/include',
49       '../../third_party/usrsctp',
50       '../../third_party/webrtc',
51     ],
52     'dependencies': [
53       '<(DEPTH)/base/base.gyp:base',
54       '<(DEPTH)/net/net.gyp:net',
55       '<(DEPTH)/third_party/expat/expat.gyp:expat',
56     ],
57     'export_dependent_settings': [
58       '<(DEPTH)/third_party/expat/expat.gyp:expat',
59     ],
60     'direct_dependent_settings': {
61       'include_dirs': [
62         './overrides',
63         './<(libjingle_source)',
64         '../../third_party/webrtc/overrides',
65         '../..',
66         '../../testing/gtest/include',
67         '../../third_party',
68         '../../third_party/webrtc',
69       ],
70       'defines': [
71         'FEATURE_ENABLE_SSL',
72         'FEATURE_ENABLE_VOICEMAIL',
73         'EXPAT_RELATIVE_PATH',
74         'GTEST_RELATIVE_PATH',
75         'NO_MAIN_THREAD_WRAPPING',
76         'NO_SOUND_SYSTEM',
77       ],
78       'conditions': [
79         ['OS=="win"', {
80           'link_settings': {
81             'libraries': [
82               '-lsecur32.lib',
83               '-lcrypt32.lib',
84               '-liphlpapi.lib',
85             ],
86           },
87         }],
88         ['OS=="win"', {
89           'include_dirs': [
90             '../third_party/platformsdk_win7/files/Include',
91           ],
92           'defines': [
93             '_CRT_SECURE_NO_WARNINGS',  # Suppres warnings about _vsnprinf
94           ],
95           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
96           'msvs_disabled_warnings': [ 4267 ],
97         }],
98         ['OS=="linux"', {
99           'defines': [
100             'LINUX',
101           ],
102         }],
103         ['OS=="mac"', {
104           'defines': [
105             'OSX',
106           ],
107         }],
108         ['OS=="android"', {
109           'defines': [
110             'ANDROID',
111           ],
112         }],
113         ['os_posix==1', {
114           'defines': [
115             'POSIX',
116           ],
117         }],
118         ['os_bsd==1', {
119           'defines': [
120             'BSD',
121           ],
122         }],
123         ['OS=="openbsd"', {
124           'defines': [
125             'OPENBSD',
126           ],
127         }],
128         ['OS=="freebsd"', {
129           'defines': [
130             'FREEBSD',
131           ],
132         }],
133         ['chromeos==1', {
134           'defines': [
135             'CHROMEOS',
136           ],
137         }],
138       ],
139     },
140     'all_dependent_settings': {
141       'configurations': {
142         'Debug': {
143           'defines': [
144             # TODO(sergeyu): Fix libjingle to use NDEBUG instead of
145             # _DEBUG and remove this define. See above as well.
146             '_DEBUG',
147           ],
148         }
149       },
150     },
151     'conditions': [
152       ['"<(libpeer_target_type)"=="static_library"', {
153         'defines': [ 'LIBPEERCONNECTION_LIB=1' ],
154       }],
155       ['use_openssl==1', {
156         'defines': [
157           'SSL_USE_OPENSSL',
158           'HAVE_OPENSSL_SSL_H',
159         ],
160         'dependencies': [
161           '../../third_party/openssl/openssl.gyp:openssl',
162         ],
163       }, {
164         'defines': [
165           'SSL_USE_NSS',
166           'HAVE_NSS_SSL_H',
167           'SSL_USE_NSS_RNG',
168         ],
169         'conditions': [
170           ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', {
171             'dependencies': [
172               '<(DEPTH)/build/linux/system.gyp:ssl',
173             ],
174           }],
175           ['OS == "mac" or OS == "ios" or OS == "win"', {
176             'dependencies': [
177               '<(DEPTH)/net/third_party/nss/ssl.gyp:libssl',
178               '<(DEPTH)/third_party/nss/nss.gyp:nspr',
179               '<(DEPTH)/third_party/nss/nss.gyp:nss',
180             ],
181           }],
182         ],
183       }],
184       ['OS=="win"', {
185         'include_dirs': [
186           '../third_party/platformsdk_win7/files/Include',
187         ],
188         'conditions' : [
189           ['target_arch == "ia32"', {
190             'defines': [
191               '_USE_32BIT_TIME_T',
192             ],
193           }],
194         ],
195       }],
196       ['clang == 1', {
197         'xcode_settings': {
198           'WARNING_CFLAGS!': [
199             # Don't warn about string->bool used in asserts.
200             '-Wstring-conversion',
201           ],
202         },
203         'cflags!': [
204           '-Wstring-conversion',
205         ],
206       }],
207       ['OS=="linux"', {
208         'defines': [
209           'LINUX',
210         ],
211       }],
212       ['OS=="mac"', {
213         'defines': [
214           'OSX',
215         ],
216       }],
217       ['OS=="ios"', {
218         'defines': [
219           'IOS',
220         ],
221       }],
222       ['os_posix == 1', {
223         'defines': [
224           'POSIX',
225         ],
226       }],
227       ['os_bsd==1', {
228         'defines': [
229           'BSD',
230         ],
231       }],
232       ['OS=="openbsd"', {
233         'defines': [
234           'OPENBSD',
235         ],
236       }],
237       ['OS=="freebsd"', {
238         'defines': [
239           'FREEBSD',
240         ],
241       }],
242     ],
243   },
244   'targets': [
245     {
246       'target_name': 'libjingle',
247       'type': 'static_library',
248       'includes': [ 'libjingle_common.gypi' ],
249       'sources': [
250         'overrides/talk/base/basictypes.h',
251         'overrides/talk/base/constructormagic.h',
252         'overrides/talk/base/win32socketinit.cc',
254         # Overrides logging.h/.cc because libjingle logging should be done to
255         # the same place as the chromium logging.
256         'overrides/talk/base/logging.cc',
257         'overrides/talk/base/logging.h',
258       ],
259       'sources!' : [
260         # Compiled as part of libjingle_p2p_constants.
261         '<(libjingle_source)/talk/p2p/base/constants.cc',
262         '<(libjingle_source)/talk/p2p/base/constants.h',
264         # Replaced with logging.cc in the overrides.
265         '<(libjingle_source)/talk/base/logging.h',
266         '<(libjingle_source)/talk/base/logging.cc',
267       ],
268       'dependencies': [
269         'libjingle_p2p_constants',
270         '<@(libjingle_additional_deps)',
271       ],
272     },  # target libjingle
273     # This has to be is a separate project due to a bug in MSVS 2008 and the
274     # current toolset on android.  The problem is that we have two files named
275     # "constants.cc" and MSVS/android doesn't handle this properly.
276     # GYP currently has guards to catch this, so if you want to remove it,
277     # run GYP and if GYP has removed the validation check, then we can assume
278     # that the toolchains have been fixed (we currently use VS2010 and later,
279     # so VS2008 isn't a concern anymore).
280     {
281       'target_name': 'libjingle_p2p_constants',
282       'type': 'static_library',
283       'sources': [
284         '<(libjingle_source)/talk/p2p/base/constants.cc',
285         '<(libjingle_source)/talk/p2p/base/constants.h',
286       ],
287     },  # target libjingle_p2p_constants
288     {
289       'target_name': 'peerconnection_server',
290       'type': 'executable',
291       'sources': [
292         '<(libjingle_source)/talk/examples/peerconnection/server/data_socket.cc',
293         '<(libjingle_source)/talk/examples/peerconnection/server/data_socket.h',
294         '<(libjingle_source)/talk/examples/peerconnection/server/main.cc',
295         '<(libjingle_source)/talk/examples/peerconnection/server/peer_channel.cc',
296         '<(libjingle_source)/talk/examples/peerconnection/server/peer_channel.h',
297         '<(libjingle_source)/talk/examples/peerconnection/server/utils.cc',
298         '<(libjingle_source)/talk/examples/peerconnection/server/utils.h',
299       ],
300       'include_dirs': [
301         '<(libjingle_source)',
302       ],
303       'dependencies': [
304         'libjingle',
305       ],
306       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
307       'msvs_disabled_warnings': [ 4309, ],
308     }, # target peerconnection_server
309   ],
310   'conditions': [
311     ['enable_webrtc==1', {
312       'targets': [
313         {
314           'target_name': 'libjingle_webrtc_common',
315           'type': 'static_library',
316           'all_dependent_settings': {
317             'conditions': [
318               ['"<(libpeer_target_type)"=="static_library"', {
319                 'defines': [ 'LIBPEERCONNECTION_LIB=1' ],
320               }],
321             ],
322           },
323           'sources': [
324             'overrides/talk/media/webrtc/webrtcexport.h',
326             '<(libjingle_source)/talk/app/webrtc/audiotrack.cc',
327             '<(libjingle_source)/talk/app/webrtc/audiotrack.h',
328             '<(libjingle_source)/talk/app/webrtc/audiotrackrenderer.cc',
329             '<(libjingle_source)/talk/app/webrtc/audiotrackrenderer.h',
330             '<(libjingle_source)/talk/app/webrtc/datachannel.cc',
331             '<(libjingle_source)/talk/app/webrtc/datachannel.h',
332             '<(libjingle_source)/talk/app/webrtc/dtmfsender.cc',
333             '<(libjingle_source)/talk/app/webrtc/dtmfsender.h',
334             '<(libjingle_source)/talk/app/webrtc/jsep.h',
335             '<(libjingle_source)/talk/app/webrtc/jsepicecandidate.cc',
336             '<(libjingle_source)/talk/app/webrtc/jsepicecandidate.h',
337             '<(libjingle_source)/talk/app/webrtc/jsepsessiondescription.cc',
338             '<(libjingle_source)/talk/app/webrtc/jsepsessiondescription.h',
339             '<(libjingle_source)/talk/app/webrtc/localaudiosource.cc',
340             '<(libjingle_source)/talk/app/webrtc/localaudiosource.h',
341             '<(libjingle_source)/talk/app/webrtc/mediaconstraintsinterface.cc',
342             '<(libjingle_source)/talk/app/webrtc/mediaconstraintsinterface.h',
343             '<(libjingle_source)/talk/app/webrtc/mediastream.cc',
344             '<(libjingle_source)/talk/app/webrtc/mediastream.h',
345             '<(libjingle_source)/talk/app/webrtc/mediastreamhandler.cc',
346             '<(libjingle_source)/talk/app/webrtc/mediastreamhandler.h',
347             '<(libjingle_source)/talk/app/webrtc/mediastreaminterface.h',
348             '<(libjingle_source)/talk/app/webrtc/mediastreamprovider.h',
349             '<(libjingle_source)/talk/app/webrtc/mediastreamproxy.h',
350             '<(libjingle_source)/talk/app/webrtc/mediastreamsignaling.cc',
351             '<(libjingle_source)/talk/app/webrtc/mediastreamsignaling.h',
352             '<(libjingle_source)/talk/app/webrtc/mediastreamtrack.h',
353             '<(libjingle_source)/talk/app/webrtc/mediastreamtrackproxy.h',
354             '<(libjingle_source)/talk/app/webrtc/notifier.h',
355             '<(libjingle_source)/talk/app/webrtc/peerconnection.cc',
356             '<(libjingle_source)/talk/app/webrtc/peerconnection.h',
357             '<(libjingle_source)/talk/app/webrtc/peerconnectionfactory.cc',
358             '<(libjingle_source)/talk/app/webrtc/peerconnectionfactory.h',
359             '<(libjingle_source)/talk/app/webrtc/peerconnectioninterface.h',
360             '<(libjingle_source)/talk/app/webrtc/portallocatorfactory.cc',
361             '<(libjingle_source)/talk/app/webrtc/portallocatorfactory.h',
362             '<(libjingle_source)/talk/app/webrtc/remoteaudiosource.cc',
363             '<(libjingle_source)/talk/app/webrtc/remoteaudiosource.h',
364             '<(libjingle_source)/talk/app/webrtc/remotevideocapturer.cc',
365             '<(libjingle_source)/talk/app/webrtc/remotevideocapturer.h',
366             '<(libjingle_source)/talk/app/webrtc/sctputils.cc',
367             '<(libjingle_source)/talk/app/webrtc/sctputils.h',
368             '<(libjingle_source)/talk/app/webrtc/statscollector.cc',
369             '<(libjingle_source)/talk/app/webrtc/statscollector.h',
370             '<(libjingle_source)/talk/app/webrtc/statstypes.h',
371             '<(libjingle_source)/talk/app/webrtc/streamcollection.h',
372             '<(libjingle_source)/talk/app/webrtc/umametrics.h',
373             '<(libjingle_source)/talk/app/webrtc/videosource.cc',
374             '<(libjingle_source)/talk/app/webrtc/videosource.h',
375             '<(libjingle_source)/talk/app/webrtc/videosourceinterface.h',
376             '<(libjingle_source)/talk/app/webrtc/videosourceproxy.h',
377             '<(libjingle_source)/talk/app/webrtc/videotrack.cc',
378             '<(libjingle_source)/talk/app/webrtc/videotrack.h',
379             '<(libjingle_source)/talk/app/webrtc/videotrackrenderers.cc',
380             '<(libjingle_source)/talk/app/webrtc/videotrackrenderers.h',
381             '<(libjingle_source)/talk/app/webrtc/webrtcsdp.cc',
382             '<(libjingle_source)/talk/app/webrtc/webrtcsdp.h',
383             '<(libjingle_source)/talk/app/webrtc/webrtcsession.cc',
384             '<(libjingle_source)/talk/app/webrtc/webrtcsession.h',
385             '<(libjingle_source)/talk/app/webrtc/webrtcsessiondescriptionfactory.cc',
386             '<(libjingle_source)/talk/app/webrtc/webrtcsessiondescriptionfactory.h',
387             '<(libjingle_source)/talk/media/base/audiorenderer.h',
388             '<(libjingle_source)/talk/media/base/capturemanager.cc',
389             '<(libjingle_source)/talk/media/base/capturemanager.h',
390             '<(libjingle_source)/talk/media/base/capturerenderadapter.cc',
391             '<(libjingle_source)/talk/media/base/capturerenderadapter.h',
392             '<(libjingle_source)/talk/media/base/codec.cc',
393             '<(libjingle_source)/talk/media/base/codec.h',
394             '<(libjingle_source)/talk/media/base/constants.cc',
395             '<(libjingle_source)/talk/media/base/constants.h',
396             '<(libjingle_source)/talk/media/base/cryptoparams.h',
397             '<(libjingle_source)/talk/media/base/filemediaengine.cc',
398             '<(libjingle_source)/talk/media/base/filemediaengine.h',
399             '<(libjingle_source)/talk/media/base/hybriddataengine.h',
400             '<(libjingle_source)/talk/media/base/mediachannel.h',
401             '<(libjingle_source)/talk/media/base/mediaengine.cc',
402             '<(libjingle_source)/talk/media/base/mediaengine.h',
403             '<(libjingle_source)/talk/media/base/rtpdataengine.cc',
404             '<(libjingle_source)/talk/media/base/rtpdataengine.h',
405             '<(libjingle_source)/talk/media/base/rtpdump.cc',
406             '<(libjingle_source)/talk/media/base/rtpdump.h',
407             '<(libjingle_source)/talk/media/base/rtputils.cc',
408             '<(libjingle_source)/talk/media/base/rtputils.h',
409             '<(libjingle_source)/talk/media/base/streamparams.cc',
410             '<(libjingle_source)/talk/media/base/streamparams.h',
411             '<(libjingle_source)/talk/media/base/videoadapter.cc',
412             '<(libjingle_source)/talk/media/base/videoadapter.h',
413             '<(libjingle_source)/talk/media/base/videocapturer.cc',
414             '<(libjingle_source)/talk/media/base/videocapturer.h',
415             '<(libjingle_source)/talk/media/base/videocommon.cc',
416             '<(libjingle_source)/talk/media/base/videocommon.h',
417             '<(libjingle_source)/talk/media/base/videoframe.cc',
418             '<(libjingle_source)/talk/media/base/videoframe.h',
419             '<(libjingle_source)/talk/media/devices/dummydevicemanager.cc',
420             '<(libjingle_source)/talk/media/devices/dummydevicemanager.h',
421             '<(libjingle_source)/talk/media/devices/filevideocapturer.cc',
422             '<(libjingle_source)/talk/media/devices/filevideocapturer.h',
423             '<(libjingle_source)/talk/media/webrtc/webrtccommon.h',
424             '<(libjingle_source)/talk/media/webrtc/webrtcpassthroughrender.cc',
425             '<(libjingle_source)/talk/media/webrtc/webrtcpassthroughrender.h',
426             '<(libjingle_source)/talk/media/webrtc/webrtctexturevideoframe.cc',
427             '<(libjingle_source)/talk/media/webrtc/webrtctexturevideoframe.h',
428             '<(libjingle_source)/talk/media/webrtc/webrtcvideocapturer.cc',
429             '<(libjingle_source)/talk/media/webrtc/webrtcvideocapturer.h',
430             '<(libjingle_source)/talk/media/webrtc/webrtcvideoframe.cc',
431             '<(libjingle_source)/talk/media/webrtc/webrtcvideoframe.h',
432             '<(libjingle_source)/talk/media/webrtc/webrtcvie.h',
433             '<(libjingle_source)/talk/media/webrtc/webrtcvoe.h',
434             '<(libjingle_source)/talk/session/media/audiomonitor.cc',
435             '<(libjingle_source)/talk/session/media/audiomonitor.h',
436             '<(libjingle_source)/talk/session/media/bundlefilter.cc',
437             '<(libjingle_source)/talk/session/media/bundlefilter.h',
438             '<(libjingle_source)/talk/session/media/call.cc',
439             '<(libjingle_source)/talk/session/media/call.h',
440             '<(libjingle_source)/talk/session/media/channel.cc',
441             '<(libjingle_source)/talk/session/media/channel.h',
442             '<(libjingle_source)/talk/session/media/channelmanager.cc',
443             '<(libjingle_source)/talk/session/media/channelmanager.h',
444             '<(libjingle_source)/talk/session/media/currentspeakermonitor.cc',
445             '<(libjingle_source)/talk/session/media/currentspeakermonitor.h',
446             '<(libjingle_source)/talk/session/media/externalhmac.cc',
447             '<(libjingle_source)/talk/session/media/externalhmac.h',
448             '<(libjingle_source)/talk/session/media/mediamessages.cc',
449             '<(libjingle_source)/talk/session/media/mediamessages.h',
450             '<(libjingle_source)/talk/session/media/mediamonitor.cc',
451             '<(libjingle_source)/talk/session/media/mediamonitor.h',
452             '<(libjingle_source)/talk/session/media/mediasession.cc',
453             '<(libjingle_source)/talk/session/media/mediasession.h',
454             '<(libjingle_source)/talk/session/media/mediasessionclient.cc',
455             '<(libjingle_source)/talk/session/media/mediasessionclient.h',
456             '<(libjingle_source)/talk/session/media/mediasink.h',
457             '<(libjingle_source)/talk/session/media/rtcpmuxfilter.cc',
458             '<(libjingle_source)/talk/session/media/rtcpmuxfilter.h',
459             '<(libjingle_source)/talk/session/media/soundclip.cc',
460             '<(libjingle_source)/talk/session/media/soundclip.h',
461             '<(libjingle_source)/talk/session/media/srtpfilter.cc',
462             '<(libjingle_source)/talk/session/media/srtpfilter.h',
463             '<(libjingle_source)/talk/session/media/typingmonitor.cc',
464             '<(libjingle_source)/talk/session/media/typingmonitor.h',
465             '<(libjingle_source)/talk/session/media/voicechannel.h',
466             '<(libjingle_source)/talk/session/tunnel/pseudotcpchannel.cc',
467             '<(libjingle_source)/talk/session/tunnel/pseudotcpchannel.h',
468             '<(libjingle_source)/talk/session/tunnel/tunnelsessionclient.cc',
469             '<(libjingle_source)/talk/session/tunnel/tunnelsessionclient.h',
470           ],
471           'conditions': [
472             ['libpeer_allocator_shim==1 and '
473              'libpeer_target_type!="static_library" and OS!="mac"', {
474               'sources': [
475                 'overrides/allocator_shim/allocator_stub.cc',
476                 'overrides/allocator_shim/allocator_stub.h',
477               ],
478             }],
479             # TODO(mallinath) - Enable SCTP for iOS.
480             ['OS!="ios"', {
481               'defines': [
482                 'HAVE_SCTP',
483               ],
484               'sources': [
485                 '<(libjingle_source)/talk/media/sctp/sctpdataengine.cc',
486                 '<(libjingle_source)/talk/media/sctp/sctpdataengine.h',
487               ],
488               'dependencies': [
489                 '<(DEPTH)/third_party/usrsctp/usrsctp.gyp:usrsctplib',
490               ],
491             }],
492             ['enabled_libjingle_device_manager==1', {
493               'sources!': [
494                 '<(libjingle_source)/talk/media/devices/dummydevicemanager.cc',
495                 '<(libjingle_source)/talk/media/devices/dummydevicemanager.h',
496               ],
497               'sources': [
498                 '<(libjingle_source)/talk/media/devices/devicemanager.cc',
499                 '<(libjingle_source)/talk/media/devices/devicemanager.h',
500                 '<(libjingle_source)/talk/sound/nullsoundsystem.cc',
501                 '<(libjingle_source)/talk/sound/nullsoundsystem.h',
502                 '<(libjingle_source)/talk/sound/nullsoundsystemfactory.cc',
503                 '<(libjingle_source)/talk/sound/nullsoundsystemfactory.h',
504                 '<(libjingle_source)/talk/sound/platformsoundsystem.cc',
505                 '<(libjingle_source)/talk/sound/platformsoundsystem.h',
506                 '<(libjingle_source)/talk/sound/platformsoundsystemfactory.cc',
507                 '<(libjingle_source)/talk/sound/platformsoundsystemfactory.h',
508                 '<(libjingle_source)/talk/sound/soundsysteminterface.cc',
509                 '<(libjingle_source)/talk/sound/soundsysteminterface.h',
510                 '<(libjingle_source)/talk/sound/soundsystemproxy.cc',
511                 '<(libjingle_source)/talk/sound/soundsystemproxy.h',
512               ],
513               'conditions': [
514                 ['OS=="win"', {
515                   'sources': [
516                     '<(libjingle_source)/talk/base/win32window.cc',
517                     '<(libjingle_source)/talk/base/win32window.h',
518                     '<(libjingle_source)/talk/base/win32windowpicker.cc',
519                     '<(libjingle_source)/talk/base/win32windowpicker.h',
520                     '<(libjingle_source)/talk/media/devices/win32deviceinfo.cc',
521                     '<(libjingle_source)/talk/media/devices/win32devicemanager.cc',
522                     '<(libjingle_source)/talk/media/devices/win32devicemanager.h',
523                   ],
524                 }],
525                 ['OS=="linux"', {
526                   'sources': [
527                     '<(libjingle_source)/talk/base/linuxwindowpicker.cc',
528                     '<(libjingle_source)/talk/base/linuxwindowpicker.h',
529                     '<(libjingle_source)/talk/media/devices/libudevsymboltable.cc',
530                     '<(libjingle_source)/talk/media/devices/libudevsymboltable.h',
531                     '<(libjingle_source)/talk/media/devices/linuxdeviceinfo.cc',
532                     '<(libjingle_source)/talk/media/devices/linuxdevicemanager.cc',
533                     '<(libjingle_source)/talk/media/devices/linuxdevicemanager.h',
534                     '<(libjingle_source)/talk/media/devices/v4llookup.cc',
535                     '<(libjingle_source)/talk/media/devices/v4llookup.h',
536                     '<(libjingle_source)/talk/sound/alsasoundsystem.cc',
537                     '<(libjingle_source)/talk/sound/alsasoundsystem.h',
538                     '<(libjingle_source)/talk/sound/alsasymboltable.cc',
539                     '<(libjingle_source)/talk/sound/alsasymboltable.h',
540                     '<(libjingle_source)/talk/sound/linuxsoundsystem.cc',
541                     '<(libjingle_source)/talk/sound/linuxsoundsystem.h',
542                     '<(libjingle_source)/talk/sound/pulseaudiosoundsystem.cc',
543                     '<(libjingle_source)/talk/sound/pulseaudiosoundsystem.h',
544                     '<(libjingle_source)/talk/sound/pulseaudiosymboltable.cc',
545                     '<(libjingle_source)/talk/sound/pulseaudiosymboltable.h',
546                   ],
547                 }],
548                 ['OS=="mac"', {
549                   'sources': [
550                     '<(libjingle_source)/talk/media/devices/macdeviceinfo.cc',
551                     '<(libjingle_source)/talk/media/devices/macdevicemanager.cc',
552                     '<(libjingle_source)/talk/media/devices/macdevicemanager.h',
553                     '<(libjingle_source)/talk/media/devices/macdevicemanagermm.mm',
554                   ],
555                   'xcode_settings': {
556                     'WARNING_CFLAGS': [
557                       # Suppres warnings about using deprecated functions in
558                       # macdevicemanager.cc.
559                       '-Wno-deprecated-declarations',
560                     ],
561                   },
562                 }],
563               ],
564             }],
565           ],
566           'dependencies': [
567             '<(DEPTH)/third_party/libsrtp/libsrtp.gyp:libsrtp',
568             '<(DEPTH)/third_party/webrtc/modules/modules.gyp:media_file',
569             '<(DEPTH)/third_party/webrtc/modules/modules.gyp:video_capture_module',
570             '<(DEPTH)/third_party/webrtc/modules/modules.gyp:video_render_module',
571             'libjingle',
572           ],
573         },  # target libjingle_webrtc_common
574         {
575           'target_name': 'libjingle_webrtc',
576           'type': 'static_library',
577           'sources': [
578             'overrides/init_webrtc.cc',
579             'overrides/init_webrtc.h',
580           ],
581           'dependencies': [
582             'libjingle_webrtc_common',
583           ],
584         },
585         {
586           'target_name': 'libpeerconnection',
587           'type': '<(libpeer_target_type)',
588           'sources': [
589             '<(libjingle_source)/talk/media/webrtc/webrtcmediaengine.cc',
590             '<(libjingle_source)/talk/media/webrtc/webrtcmediaengine.h',
591             '<(libjingle_source)/talk/media/webrtc/webrtcvideoengine.cc',
592             '<(libjingle_source)/talk/media/webrtc/webrtcvideoengine.h',
593             '<(libjingle_source)/talk/media/webrtc/webrtcvideoengine2.cc',
594             '<(libjingle_source)/talk/media/webrtc/webrtcvideoengine2.h',
595             '<(libjingle_source)/talk/media/webrtc/webrtcvoiceengine.cc',
596             '<(libjingle_source)/talk/media/webrtc/webrtcvoiceengine.h',
597           ],
598           'dependencies': [
599             '<(DEPTH)/third_party/webrtc/system_wrappers/source/system_wrappers.gyp:system_wrappers',
600             '<(DEPTH)/third_party/webrtc/voice_engine/voice_engine.gyp:voice_engine',
601             '<(DEPTH)/third_party/webrtc/webrtc.gyp:webrtc',
602             '<@(libjingle_peerconnection_additional_deps)',
603             'libjingle_webrtc_common',
604           ],
605           'conditions': [
606             ['libpeer_target_type!="static_library"', {
607               'sources': [
608                 'overrides/initialize_module.cc',
609               ],
610               'conditions': [
611                 ['OS!="mac" and OS!="android"', {
612                   'sources': [
613                     'overrides/allocator_shim/allocator_proxy.cc',
614                   ],
615                 }],
616               ],
617             }],
618             ['"<(libpeer_target_type)"!="static_library"', {
619               # Used to control symbol export/import.
620               'defines': [ 'LIBPEERCONNECTION_IMPLEMENTATION=1' ],
621             }],
622             ['OS=="win" and "<(libpeer_target_type)"!="static_library"', {
623               'link_settings': {
624                 'libraries': [
625                   '-lsecur32.lib',
626                   '-lcrypt32.lib',
627                   '-liphlpapi.lib',
628                 ],
629               },
630             }],
631             ['OS!="win" and "<(libpeer_target_type)"!="static_library"', {
632               'cflags': [
633                 # For compatibility with how we export symbols from this
634                 # target on Windows.  This also prevents the linker from
635                 # picking up symbols from this target that should be linked
636                 # in from other libjingle libs.
637                 '-fvisibility=hidden',
638               ],
639             }],
640             ['OS=="mac" and libpeer_target_type!="static_library"', {
641               'product_name': 'libpeerconnection',
642             }],
643             ['OS=="android" and "<(libpeer_target_type)"=="static_library"', {
644               'standalone_static_library': 1,
645             }],
646             ['OS=="linux" and libpeer_target_type!="static_library"', {
647               # The installer and various tools depend on finding the .so
648               # in this directory and not lib.target as will otherwise be
649               # the case with make builds.
650               'product_dir': '<(PRODUCT_DIR)/lib',
651             }],
652           ],
653         },  # target libpeerconnection
654       ],
655     }],
656   ],