blob: 66571f804db32388803ce0b8a35923a12566a2fd [file] [log] [blame]
henrike@webrtc.orgf0488722014-05-13 18:00:26 +00001# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
2#
3# Use of this source code is governed by a BSD-style license
4# that can be found in the LICENSE file in the root of the source
5# tree. An additional intellectual property rights grant can be found
6# in the file PATENTS. All contributing project authors may
7# be found in the AUTHORS file in the root of the source tree.
8
9{
10 'includes': [ '../build/common.gypi', ],
11 'conditions': [
12 ['os_posix == 1 and OS != "mac" and OS != "ios"', {
13 'conditions': [
14 ['sysroot!=""', {
15 'variables': {
16 'pkg-config': '../../../build/linux/pkg-config-wrapper "<(sysroot)" "<(target_arch)"',
17 },
18 }, {
19 'variables': {
20 'pkg-config': 'pkg-config'
21 },
22 }],
23 ],
24 }],
25 ],
26 'targets': [
27 {
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000028 # The subset of rtc_base approved for use outside of libjingle.
29 'target_name': 'rtc_base_approved',
30 'type': 'static_library',
31 'sources': [
Tommi494f2092015-04-27 17:39:23 +020032 '../overrides/webrtc/base/basictypes.h',
33 '../overrides/webrtc/base/constructormagic.h',
Peter Boströmff019b02015-04-30 14:16:07 +020034 'atomicops.h',
Noah Richards915590e2015-04-22 15:43:08 -070035 'basictypes.h',
36 'bitbuffer.cc',
37 'bitbuffer.h',
Karl Wiberg94784372015-04-20 14:03:07 +020038 'buffer.cc',
39 'buffer.h',
Joachim Bauch6f2ef742015-05-21 17:52:01 +020040 'bufferqueue.cc',
41 'bufferqueue.h',
Noah Richards915590e2015-04-22 15:43:08 -070042 'bytebuffer.cc',
43 'bytebuffer.h',
44 'byteorder.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000045 'checks.cc',
46 'checks.h',
Noah Richards915590e2015-04-22 15:43:08 -070047 'constructormagic.h',
Tommi494f2092015-04-27 17:39:23 +020048 'criticalsection.cc',
49 'criticalsection.h',
tommi@webrtc.org4c0fd962015-02-09 10:23:27 +000050 'event.cc',
51 'event.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +000052 'event_tracer.cc',
53 'event_tracer.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000054 'exp_filter.cc',
55 'exp_filter.h',
Tommi23edcff2015-05-25 10:45:43 +020056 'logging.cc',
57 'logging.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000058 'md5.cc',
59 'md5.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +000060 'md5digest.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000061 'md5digest.h',
xians@webrtc.orge46bc772014-10-10 08:36:56 +000062 'platform_file.cc',
63 'platform_file.h',
Tommibebc6902015-05-18 09:51:42 +020064 'platform_thread.cc',
65 'platform_thread.h',
andrew@webrtc.org0ab42bc2014-12-17 22:56:09 +000066 'safe_conversions.h',
67 'safe_conversions_impl.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000068 'stringencode.cc',
69 'stringencode.h',
70 'stringutils.cc',
71 'stringutils.h',
kwiberg@webrtc.orgaf9d56f2015-01-13 20:32:04 +000072 'template_util.h',
pbos@webrtc.org38344ed2014-09-24 06:05:00 +000073 'thread_annotations.h',
tommi@webrtc.org04cd4662015-01-26 15:27:29 +000074 'thread_checker.h',
75 'thread_checker_impl.cc',
76 'thread_checker_impl.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000077 'timeutils.cc',
78 'timeutils.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +000079 'trace_event.h',
Noah Richards915590e2015-04-22 15:43:08 -070080 ],
81 'conditions': [
82 ['build_with_chromium==1', {
83 'include_dirs': [
84 '../overrides',
85 ],
86 'sources!': [
87 'basictypes.h',
88 'constructormagic.h',
Tommi23edcff2015-05-25 10:45:43 +020089 'logging.cc',
90 'logging.h',
Noah Richards915590e2015-04-22 15:43:08 -070091 ],
92 }, {
93 'sources!': [
94 '../overrides/webrtc/base/basictypes.h',
95 '../overrides/webrtc/base/constructormagic.h',
96 ],
97 }],
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000098 ],
99 },
100 {
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000101 'target_name': 'rtc_base',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000102 'type': 'static_library',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000103 'dependencies': [
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000104 '<(webrtc_root)/common.gyp:webrtc_common',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000105 'rtc_base_approved',
106 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000107 'defines': [
108 'FEATURE_ENABLE_SSL',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000109 'LOGGING=1',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000110 ],
111 'sources': [
pkasting@chromium.orge7a4a122015-01-28 21:36:55 +0000112 'arraysize.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000113 'asyncfile.cc',
114 'asyncfile.h',
115 'asynchttprequest.cc',
116 'asynchttprequest.h',
117 'asyncinvoker.cc',
118 'asyncinvoker.h',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000119 'asyncinvoker-inl.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000120 'asyncpacketsocket.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000121 'asyncpacketsocket.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000122 'asyncresolverinterface.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000123 'asyncresolverinterface.h',
124 'asyncsocket.cc',
125 'asyncsocket.h',
126 'asynctcpsocket.cc',
127 'asynctcpsocket.h',
128 'asyncudpsocket.cc',
129 'asyncudpsocket.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000130 'autodetectproxy.cc',
131 'autodetectproxy.h',
132 'bandwidthsmoother.cc',
133 'bandwidthsmoother.h',
134 'base64.cc',
135 'base64.h',
136 'basicdefs.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000137 'bind.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000138 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000139 'common.cc',
140 'common.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000141 'cpumonitor.cc',
142 'cpumonitor.h',
143 'crc32.cc',
144 'crc32.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000145 'cryptstring.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000146 'cryptstring.h',
147 'dbus.cc',
148 'dbus.h',
149 'diskcache.cc',
150 'diskcache.h',
151 'diskcache_win32.cc',
152 'diskcache_win32.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000153 'fileutils.cc',
154 'fileutils.h',
155 'fileutils_mock.h',
156 'firewallsocketserver.cc',
157 'firewallsocketserver.h',
158 'flags.cc',
159 'flags.h',
pkasting@chromium.org4591fbd2014-11-20 22:28:14 +0000160 'format_macros.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000161 'gunit_prod.h',
162 'helpers.cc',
163 'helpers.h',
164 'httpbase.cc',
165 'httpbase.h',
166 'httpclient.cc',
167 'httpclient.h',
168 'httpcommon-inl.h',
169 'httpcommon.cc',
170 'httpcommon.h',
171 'httprequest.cc',
172 'httprequest.h',
173 'httpserver.cc',
174 'httpserver.h',
175 'ifaddrs-android.cc',
176 'ifaddrs-android.h',
177 'iosfilesystem.mm',
178 'ipaddress.cc',
179 'ipaddress.h',
180 'json.cc',
181 'json.h',
182 'latebindingsymboltable.cc',
183 'latebindingsymboltable.h',
184 'libdbusglibsymboltable.cc',
185 'libdbusglibsymboltable.h',
186 'linux.cc',
187 'linux.h',
188 'linuxfdwalk.c',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000189 'linuxfdwalk.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000190 'linked_ptr.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000191 'macasyncsocket.cc',
192 'macasyncsocket.h',
193 'maccocoasocketserver.h',
194 'maccocoasocketserver.mm',
195 'maccocoathreadhelper.h',
196 'maccocoathreadhelper.mm',
197 'macconversion.cc',
198 'macconversion.h',
199 'macsocketserver.cc',
200 'macsocketserver.h',
201 'macutils.cc',
202 'macutils.h',
203 'macwindowpicker.cc',
204 'macwindowpicker.h',
205 'mathutils.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000206 'messagedigest.cc',
207 'messagedigest.h',
208 'messagehandler.cc',
209 'messagehandler.h',
210 'messagequeue.cc',
211 'messagequeue.h',
212 'multipart.cc',
213 'multipart.h',
214 'natserver.cc',
215 'natserver.h',
216 'natsocketfactory.cc',
217 'natsocketfactory.h',
218 'nattypes.cc',
219 'nattypes.h',
220 'nethelpers.cc',
221 'nethelpers.h',
222 'network.cc',
223 'network.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000224 'nullsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000225 'optionsfile.cc',
226 'optionsfile.h',
227 'pathutils.cc',
228 'pathutils.h',
229 'physicalsocketserver.cc',
230 'physicalsocketserver.h',
231 'posix.cc',
232 'posix.h',
233 'profiler.cc',
234 'profiler.h',
235 'proxydetect.cc',
236 'proxydetect.h',
237 'proxyinfo.cc',
238 'proxyinfo.h',
239 'proxyserver.cc',
240 'proxyserver.h',
241 'ratelimiter.cc',
242 'ratelimiter.h',
243 'ratetracker.cc',
244 'ratetracker.h',
245 'refcount.h',
246 'referencecountedsingletonfactory.h',
247 'rollingaccumulator.h',
248 'schanneladapter.cc',
249 'schanneladapter.h',
250 'scoped_autorelease_pool.h',
251 'scoped_autorelease_pool.mm',
252 'scoped_ptr.h',
253 'scoped_ref_ptr.h',
254 'scopedptrcollection.h',
255 'sec_buffer.h',
256 'sha1.cc',
257 'sha1.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000258 'sha1digest.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000259 'sha1digest.h',
tommi@webrtc.orgfe196992015-02-07 22:35:54 +0000260 'sharedexclusivelock.cc',
261 'sharedexclusivelock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000262 'signalthread.cc',
263 'signalthread.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000264 'sigslot.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000265 'sigslot.h',
266 'sigslotrepeater.h',
267 'socket.h',
268 'socketadapters.cc',
269 'socketadapters.h',
270 'socketaddress.cc',
271 'socketaddress.h',
272 'socketaddresspair.cc',
273 'socketaddresspair.h',
274 'socketfactory.h',
275 'socketpool.cc',
276 'socketpool.h',
277 'socketserver.h',
278 'socketstream.cc',
279 'socketstream.h',
280 'ssladapter.cc',
281 'ssladapter.h',
282 'sslconfig.h',
283 'sslfingerprint.cc',
284 'sslfingerprint.h',
285 'sslidentity.cc',
286 'sslidentity.h',
287 'sslroots.h',
288 'sslsocketfactory.cc',
289 'sslsocketfactory.h',
290 'sslstreamadapter.cc',
291 'sslstreamadapter.h',
292 'sslstreamadapterhelper.cc',
293 'sslstreamadapterhelper.h',
294 'stream.cc',
295 'stream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000296 'systeminfo.cc',
297 'systeminfo.h',
298 'task.cc',
299 'task.h',
300 'taskparent.cc',
301 'taskparent.h',
302 'taskrunner.cc',
303 'taskrunner.h',
304 'testclient.cc',
305 'testclient.h',
306 'thread.cc',
307 'thread.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000308 'timing.cc',
309 'timing.h',
310 'transformadapter.cc',
311 'transformadapter.h',
312 'unixfilesystem.cc',
313 'unixfilesystem.h',
314 'urlencode.cc',
315 'urlencode.h',
316 'versionparsing.cc',
317 'versionparsing.h',
318 'virtualsocketserver.cc',
319 'virtualsocketserver.h',
320 'win32.cc',
321 'win32.h',
322 'win32filesystem.cc',
323 'win32filesystem.h',
324 'win32regkey.cc',
325 'win32regkey.h',
326 'win32securityerrors.cc',
327 'win32socketinit.cc',
328 'win32socketinit.h',
329 'win32socketserver.cc',
330 'win32socketserver.h',
331 'win32window.cc',
332 'win32window.h',
333 'win32windowpicker.cc',
334 'win32windowpicker.h',
335 'window.h',
336 'windowpicker.h',
337 'windowpickerfactory.h',
338 'winfirewall.cc',
339 'winfirewall.h',
340 'winping.cc',
341 'winping.h',
342 'worker.cc',
343 'worker.h',
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000344 'x11windowpicker.cc',
345 'x11windowpicker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000346 '../overrides/webrtc/base/logging.cc',
347 '../overrides/webrtc/base/logging.h',
348 '../overrides/webrtc/base/win32socketinit.cc',
349 ],
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000350 # TODO(henrike): issue 3307, make rtc_base build without disabling
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000351 # these flags.
352 'cflags!': [
353 '-Wextra',
354 '-Wall',
355 ],
356 'cflags_cc!': [
357 '-Wnon-virtual-dtor',
358 ],
359 'direct_dependent_settings': {
360 'cflags_cc!': [
361 '-Wnon-virtual-dtor',
362 ],
363 'defines': [
364 'FEATURE_ENABLE_SSL',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000365 ],
366 },
367 'include_dirs': [
368 '../../third_party/jsoncpp/overrides/include',
369 '../../third_party/jsoncpp/source/include',
370 ],
371 'conditions': [
372 ['build_with_chromium==1', {
373 'include_dirs': [
374 '../overrides',
henrike@webrtc.org6ac22e62014-08-11 21:06:30 +0000375 '../../boringssl/src/include',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000376 ],
377 'sources!': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000378 'atomicops.h',
379 'bandwidthsmoother.cc',
380 'bandwidthsmoother.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000381 'bind.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000382 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000383 'constructormagic.h',
384 'dbus.cc',
385 'dbus.h',
386 'diskcache_win32.cc',
387 'diskcache_win32.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000388 'fileutils_mock.h',
389 'genericslot.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000390 'httpserver.cc',
391 'httpserver.h',
392 'json.cc',
393 'json.h',
394 'latebindingsymboltable.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000395 'latebindingsymboltable.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000396 'libdbusglibsymboltable.cc',
397 'libdbusglibsymboltable.h',
398 'linuxfdwalk.c',
399 'linuxfdwalk.h',
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000400 'x11windowpicker.cc',
401 'x11windowpicker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000402 'logging.cc',
403 'logging.h',
404 'macasyncsocket.cc',
405 'macasyncsocket.h',
406 'maccocoasocketserver.h',
407 'maccocoasocketserver.mm',
408 'macsocketserver.cc',
409 'macsocketserver.h',
410 'macwindowpicker.cc',
411 'macwindowpicker.h',
412 'mathutils.h',
413 'multipart.cc',
414 'multipart.h',
415 'natserver.cc',
416 'natserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000417 'natsocketfactory.cc',
418 'natsocketfactory.h',
419 'nattypes.cc',
420 'nattypes.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000421 'optionsfile.cc',
422 'optionsfile.h',
423 'posix.cc',
424 'posix.h',
425 'profiler.cc',
426 'profiler.h',
427 'proxyserver.cc',
428 'proxyserver.h',
429 'refcount.h',
430 'referencecountedsingletonfactory.h',
431 'rollingaccumulator.h',
432 'safe_conversions.h',
433 'safe_conversions_impl.h',
434 'scopedptrcollection.h',
435 'scoped_ref_ptr.h',
436 'sec_buffer.h',
437 'sharedexclusivelock.cc',
438 'sharedexclusivelock.h',
439 'sslconfig.h',
440 'sslroots.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000441 'testbase64.h',
442 'testclient.cc',
443 'testclient.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000444 'transformadapter.cc',
445 'transformadapter.h',
446 'versionparsing.cc',
447 'versionparsing.h',
448 'virtualsocketserver.cc',
449 'virtualsocketserver.h',
450 'win32regkey.cc',
451 'win32regkey.h',
452 'win32socketinit.cc',
453 'win32socketinit.h',
454 'win32socketserver.cc',
455 'win32socketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000456 'window.h',
457 'windowpickerfactory.h',
458 'windowpicker.h',
459 ],
460 'defines': [
461 'NO_MAIN_THREAD_WRAPPING',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000462 ],
463 'direct_dependent_settings': {
464 'defines': [
465 'NO_MAIN_THREAD_WRAPPING',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000466 ],
467 },
468 }, {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000469 'conditions': [
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000470 ['build_json==1', {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000471 'dependencies': [
472 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
473 ],
474 }, {
475 'include_dirs': [
476 '<(json_root)',
477 ],
478 'defines': [
479 # When defined changes the include path for json.h to where it
480 # is expected to be when building json outside of the standalone
481 # build.
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000482 'WEBRTC_EXTERNAL_JSON',
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000483 ],
484 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000485 ],
486 'sources!': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000487 '../overrides/webrtc/base/win32socketinit.cc',
488 '../overrides/webrtc/base/logging.cc',
489 '../overrides/webrtc/base/logging.h',
490 ],
491 }],
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000492 ['use_openssl==1', {
493 'defines': [
494 'SSL_USE_OPENSSL',
495 'HAVE_OPENSSL_SSL_H',
496 ],
497 'direct_dependent_settings': {
498 'defines': [
499 'SSL_USE_OPENSSL',
500 'HAVE_OPENSSL_SSL_H',
501 ],
502 },
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000503 'sources': [
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000504 'openssl.h',
505 'openssladapter.cc',
506 'openssladapter.h',
507 'openssldigest.cc',
508 'openssldigest.h',
509 'opensslidentity.cc',
510 'opensslidentity.h',
511 'opensslstreamadapter.cc',
512 'opensslstreamadapter.h',
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000513 ],
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000514 'conditions': [
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000515 ['build_ssl==1', {
516 'dependencies': [
517 '<(DEPTH)/third_party/boringssl/boringssl.gyp:boringssl',
518 ],
519 }, {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000520 'include_dirs': [
521 '<(ssl_root)',
522 ],
523 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000524 ],
525 }, {
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000526 'sources': [
527 'nssidentity.cc',
528 'nssidentity.h',
529 'nssstreamadapter.cc',
530 'nssstreamadapter.h',
531 ],
tpsiaki@google.com67eabc02014-09-10 18:06:47 +0000532 'conditions': [
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000533 ['use_legacy_ssl_defaults!=1', {
tpsiaki@google.com67eabc02014-09-10 18:06:47 +0000534 'defines': [
535 'SSL_USE_NSS',
536 'HAVE_NSS_SSL_H',
537 'SSL_USE_NSS_RNG',
538 ],
539 'direct_dependent_settings': {
540 'defines': [
541 'SSL_USE_NSS',
542 'HAVE_NSS_SSL_H',
543 'SSL_USE_NSS_RNG',
544 ],
545 },
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000546 }],
henrike@webrtc.org33a0e2d2014-10-27 18:13:40 +0000547 ['build_ssl==1', {
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000548 'conditions': [
henrike@webrtc.org33a0e2d2014-10-27 18:13:40 +0000549 # On some platforms, the rest of NSS is bundled. On others,
550 # it's pulled from the system.
Henrik Kjellanderca047f72015-04-08 08:54:02 +0200551 ['OS == "mac" or OS == "ios"', {
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000552 'dependencies': [
553 '<(DEPTH)/net/third_party/nss/ssl.gyp:libssl',
pbos@webrtc.org77d5a572014-10-07 11:43:03 +0000554 '<(DEPTH)/third_party/nss/nss.gyp:nspr',
555 '<(DEPTH)/third_party/nss/nss.gyp:nss',
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000556 ],
henrike@webrtc.org33a0e2d2014-10-27 18:13:40 +0000557 }],
558 ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', {
559 'dependencies': [
560 '<(DEPTH)/build/linux/system.gyp:ssl',
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000561 ],
562 }],
563 ],
henrike@webrtc.org33a0e2d2014-10-27 18:13:40 +0000564 }, {
565 'include_dirs': [
566 '<(ssl_root)',
567 ],
pthatcher@webrtc.org5d0071f2014-09-26 18:53:40 +0000568 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000569 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000570 }],
571 ['OS == "android"', {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000572 'link_settings': {
573 'libraries': [
574 '-llog',
575 '-lGLESv2',
576 ],
577 },
578 }, {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000579 'sources!': [
580 'ifaddrs-android.cc',
581 'ifaddrs-android.h',
582 ],
583 }],
584 ['OS=="ios"', {
Yuriy Shevchuk02ff9112015-05-21 13:50:59 +0200585 'sources/': [
586 ['include', 'macconversion.*'],
587 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000588 'all_dependent_settings': {
589 'xcode_settings': {
590 'OTHER_LDFLAGS': [
591 '-framework Foundation',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000592 '-framework Security',
593 '-framework SystemConfiguration',
594 '-framework UIKit',
595 ],
596 },
597 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000598 }],
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000599 ['use_x11 == 1', {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000600 'link_settings': {
601 'libraries': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000602 '-ldl',
603 '-lrt',
604 '-lXext',
605 '-lX11',
606 '-lXcomposite',
607 '-lXrender',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000608 ],
609 },
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000610 }, {
611 'sources!': [
612 'x11windowpicker.cc',
613 'x11windowpicker.h',
614 ],
615 }],
616 ['OS=="linux"', {
617 'link_settings': {
618 'libraries': [
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000619 '-ldl',
620 '-lrt',
621 ],
622 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000623 }, {
624 'sources!': [
625 'dbus.cc',
626 'dbus.h',
627 'libdbusglibsymboltable.cc',
628 'libdbusglibsymboltable.h',
629 'linuxfdwalk.c',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000630 ],
631 }],
632 ['OS=="mac"', {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000633 'all_dependent_settings': {
634 'link_settings': {
635 'xcode_settings': {
636 'OTHER_LDFLAGS': [
637 '-framework Cocoa',
638 '-framework Foundation',
639 '-framework IOKit',
640 '-framework Security',
641 '-framework SystemConfiguration',
642 ],
643 },
644 },
645 },
646 'conditions': [
647 ['target_arch=="ia32"', {
648 'all_dependent_settings': {
649 'link_settings': {
650 'xcode_settings': {
651 'OTHER_LDFLAGS': [
652 '-framework Carbon',
653 ],
654 },
655 },
656 },
657 }],
658 ],
659 }, {
660 'sources!': [
661 'macasyncsocket.cc',
662 'macasyncsocket.h',
663 'maccocoasocketserver.h',
664 'maccocoasocketserver.mm',
665 'macconversion.cc',
666 'macconversion.h',
667 'macsocketserver.cc',
668 'macsocketserver.h',
669 'macutils.cc',
670 'macutils.h',
671 'macwindowpicker.cc',
672 'macwindowpicker.h',
673 ],
674 }],
675 ['OS=="win"', {
676 'link_settings': {
677 'libraries': [
678 '-lcrypt32.lib',
679 '-liphlpapi.lib',
680 '-lsecur32.lib',
681 ],
682 },
683 # Suppress warnings about WIN32_LEAN_AND_MEAN.
684 'msvs_disabled_warnings': [4005, 4703],
685 'defines': [
686 '_CRT_NONSTDC_NO_DEPRECATE',
687 ],
688 }, {
689 'sources/': [
690 ['exclude', 'win32[a-z0-9]*\\.(h|cc)$'],
691 ],
692 'sources!': [
693 'schanneladapter.cc',
694 'schanneladapter.h',
695 'winping.cc',
696 'winping.h',
697 'winfirewall.cc',
698 'winfirewall.h',
699 ],
700 }],
701 ['os_posix==0', {
702 'sources!': [
703 'latebindingsymboltable.cc',
704 'latebindingsymboltable.h',
705 'posix.cc',
706 'posix.h',
707 'unixfilesystem.cc',
708 'unixfilesystem.h',
709 ],
710 }, {
711 'configurations': {
712 'Debug_Base': {
713 'defines': [
714 # Chromium's build/common.gypi defines this for all posix
715 # _except_ for ios & mac. We want it there as well, e.g.
716 # because ASSERT and friends trigger off of it.
717 '_DEBUG',
718 ],
719 },
720 }
721 }],
722 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
723 'defines': [
724 'CARBON_DEPRECATED=YES',
725 ],
726 }],
727 ['OS!="ios" and OS!="mac"', {
728 'sources!': [
729 'scoped_autorelease_pool.mm',
730 ],
731 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000732 ['OS!="linux" and OS!="android"', {
733 'sources!': [
734 'linux.cc',
735 'linux.h',
736 ],
737 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000738 ],
739 },
740 ],
741}