blob: b941544ea422e21d85f2db957eb5ad003c01fd1d [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': [
kjellandera8a7ef62016-04-05 08:13:31 -070012 ['os_posix==1 and OS!="mac" and OS!="ios"', {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +000013 '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': [
Karl Wiberge2a83ee2015-10-26 19:51:29 +010032 'array_view.h',
Peter Boströmff019b02015-04-30 14:16:07 +020033 'atomicops.h',
Tommicc4fdde2016-04-22 19:34:59 +020034 'bind.h',
Noah Richards915590e2015-04-22 15:43:08 -070035 'bitbuffer.cc',
36 'bitbuffer.h',
Karl Wiberg94784372015-04-20 14:03:07 +020037 'buffer.h',
Joachim Bauch6f2ef742015-05-21 17:52:01 +020038 'bufferqueue.cc',
39 'bufferqueue.h',
Noah Richards915590e2015-04-22 15:43:08 -070040 'bytebuffer.cc',
41 'bytebuffer.h',
42 'byteorder.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000043 'checks.cc',
44 'checks.h',
Noah Richards915590e2015-04-22 15:43:08 -070045 'constructormagic.h',
tommiebfbab52016-03-19 11:36:18 -070046 'copyonwritebuffer.cc',
47 'copyonwritebuffer.h',
Tommi494f2092015-04-27 17:39:23 +020048 'criticalsection.cc',
49 'criticalsection.h',
kwiberg45fd9fe2015-12-16 01:09:16 -080050 'deprecation.h',
tommi@webrtc.org4c0fd962015-02-09 10:23:27 +000051 'event.cc',
52 'event.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +000053 'event_tracer.cc',
54 'event_tracer.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000055 'exp_filter.cc',
56 'exp_filter.h',
ivoc48052312016-08-25 04:43:45 -070057 'format_macros.h',
Taylor Brandstetter5d97a9a2016-06-10 14:17:27 -070058 'location.h',
59 'location.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000060 'md5.cc',
61 'md5.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +000062 'md5digest.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000063 'md5digest.h',
philipel5ab4c6d2016-03-08 03:36:15 -080064 'mod_ops.h',
skvlad98bb6642016-04-07 15:36:45 -070065 'onetimeevent.h',
Karl Wibergbe579832015-11-10 22:34:18 +010066 'optional.h',
xians@webrtc.orge46bc772014-10-10 08:36:56 +000067 'platform_file.cc',
68 'platform_file.h',
Tommibebc6902015-05-18 09:51:42 +020069 'platform_thread.cc',
70 'platform_thread.h',
pbos12411ef2015-11-23 14:47:56 -080071 'platform_thread_types.h',
Peter Boström02bafc62016-07-01 12:45:15 +020072 'race_checker.cc',
73 'race_checker.h',
terelius84e78f92015-12-10 01:50:55 -080074 'random.cc',
75 'random.h',
tkchinf75d0082016-02-23 22:49:42 -080076 'rate_statistics.cc',
77 'rate_statistics.h',
sprangcd349d92016-07-13 09:11:28 -070078 'rate_limiter.cc',
79 'rate_limiter.h',
Peter Boström2ee24392015-06-22 07:57:16 +020080 'ratetracker.cc',
81 'ratetracker.h',
tommi04af8392016-02-14 08:11:10 -080082 'refcount.h',
Tommid44c0772016-03-11 17:12:32 -080083 'safe_conversions.h',
84 'safe_conversions_impl.h',
kwibergac554ee2016-09-02 00:39:33 -070085 'sanitizer.h',
tommi04af8392016-02-14 08:11:10 -080086 'scoped_ref_ptr.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000087 'stringencode.cc',
88 'stringencode.h',
89 'stringutils.cc',
90 'stringutils.h',
terelius85fa7d52016-03-24 01:51:52 -070091 'swap_queue.h',
tommiefefda62015-08-20 05:04:09 -070092 'systeminfo.cc',
93 'systeminfo.h',
kwiberg@webrtc.orgaf9d56f2015-01-13 20:32:04 +000094 'template_util.h',
pbos@webrtc.org38344ed2014-09-24 06:05:00 +000095 'thread_annotations.h',
tommi@webrtc.org04cd4662015-01-26 15:27:29 +000096 'thread_checker.h',
97 'thread_checker_impl.cc',
98 'thread_checker_impl.h',
nisse191b3592016-06-22 08:36:53 -070099 'timestampaligner.cc',
100 'timestampaligner.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000101 'timeutils.cc',
102 'timeutils.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +0000103 'trace_event.h',
Noah Richards915590e2015-04-22 15:43:08 -0700104 ],
105 'conditions': [
106 ['build_with_chromium==1', {
Peter Boström11e02292015-11-25 21:36:14 +0100107 'dependencies': [
108 '<(DEPTH)/base/base.gyp:base',
109 ],
Noah Richards915590e2015-04-22 15:43:08 -0700110 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700111 '../../webrtc_overrides',
Noah Richards915590e2015-04-22 15:43:08 -0700112 ],
Peter Boström11e02292015-11-25 21:36:14 +0100113 'sources': [
114 '../../webrtc_overrides/webrtc/base/logging.cc',
115 '../../webrtc_overrides/webrtc/base/logging.h',
116 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700117 }, {
118 'sources': [
Tommi23edcff2015-05-25 10:45:43 +0200119 'logging.cc',
120 'logging.h',
Tommi09ca02e2016-04-24 17:32:48 +0200121 'logging_mac.mm',
Noah Richards915590e2015-04-22 15:43:08 -0700122 ],
tommic06b1332016-05-14 11:31:40 -0700123 }],
tommi09c60da2016-05-24 11:40:35 -0700124 ['OS=="mac" and build_with_chromium==0', {
125 'all_dependent_settings': {
126 'xcode_settings': {
127 'OTHER_LDFLAGS': [
128 # needed for logging_mac.mm
129 '-framework Foundation',
130 ],
131 },
132 },
133 }], # OS=="mac" and build_with_chromium==0
aleloi16f55a12016-08-23 08:08:23 -0700134 ['OS=="android"', {
135 'link_settings': {
136 'libraries': [
137 '-llog',
138 ],
139 },
140 }],
tommi09c60da2016-05-24 11:40:35 -0700141 ],
142 },
143 {
144 'target_name': 'rtc_task_queue',
145 'type': 'static_library',
146 'dependencies': [
147 'rtc_base_approved',
148 ],
149 'sources': [
perkj9c16fe82016-07-12 15:04:07 -0700150 'sequenced_task_checker.h',
151 'sequenced_task_checker_impl.cc',
152 'sequenced_task_checker_impl.h',
tommi09c60da2016-05-24 11:40:35 -0700153 ],
154 'conditions': [
perkj84bd5c72016-08-30 23:01:06 -0700155 ['build_with_chromium==1', {
156 'include_dirs': [
157 '../../webrtc_overrides'
Tommi0bcbbd32016-05-15 13:42:45 +0200158 ],
perkj84bd5c72016-08-30 23:01:06 -0700159 'sources' : [
160 '../../webrtc_overrides/webrtc/base/task_queue.cc',
161 '../../webrtc_overrides/webrtc/base/task_queue.h',
162 ]
163 } , {
164 # If not build for chromium, use our own implementation.
165 'sources' : [
166 'task_queue.h',
167 'task_queue_posix.h',
phoglundff274392016-05-17 03:44:28 -0700168 ],
phoglundff274392016-05-17 03:44:28 -0700169 'conditions': [
perkj84bd5c72016-08-30 23:01:06 -0700170 ['build_libevent==1', {
171 'dependencies': [
172 '<(DEPTH)/base/third_party/libevent/libevent.gyp:libevent',
173 ],
phoglundff274392016-05-17 03:44:28 -0700174 }],
perkj84bd5c72016-08-30 23:01:06 -0700175 ['enable_libevent==1', {
176 'sources': [
177 'task_queue_libevent.cc',
178 'task_queue_posix.cc',
179 ],
180 'defines': [ 'WEBRTC_BUILD_LIBEVENT' ],
181 'all_dependent_settings': {
182 'defines': [ 'WEBRTC_BUILD_LIBEVENT' ]
183 },
184 }, {
185 # If not libevent, fall back to the other task queues.
186 'conditions': [
187 ['OS=="mac" or OS=="ios"', {
188 'sources': [
189 'task_queue_gcd.cc',
190 'task_queue_posix.cc',
191 ],
192 }],
193 ['OS=="win"', {
194 'sources': [ 'task_queue_win.cc' ],
195 }]
196 ],
197 }],
198 ]
Noah Richards915590e2015-04-22 15:43:08 -0700199 }],
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000200 ],
201 },
202 {
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000203 'target_name': 'rtc_base',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000204 'type': 'static_library',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000205 'dependencies': [
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000206 '<(webrtc_root)/common.gyp:webrtc_common',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000207 'rtc_base_approved',
208 ],
jbroman5584bf42016-01-12 09:46:55 -0800209 'export_dependent_settings': [
210 'rtc_base_approved',
211 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000212 'defines': [
213 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700214 'SSL_USE_OPENSSL',
215 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000216 'LOGGING=1',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000217 ],
218 'sources': [
pkasting@chromium.orge7a4a122015-01-28 21:36:55 +0000219 'arraysize.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000220 'asyncfile.cc',
221 'asyncfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000222 'asyncinvoker.cc',
223 'asyncinvoker.h',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000224 'asyncinvoker-inl.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000225 'asyncpacketsocket.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000226 'asyncpacketsocket.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000227 'asyncresolverinterface.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000228 'asyncresolverinterface.h',
229 'asyncsocket.cc',
230 'asyncsocket.h',
231 'asynctcpsocket.cc',
232 'asynctcpsocket.h',
233 'asyncudpsocket.cc',
234 'asyncudpsocket.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000235 'autodetectproxy.cc',
236 'autodetectproxy.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000237 'base64.cc',
238 'base64.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000239 'common.cc',
240 'common.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000241 'crc32.cc',
242 'crc32.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000243 'cryptstring.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000244 'cryptstring.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000245 'diskcache.cc',
246 'diskcache.h',
tkchin93411912015-07-22 12:12:17 -0700247 'filerotatingstream.cc',
248 'filerotatingstream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000249 'fileutils.cc',
250 'fileutils.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000251 'firewallsocketserver.cc',
252 'firewallsocketserver.h',
253 'flags.cc',
254 'flags.h',
255 'gunit_prod.h',
256 'helpers.cc',
257 'helpers.h',
258 'httpbase.cc',
259 'httpbase.h',
260 'httpclient.cc',
261 'httpclient.h',
262 'httpcommon-inl.h',
263 'httpcommon.cc',
264 'httpcommon.h',
265 'httprequest.cc',
266 'httprequest.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000267 'iosfilesystem.mm',
268 'ipaddress.cc',
269 'ipaddress.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000270 'linked_ptr.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000271 'messagedigest.cc',
272 'messagedigest.h',
273 'messagehandler.cc',
274 'messagehandler.h',
275 'messagequeue.cc',
276 'messagequeue.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000277 'nethelpers.cc',
278 'nethelpers.h',
279 'network.cc',
280 'network.h',
honghaiz023f3ef2015-10-19 09:39:32 -0700281 'networkmonitor.cc',
282 'networkmonitor.h',
danilchapbebf54c2016-04-28 01:32:48 -0700283 'nullsocketserver.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000284 'nullsocketserver.h',
torbjorng07d09362015-09-22 11:58:04 -0700285 'openssl.h',
286 'openssladapter.cc',
287 'openssladapter.h',
288 'openssldigest.cc',
289 'openssldigest.h',
290 'opensslidentity.cc',
291 'opensslidentity.h',
292 'opensslstreamadapter.cc',
293 'opensslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000294 'pathutils.cc',
295 'pathutils.h',
296 'physicalsocketserver.cc',
297 'physicalsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000298 'proxydetect.cc',
299 'proxydetect.h',
300 'proxyinfo.cc',
301 'proxyinfo.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000302 'ratelimiter.cc',
303 'ratelimiter.h',
Henrik Boström41b3a382015-08-20 12:15:54 +0200304 'rtccertificate.cc',
305 'rtccertificate.h',
Henrik Boströmda3a1da2016-04-15 17:55:21 +0200306 'rtccertificategenerator.cc',
307 'rtccertificategenerator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000308 'sha1.cc',
309 'sha1.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000310 'sha1digest.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000311 'sha1digest.h',
tommi@webrtc.orgfe196992015-02-07 22:35:54 +0000312 'sharedexclusivelock.cc',
313 'sharedexclusivelock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000314 'signalthread.cc',
315 'signalthread.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000316 'sigslot.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000317 'sigslot.h',
318 'sigslotrepeater.h',
319 'socket.h',
320 'socketadapters.cc',
321 'socketadapters.h',
322 'socketaddress.cc',
323 'socketaddress.h',
324 'socketaddresspair.cc',
325 'socketaddresspair.h',
326 'socketfactory.h',
327 'socketpool.cc',
328 'socketpool.h',
329 'socketserver.h',
330 'socketstream.cc',
331 'socketstream.h',
332 'ssladapter.cc',
333 'ssladapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000334 'sslfingerprint.cc',
335 'sslfingerprint.h',
336 'sslidentity.cc',
337 'sslidentity.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000338 'sslsocketfactory.cc',
339 'sslsocketfactory.h',
340 'sslstreamadapter.cc',
341 'sslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000342 'stream.cc',
343 'stream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000344 'task.cc',
345 'task.h',
346 'taskparent.cc',
347 'taskparent.h',
348 'taskrunner.cc',
349 'taskrunner.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000350 'thread.cc',
351 'thread.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000352 'timing.cc',
353 'timing.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000354 'urlencode.cc',
355 'urlencode.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000356 'worker.cc',
357 'worker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000358 ],
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000359 # TODO(henrike): issue 3307, make rtc_base build without disabling
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000360 # these flags.
361 'cflags!': [
362 '-Wextra',
363 '-Wall',
364 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000365 'direct_dependent_settings': {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000366 'defines': [
367 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700368 'SSL_USE_OPENSSL',
369 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000370 ],
371 },
372 'include_dirs': [
373 '../../third_party/jsoncpp/overrides/include',
374 '../../third_party/jsoncpp/source/include',
375 ],
376 'conditions': [
377 ['build_with_chromium==1', {
378 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700379 '../../webrtc_overrides',
henrike@webrtc.org6ac22e62014-08-11 21:06:30 +0000380 '../../boringssl/src/include',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000381 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700382 'conditions': [
383 ['OS=="win"', {
384 'sources': [
385 '../../webrtc_overrides/webrtc/base/win32socketinit.cc',
386 ],
387 }],
henrikg9dff0ba2015-10-02 10:07:50 -0700388 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700389 'defines': [
390 'NO_MAIN_THREAD_WRAPPING',
391 ],
392 'direct_dependent_settings': {
393 'defines': [
394 'NO_MAIN_THREAD_WRAPPING',
395 ],
396 },
397 }, {
398 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000399 'bandwidthsmoother.cc',
400 'bandwidthsmoother.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000401 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000402 'fileutils_mock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000403 'httpserver.cc',
404 'httpserver.h',
405 'json.cc',
406 'json.h',
tkchin93411912015-07-22 12:12:17 -0700407 'logsinks.cc',
408 'logsinks.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000409 'mathutils.h',
410 'multipart.cc',
411 'multipart.h',
412 'natserver.cc',
413 'natserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000414 'natsocketfactory.cc',
415 'natsocketfactory.h',
416 'nattypes.cc',
417 'nattypes.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000418 'optionsfile.cc',
419 'optionsfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000420 'profiler.cc',
421 'profiler.h',
422 'proxyserver.cc',
423 'proxyserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000424 'referencecountedsingletonfactory.h',
425 'rollingaccumulator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000426 'scopedptrcollection.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000427 'sec_buffer.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000428 'sslconfig.h',
429 'sslroots.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000430 'testbase64.h',
431 'testclient.cc',
432 'testclient.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000433 'transformadapter.cc',
434 'transformadapter.h',
435 'versionparsing.cc',
436 'versionparsing.h',
437 'virtualsocketserver.cc',
438 'virtualsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000439 'window.h',
kjellanderc8587ad2016-04-05 05:23:26 -0700440 'windowpicker.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700441 'windowpickerfactory.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000442 ],
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000443 'conditions': [
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000444 ['build_json==1', {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000445 'dependencies': [
446 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
447 ],
448 }, {
449 'include_dirs': [
450 '<(json_root)',
451 ],
452 'defines': [
453 # When defined changes the include path for json.h to where it
454 # is expected to be when building json outside of the standalone
455 # build.
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000456 'WEBRTC_EXTERNAL_JSON',
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000457 ],
458 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700459 ['OS=="linux"', {
460 'sources': [
461 'dbus.cc',
462 'dbus.h',
463 'libdbusglibsymboltable.cc',
464 'libdbusglibsymboltable.h',
465 'linuxfdwalk.c',
466 'linuxfdwalk.h',
467 ],
468 }],
469 ['os_posix==1', {
470 'sources': [
471 'latebindingsymboltable.cc',
kjellandera8a7ef62016-04-05 08:13:31 -0700472 'latebindingsymboltable.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700473 'posix.cc',
474 'posix.h',
475 ],
476 }],
477 ['OS=="mac"', {
478 'sources': [
479 'macasyncsocket.cc',
480 'macasyncsocket.h',
481 'maccocoasocketserver.h',
482 'maccocoasocketserver.mm',
483 'macsocketserver.cc',
484 'macsocketserver.h',
485 'macwindowpicker.cc',
486 'macwindowpicker.h',
487 ],
488 }],
489 ['OS=="win"', {
490 'sources': [
491 'diskcache_win32.cc',
492 'diskcache_win32.h',
493 'win32regkey.cc',
494 'win32regkey.h',
495 'win32socketinit.cc',
496 'win32socketinit.h',
497 'win32socketserver.cc',
498 'win32socketserver.h',
499 ],
500 }],
kjellander7cae30c2015-12-16 14:05:29 -0800501 ['OS=="win" and clang==1', {
502 'msvs_settings': {
503 'VCCLCompilerTool': {
504 'AdditionalOptions': [
505 # Disable warnings failing when compiling with Clang on Windows.
506 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5366
kjellander3c85cad2016-01-19 04:47:17 -0800507 '-Wno-sign-compare',
kjellander7cae30c2015-12-16 14:05:29 -0800508 '-Wno-missing-braces',
509 ],
510 },
511 },
512 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700513 ], # conditions
514 }], # build_with_chromium==0
515 ['OS=="android"', {
516 'sources': [
517 'ifaddrs-android.cc',
518 'ifaddrs-android.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000519 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000520 'link_settings': {
521 'libraries': [
522 '-llog',
523 '-lGLESv2',
524 ],
525 },
kjellandera8a7ef62016-04-05 08:13:31 -0700526 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200527 ['(OS=="mac" or OS=="ios") and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700528 'sources': [
529 'maccocoathreadhelper.h',
530 'maccocoathreadhelper.mm',
531 'macconversion.cc',
532 'macconversion.h',
533 'macifaddrs_converter.cc',
534 'scoped_autorelease_pool.h',
535 'scoped_autorelease_pool.mm',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000536 ],
537 }],
538 ['OS=="ios"', {
539 'all_dependent_settings': {
540 'xcode_settings': {
541 'OTHER_LDFLAGS': [
Zeke Chin2d3b7e22015-07-14 12:55:44 -0700542 '-framework CFNetwork',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000543 '-framework Foundation',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000544 '-framework Security',
545 '-framework SystemConfiguration',
546 '-framework UIKit',
547 ],
548 },
549 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000550 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700551 ['use_x11==1', {
552 'sources': [
553 'x11windowpicker.cc',
554 'x11windowpicker.h',
555 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000556 'link_settings': {
557 'libraries': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000558 '-ldl',
559 '-lrt',
560 '-lXext',
561 '-lX11',
562 '-lXcomposite',
563 '-lXrender',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000564 ],
565 },
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000566 }],
567 ['OS=="linux"', {
568 'link_settings': {
569 'libraries': [
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000570 '-ldl',
571 '-lrt',
572 ],
573 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000574 }],
575 ['OS=="mac"', {
kjellandera8a7ef62016-04-05 08:13:31 -0700576 'sources': [
577 'macutils.cc',
578 'macutils.h',
579 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000580 'all_dependent_settings': {
581 'link_settings': {
582 'xcode_settings': {
583 'OTHER_LDFLAGS': [
584 '-framework Cocoa',
585 '-framework Foundation',
586 '-framework IOKit',
587 '-framework Security',
588 '-framework SystemConfiguration',
589 ],
590 },
591 },
592 },
593 'conditions': [
594 ['target_arch=="ia32"', {
595 'all_dependent_settings': {
596 'link_settings': {
597 'xcode_settings': {
598 'OTHER_LDFLAGS': [
599 '-framework Carbon',
600 ],
601 },
602 },
603 },
604 }],
605 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000606 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200607 ['OS=="win" and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700608 'sources': [
609 'win32.cc',
610 'win32.h',
611 'win32filesystem.cc',
612 'win32filesystem.h',
613 'win32securityerrors.cc',
614 'win32window.cc',
615 'win32window.h',
616 'win32windowpicker.cc',
617 'win32windowpicker.h',
618 'winfirewall.cc',
619 'winfirewall.h',
620 'winping.cc',
621 'winping.h',
Guo-wei Shieh9faf1542015-12-28 14:06:55 -0800622 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000623 'link_settings': {
624 'libraries': [
625 '-lcrypt32.lib',
626 '-liphlpapi.lib',
627 '-lsecur32.lib',
628 ],
629 },
630 # Suppress warnings about WIN32_LEAN_AND_MEAN.
631 'msvs_disabled_warnings': [4005, 4703],
632 'defines': [
633 '_CRT_NONSTDC_NO_DEPRECATE',
634 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000635 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700636 ['os_posix==1', {
637 'sources': [
638 'ifaddrs_converter.cc',
639 'ifaddrs_converter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000640 'unixfilesystem.cc',
641 'unixfilesystem.h',
642 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000643 'configurations': {
644 'Debug_Base': {
645 'defines': [
646 # Chromium's build/common.gypi defines this for all posix
647 # _except_ for ios & mac. We want it there as well, e.g.
648 # because ASSERT and friends trigger off of it.
649 '_DEBUG',
650 ],
651 },
652 }
653 }],
654 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
655 'defines': [
656 'CARBON_DEPRECATED=YES',
657 ],
658 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700659 ['OS=="linux" or OS=="android"', {
660 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000661 'linux.cc',
662 'linux.h',
663 ],
664 }],
torbjorng07d09362015-09-22 11:58:04 -0700665 ['build_ssl==1', {
666 'dependencies': [
667 '<(DEPTH)/third_party/boringssl/boringssl.gyp:boringssl',
668 ],
669 }, {
670 'include_dirs': [
671 '<(ssl_root)',
672 ],
673 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000674 ],
675 },
kjellander988d31e2016-02-05 00:23:50 -0800676 {
677 'target_name': 'gtest_prod',
678 'type': 'static_library',
679 'sources': [
680 'gtest_prod_util.h',
681 ],
682 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000683 ],
684}