blob: b81ad125eb521d5a351877cc31d09af548d58a77 [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',
Taylor Brandstetter5d97a9a2016-06-10 14:17:27 -070057 'location.h',
58 'location.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000059 'md5.cc',
60 'md5.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +000061 'md5digest.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000062 'md5digest.h',
philipel5ab4c6d2016-03-08 03:36:15 -080063 'mod_ops.h',
skvlad98bb6642016-04-07 15:36:45 -070064 'onetimeevent.h',
Karl Wibergbe579832015-11-10 22:34:18 +010065 'optional.h',
xians@webrtc.orge46bc772014-10-10 08:36:56 +000066 'platform_file.cc',
67 'platform_file.h',
Tommibebc6902015-05-18 09:51:42 +020068 'platform_thread.cc',
69 'platform_thread.h',
pbos12411ef2015-11-23 14:47:56 -080070 'platform_thread_types.h',
Peter Boström02bafc62016-07-01 12:45:15 +020071 'race_checker.cc',
72 'race_checker.h',
terelius84e78f92015-12-10 01:50:55 -080073 'random.cc',
74 'random.h',
tkchinf75d0082016-02-23 22:49:42 -080075 'rate_statistics.cc',
76 'rate_statistics.h',
Peter Boström2ee24392015-06-22 07:57:16 +020077 'ratetracker.cc',
78 'ratetracker.h',
tommi04af8392016-02-14 08:11:10 -080079 'refcount.h',
Tommid44c0772016-03-11 17:12:32 -080080 'safe_conversions.h',
81 'safe_conversions_impl.h',
tommi04af8392016-02-14 08:11:10 -080082 'scoped_ref_ptr.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000083 'stringencode.cc',
84 'stringencode.h',
85 'stringutils.cc',
86 'stringutils.h',
terelius85fa7d52016-03-24 01:51:52 -070087 'swap_queue.h',
tommiefefda62015-08-20 05:04:09 -070088 'systeminfo.cc',
89 'systeminfo.h',
kwiberg@webrtc.orgaf9d56f2015-01-13 20:32:04 +000090 'template_util.h',
pbos@webrtc.org38344ed2014-09-24 06:05:00 +000091 'thread_annotations.h',
tommi@webrtc.org04cd4662015-01-26 15:27:29 +000092 'thread_checker.h',
93 'thread_checker_impl.cc',
94 'thread_checker_impl.h',
nisse191b3592016-06-22 08:36:53 -070095 'timestampaligner.cc',
96 'timestampaligner.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000097 'timeutils.cc',
98 'timeutils.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +000099 'trace_event.h',
Noah Richards915590e2015-04-22 15:43:08 -0700100 ],
101 'conditions': [
102 ['build_with_chromium==1', {
Peter Boström11e02292015-11-25 21:36:14 +0100103 'dependencies': [
104 '<(DEPTH)/base/base.gyp:base',
105 ],
Noah Richards915590e2015-04-22 15:43:08 -0700106 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700107 '../../webrtc_overrides',
Noah Richards915590e2015-04-22 15:43:08 -0700108 ],
Peter Boström11e02292015-11-25 21:36:14 +0100109 'sources': [
110 '../../webrtc_overrides/webrtc/base/logging.cc',
111 '../../webrtc_overrides/webrtc/base/logging.h',
112 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700113 }, {
114 'sources': [
Tommi23edcff2015-05-25 10:45:43 +0200115 'logging.cc',
116 'logging.h',
Tommi09ca02e2016-04-24 17:32:48 +0200117 'logging_mac.mm',
Noah Richards915590e2015-04-22 15:43:08 -0700118 ],
tommic06b1332016-05-14 11:31:40 -0700119 }],
tommi09c60da2016-05-24 11:40:35 -0700120 ['OS=="mac" and build_with_chromium==0', {
121 'all_dependent_settings': {
122 'xcode_settings': {
123 'OTHER_LDFLAGS': [
124 # needed for logging_mac.mm
125 '-framework Foundation',
126 ],
127 },
128 },
129 }], # OS=="mac" and build_with_chromium==0
130 ],
131 },
132 {
133 'target_name': 'rtc_task_queue',
134 'type': 'static_library',
135 'dependencies': [
136 'rtc_base_approved',
137 ],
138 'sources': [
perkj9c16fe82016-07-12 15:04:07 -0700139 'sequenced_task_checker.h',
140 'sequenced_task_checker_impl.cc',
141 'sequenced_task_checker_impl.h',
tommi09c60da2016-05-24 11:40:35 -0700142 'task_queue.h',
143 'task_queue_posix.h',
144 ],
145 'conditions': [
Tommi0bcbbd32016-05-15 13:42:45 +0200146 ['build_libevent==1', {
147 'dependencies': [
148 '<(DEPTH)/base/third_party/libevent/libevent.gyp:libevent',
149 ],
tommic06b1332016-05-14 11:31:40 -0700150 }],
phoglundff274392016-05-17 03:44:28 -0700151 ['enable_libevent==1', {
152 'sources': [
153 'task_queue_libevent.cc',
154 'task_queue_posix.cc',
155 ],
156 }, {
157 # If not libevent, fall back to the other task queues.
158 'conditions': [
159 ['OS=="mac" or OS=="ios"', {
160 'sources': [
161 'task_queue_gcd.cc',
162 'task_queue_posix.cc',
163 ],
164 }],
165 ['OS=="win"', {
166 'sources': [ 'task_queue_win.cc' ],
167 }]
168 ],
Noah Richards915590e2015-04-22 15:43:08 -0700169 }],
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000170 ],
171 },
172 {
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000173 'target_name': 'rtc_base',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000174 'type': 'static_library',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000175 'dependencies': [
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000176 '<(webrtc_root)/common.gyp:webrtc_common',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000177 'rtc_base_approved',
178 ],
jbroman5584bf42016-01-12 09:46:55 -0800179 'export_dependent_settings': [
180 'rtc_base_approved',
181 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000182 'defines': [
183 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700184 'SSL_USE_OPENSSL',
185 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000186 'LOGGING=1',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000187 ],
188 'sources': [
pkasting@chromium.orge7a4a122015-01-28 21:36:55 +0000189 'arraysize.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000190 'asyncfile.cc',
191 'asyncfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000192 'asyncinvoker.cc',
193 'asyncinvoker.h',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000194 'asyncinvoker-inl.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000195 'asyncpacketsocket.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000196 'asyncpacketsocket.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000197 'asyncresolverinterface.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000198 'asyncresolverinterface.h',
199 'asyncsocket.cc',
200 'asyncsocket.h',
201 'asynctcpsocket.cc',
202 'asynctcpsocket.h',
203 'asyncudpsocket.cc',
204 'asyncudpsocket.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000205 'autodetectproxy.cc',
206 'autodetectproxy.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000207 'base64.cc',
208 'base64.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000209 'common.cc',
210 'common.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000211 'crc32.cc',
212 'crc32.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000213 'cryptstring.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000214 'cryptstring.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000215 'diskcache.cc',
216 'diskcache.h',
tkchin93411912015-07-22 12:12:17 -0700217 'filerotatingstream.cc',
218 'filerotatingstream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000219 'fileutils.cc',
220 'fileutils.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000221 'firewallsocketserver.cc',
222 'firewallsocketserver.h',
223 'flags.cc',
224 'flags.h',
pkasting@chromium.org4591fbd2014-11-20 22:28:14 +0000225 'format_macros.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000226 'gunit_prod.h',
227 'helpers.cc',
228 'helpers.h',
229 'httpbase.cc',
230 'httpbase.h',
231 'httpclient.cc',
232 'httpclient.h',
233 'httpcommon-inl.h',
234 'httpcommon.cc',
235 'httpcommon.h',
236 'httprequest.cc',
237 'httprequest.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000238 'iosfilesystem.mm',
239 'ipaddress.cc',
240 'ipaddress.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000241 'linked_ptr.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000242 'messagedigest.cc',
243 'messagedigest.h',
244 'messagehandler.cc',
245 'messagehandler.h',
246 'messagequeue.cc',
247 'messagequeue.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000248 'nethelpers.cc',
249 'nethelpers.h',
250 'network.cc',
251 'network.h',
honghaiz023f3ef2015-10-19 09:39:32 -0700252 'networkmonitor.cc',
253 'networkmonitor.h',
danilchapbebf54c2016-04-28 01:32:48 -0700254 'nullsocketserver.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000255 'nullsocketserver.h',
torbjorng07d09362015-09-22 11:58:04 -0700256 'openssl.h',
257 'openssladapter.cc',
258 'openssladapter.h',
259 'openssldigest.cc',
260 'openssldigest.h',
261 'opensslidentity.cc',
262 'opensslidentity.h',
263 'opensslstreamadapter.cc',
264 'opensslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000265 'pathutils.cc',
266 'pathutils.h',
267 'physicalsocketserver.cc',
268 'physicalsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000269 'proxydetect.cc',
270 'proxydetect.h',
271 'proxyinfo.cc',
272 'proxyinfo.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000273 'ratelimiter.cc',
274 'ratelimiter.h',
Henrik Boström41b3a382015-08-20 12:15:54 +0200275 'rtccertificate.cc',
276 'rtccertificate.h',
Henrik Boströmda3a1da2016-04-15 17:55:21 +0200277 'rtccertificategenerator.cc',
278 'rtccertificategenerator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000279 'sha1.cc',
280 'sha1.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000281 'sha1digest.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000282 'sha1digest.h',
tommi@webrtc.orgfe196992015-02-07 22:35:54 +0000283 'sharedexclusivelock.cc',
284 'sharedexclusivelock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000285 'signalthread.cc',
286 'signalthread.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000287 'sigslot.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000288 'sigslot.h',
289 'sigslotrepeater.h',
290 'socket.h',
291 'socketadapters.cc',
292 'socketadapters.h',
293 'socketaddress.cc',
294 'socketaddress.h',
295 'socketaddresspair.cc',
296 'socketaddresspair.h',
297 'socketfactory.h',
298 'socketpool.cc',
299 'socketpool.h',
300 'socketserver.h',
301 'socketstream.cc',
302 'socketstream.h',
303 'ssladapter.cc',
304 'ssladapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000305 'sslfingerprint.cc',
306 'sslfingerprint.h',
307 'sslidentity.cc',
308 'sslidentity.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000309 'sslsocketfactory.cc',
310 'sslsocketfactory.h',
311 'sslstreamadapter.cc',
312 'sslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000313 'stream.cc',
314 'stream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000315 'task.cc',
316 'task.h',
317 'taskparent.cc',
318 'taskparent.h',
319 'taskrunner.cc',
320 'taskrunner.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000321 'thread.cc',
322 'thread.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000323 'timing.cc',
324 'timing.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000325 'urlencode.cc',
326 'urlencode.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000327 'worker.cc',
328 'worker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000329 ],
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000330 # TODO(henrike): issue 3307, make rtc_base build without disabling
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000331 # these flags.
332 'cflags!': [
333 '-Wextra',
334 '-Wall',
335 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000336 'direct_dependent_settings': {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000337 'defines': [
338 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700339 'SSL_USE_OPENSSL',
340 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000341 ],
342 },
343 'include_dirs': [
344 '../../third_party/jsoncpp/overrides/include',
345 '../../third_party/jsoncpp/source/include',
346 ],
347 'conditions': [
348 ['build_with_chromium==1', {
349 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700350 '../../webrtc_overrides',
henrike@webrtc.org6ac22e62014-08-11 21:06:30 +0000351 '../../boringssl/src/include',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000352 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700353 'conditions': [
354 ['OS=="win"', {
355 'sources': [
356 '../../webrtc_overrides/webrtc/base/win32socketinit.cc',
357 ],
358 }],
henrikg9dff0ba2015-10-02 10:07:50 -0700359 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700360 'defines': [
361 'NO_MAIN_THREAD_WRAPPING',
362 ],
363 'direct_dependent_settings': {
364 'defines': [
365 'NO_MAIN_THREAD_WRAPPING',
366 ],
367 },
368 }, {
369 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000370 'bandwidthsmoother.cc',
371 'bandwidthsmoother.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000372 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000373 'fileutils_mock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000374 'httpserver.cc',
375 'httpserver.h',
376 'json.cc',
377 'json.h',
tkchin93411912015-07-22 12:12:17 -0700378 'logsinks.cc',
379 'logsinks.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000380 'mathutils.h',
381 'multipart.cc',
382 'multipart.h',
383 'natserver.cc',
384 'natserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000385 'natsocketfactory.cc',
386 'natsocketfactory.h',
387 'nattypes.cc',
388 'nattypes.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000389 'optionsfile.cc',
390 'optionsfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000391 'profiler.cc',
392 'profiler.h',
393 'proxyserver.cc',
394 'proxyserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000395 'referencecountedsingletonfactory.h',
396 'rollingaccumulator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000397 'scopedptrcollection.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000398 'sec_buffer.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000399 'sslconfig.h',
400 'sslroots.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000401 'testbase64.h',
402 'testclient.cc',
403 'testclient.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000404 'transformadapter.cc',
405 'transformadapter.h',
406 'versionparsing.cc',
407 'versionparsing.h',
408 'virtualsocketserver.cc',
409 'virtualsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000410 'window.h',
kjellanderc8587ad2016-04-05 05:23:26 -0700411 'windowpicker.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700412 'windowpickerfactory.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000413 ],
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000414 'conditions': [
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000415 ['build_json==1', {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000416 'dependencies': [
417 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
418 ],
419 }, {
420 'include_dirs': [
421 '<(json_root)',
422 ],
423 'defines': [
424 # When defined changes the include path for json.h to where it
425 # is expected to be when building json outside of the standalone
426 # build.
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000427 'WEBRTC_EXTERNAL_JSON',
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000428 ],
429 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700430 ['OS=="linux"', {
431 'sources': [
432 'dbus.cc',
433 'dbus.h',
434 'libdbusglibsymboltable.cc',
435 'libdbusglibsymboltable.h',
436 'linuxfdwalk.c',
437 'linuxfdwalk.h',
438 ],
439 }],
440 ['os_posix==1', {
441 'sources': [
442 'latebindingsymboltable.cc',
kjellandera8a7ef62016-04-05 08:13:31 -0700443 'latebindingsymboltable.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700444 'posix.cc',
445 'posix.h',
446 ],
447 }],
448 ['OS=="mac"', {
449 'sources': [
450 'macasyncsocket.cc',
451 'macasyncsocket.h',
452 'maccocoasocketserver.h',
453 'maccocoasocketserver.mm',
454 'macsocketserver.cc',
455 'macsocketserver.h',
456 'macwindowpicker.cc',
457 'macwindowpicker.h',
458 ],
459 }],
460 ['OS=="win"', {
461 'sources': [
462 'diskcache_win32.cc',
463 'diskcache_win32.h',
464 'win32regkey.cc',
465 'win32regkey.h',
466 'win32socketinit.cc',
467 'win32socketinit.h',
468 'win32socketserver.cc',
469 'win32socketserver.h',
470 ],
471 }],
kjellander7cae30c2015-12-16 14:05:29 -0800472 ['OS=="win" and clang==1', {
473 'msvs_settings': {
474 'VCCLCompilerTool': {
475 'AdditionalOptions': [
476 # Disable warnings failing when compiling with Clang on Windows.
477 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5366
kjellander3c85cad2016-01-19 04:47:17 -0800478 '-Wno-sign-compare',
kjellander7cae30c2015-12-16 14:05:29 -0800479 '-Wno-missing-braces',
480 ],
481 },
482 },
483 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700484 ], # conditions
485 }], # build_with_chromium==0
486 ['OS=="android"', {
487 'sources': [
488 'ifaddrs-android.cc',
489 'ifaddrs-android.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000490 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000491 'link_settings': {
492 'libraries': [
493 '-llog',
494 '-lGLESv2',
495 ],
496 },
kjellandera8a7ef62016-04-05 08:13:31 -0700497 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200498 ['(OS=="mac" or OS=="ios") and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700499 'sources': [
500 'maccocoathreadhelper.h',
501 'maccocoathreadhelper.mm',
502 'macconversion.cc',
503 'macconversion.h',
504 'macifaddrs_converter.cc',
505 'scoped_autorelease_pool.h',
506 'scoped_autorelease_pool.mm',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000507 ],
508 }],
509 ['OS=="ios"', {
510 'all_dependent_settings': {
511 'xcode_settings': {
512 'OTHER_LDFLAGS': [
Zeke Chin2d3b7e22015-07-14 12:55:44 -0700513 '-framework CFNetwork',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000514 '-framework Foundation',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000515 '-framework Security',
516 '-framework SystemConfiguration',
517 '-framework UIKit',
518 ],
519 },
520 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000521 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700522 ['use_x11==1', {
523 'sources': [
524 'x11windowpicker.cc',
525 'x11windowpicker.h',
526 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000527 'link_settings': {
528 'libraries': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000529 '-ldl',
530 '-lrt',
531 '-lXext',
532 '-lX11',
533 '-lXcomposite',
534 '-lXrender',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000535 ],
536 },
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000537 }],
538 ['OS=="linux"', {
539 'link_settings': {
540 'libraries': [
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000541 '-ldl',
542 '-lrt',
543 ],
544 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000545 }],
546 ['OS=="mac"', {
kjellandera8a7ef62016-04-05 08:13:31 -0700547 'sources': [
548 'macutils.cc',
549 'macutils.h',
550 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000551 'all_dependent_settings': {
552 'link_settings': {
553 'xcode_settings': {
554 'OTHER_LDFLAGS': [
555 '-framework Cocoa',
556 '-framework Foundation',
557 '-framework IOKit',
558 '-framework Security',
559 '-framework SystemConfiguration',
560 ],
561 },
562 },
563 },
564 'conditions': [
565 ['target_arch=="ia32"', {
566 'all_dependent_settings': {
567 'link_settings': {
568 'xcode_settings': {
569 'OTHER_LDFLAGS': [
570 '-framework Carbon',
571 ],
572 },
573 },
574 },
575 }],
576 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000577 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200578 ['OS=="win" and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700579 'sources': [
580 'win32.cc',
581 'win32.h',
582 'win32filesystem.cc',
583 'win32filesystem.h',
584 'win32securityerrors.cc',
585 'win32window.cc',
586 'win32window.h',
587 'win32windowpicker.cc',
588 'win32windowpicker.h',
589 'winfirewall.cc',
590 'winfirewall.h',
591 'winping.cc',
592 'winping.h',
Guo-wei Shieh9faf1542015-12-28 14:06:55 -0800593 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000594 'link_settings': {
595 'libraries': [
596 '-lcrypt32.lib',
597 '-liphlpapi.lib',
598 '-lsecur32.lib',
599 ],
600 },
601 # Suppress warnings about WIN32_LEAN_AND_MEAN.
602 'msvs_disabled_warnings': [4005, 4703],
603 'defines': [
604 '_CRT_NONSTDC_NO_DEPRECATE',
605 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000606 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700607 ['os_posix==1', {
608 'sources': [
609 'ifaddrs_converter.cc',
610 'ifaddrs_converter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000611 'unixfilesystem.cc',
612 'unixfilesystem.h',
613 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000614 'configurations': {
615 'Debug_Base': {
616 'defines': [
617 # Chromium's build/common.gypi defines this for all posix
618 # _except_ for ios & mac. We want it there as well, e.g.
619 # because ASSERT and friends trigger off of it.
620 '_DEBUG',
621 ],
622 },
623 }
624 }],
625 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
626 'defines': [
627 'CARBON_DEPRECATED=YES',
628 ],
629 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700630 ['OS=="linux" or OS=="android"', {
631 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000632 'linux.cc',
633 'linux.h',
634 ],
635 }],
torbjorng07d09362015-09-22 11:58:04 -0700636 ['build_ssl==1', {
637 'dependencies': [
638 '<(DEPTH)/third_party/boringssl/boringssl.gyp:boringssl',
639 ],
640 }, {
641 'include_dirs': [
642 '<(ssl_root)',
643 ],
644 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000645 ],
646 },
kjellander988d31e2016-02-05 00:23:50 -0800647 {
648 'target_name': 'gtest_prod',
649 'type': 'static_library',
650 'sources': [
651 'gtest_prod_util.h',
652 ],
653 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000654 ],
655}