blob: 93be3bc706974333c7bb93c53fa5f927d97606fb [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': [
139 'task_queue.h',
140 'task_queue_posix.h',
141 ],
142 'conditions': [
Tommi0bcbbd32016-05-15 13:42:45 +0200143 ['build_libevent==1', {
144 'dependencies': [
145 '<(DEPTH)/base/third_party/libevent/libevent.gyp:libevent',
146 ],
tommic06b1332016-05-14 11:31:40 -0700147 }],
phoglundff274392016-05-17 03:44:28 -0700148 ['enable_libevent==1', {
149 'sources': [
150 'task_queue_libevent.cc',
151 'task_queue_posix.cc',
152 ],
153 }, {
154 # If not libevent, fall back to the other task queues.
155 'conditions': [
156 ['OS=="mac" or OS=="ios"', {
157 'sources': [
158 'task_queue_gcd.cc',
159 'task_queue_posix.cc',
160 ],
161 }],
162 ['OS=="win"', {
163 'sources': [ 'task_queue_win.cc' ],
164 }]
165 ],
Noah Richards915590e2015-04-22 15:43:08 -0700166 }],
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000167 ],
168 },
169 {
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000170 'target_name': 'rtc_base',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000171 'type': 'static_library',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000172 'dependencies': [
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000173 '<(webrtc_root)/common.gyp:webrtc_common',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000174 'rtc_base_approved',
175 ],
jbroman5584bf42016-01-12 09:46:55 -0800176 'export_dependent_settings': [
177 'rtc_base_approved',
178 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000179 'defines': [
180 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700181 'SSL_USE_OPENSSL',
182 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000183 'LOGGING=1',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000184 ],
185 'sources': [
pkasting@chromium.orge7a4a122015-01-28 21:36:55 +0000186 'arraysize.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000187 'asyncfile.cc',
188 'asyncfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000189 'asyncinvoker.cc',
190 'asyncinvoker.h',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000191 'asyncinvoker-inl.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000192 'asyncpacketsocket.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000193 'asyncpacketsocket.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000194 'asyncresolverinterface.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000195 'asyncresolverinterface.h',
196 'asyncsocket.cc',
197 'asyncsocket.h',
198 'asynctcpsocket.cc',
199 'asynctcpsocket.h',
200 'asyncudpsocket.cc',
201 'asyncudpsocket.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000202 'autodetectproxy.cc',
203 'autodetectproxy.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000204 'base64.cc',
205 'base64.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000206 'common.cc',
207 'common.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000208 'crc32.cc',
209 'crc32.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000210 'cryptstring.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000211 'cryptstring.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000212 'diskcache.cc',
213 'diskcache.h',
tkchin93411912015-07-22 12:12:17 -0700214 'filerotatingstream.cc',
215 'filerotatingstream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000216 'fileutils.cc',
217 'fileutils.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000218 'firewallsocketserver.cc',
219 'firewallsocketserver.h',
220 'flags.cc',
221 'flags.h',
pkasting@chromium.org4591fbd2014-11-20 22:28:14 +0000222 'format_macros.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000223 'gunit_prod.h',
224 'helpers.cc',
225 'helpers.h',
226 'httpbase.cc',
227 'httpbase.h',
228 'httpclient.cc',
229 'httpclient.h',
230 'httpcommon-inl.h',
231 'httpcommon.cc',
232 'httpcommon.h',
233 'httprequest.cc',
234 'httprequest.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000235 'iosfilesystem.mm',
236 'ipaddress.cc',
237 'ipaddress.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000238 'linked_ptr.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000239 'messagedigest.cc',
240 'messagedigest.h',
241 'messagehandler.cc',
242 'messagehandler.h',
243 'messagequeue.cc',
244 'messagequeue.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000245 'nethelpers.cc',
246 'nethelpers.h',
247 'network.cc',
248 'network.h',
honghaiz023f3ef2015-10-19 09:39:32 -0700249 'networkmonitor.cc',
250 'networkmonitor.h',
danilchapbebf54c2016-04-28 01:32:48 -0700251 'nullsocketserver.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000252 'nullsocketserver.h',
torbjorng07d09362015-09-22 11:58:04 -0700253 'openssl.h',
254 'openssladapter.cc',
255 'openssladapter.h',
256 'openssldigest.cc',
257 'openssldigest.h',
258 'opensslidentity.cc',
259 'opensslidentity.h',
260 'opensslstreamadapter.cc',
261 'opensslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000262 'pathutils.cc',
263 'pathutils.h',
264 'physicalsocketserver.cc',
265 'physicalsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000266 'proxydetect.cc',
267 'proxydetect.h',
268 'proxyinfo.cc',
269 'proxyinfo.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000270 'ratelimiter.cc',
271 'ratelimiter.h',
Henrik Boström41b3a382015-08-20 12:15:54 +0200272 'rtccertificate.cc',
273 'rtccertificate.h',
Henrik Boströmda3a1da2016-04-15 17:55:21 +0200274 'rtccertificategenerator.cc',
275 'rtccertificategenerator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000276 'sha1.cc',
277 'sha1.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000278 'sha1digest.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000279 'sha1digest.h',
tommi@webrtc.orgfe196992015-02-07 22:35:54 +0000280 'sharedexclusivelock.cc',
281 'sharedexclusivelock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000282 'signalthread.cc',
283 'signalthread.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000284 'sigslot.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000285 'sigslot.h',
286 'sigslotrepeater.h',
287 'socket.h',
288 'socketadapters.cc',
289 'socketadapters.h',
290 'socketaddress.cc',
291 'socketaddress.h',
292 'socketaddresspair.cc',
293 'socketaddresspair.h',
294 'socketfactory.h',
295 'socketpool.cc',
296 'socketpool.h',
297 'socketserver.h',
298 'socketstream.cc',
299 'socketstream.h',
300 'ssladapter.cc',
301 'ssladapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000302 'sslfingerprint.cc',
303 'sslfingerprint.h',
304 'sslidentity.cc',
305 'sslidentity.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000306 'sslsocketfactory.cc',
307 'sslsocketfactory.h',
308 'sslstreamadapter.cc',
309 'sslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000310 'stream.cc',
311 'stream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000312 'task.cc',
313 'task.h',
314 'taskparent.cc',
315 'taskparent.h',
316 'taskrunner.cc',
317 'taskrunner.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000318 'thread.cc',
319 'thread.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000320 'timing.cc',
321 'timing.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000322 'urlencode.cc',
323 'urlencode.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000324 'worker.cc',
325 'worker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000326 ],
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000327 # TODO(henrike): issue 3307, make rtc_base build without disabling
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000328 # these flags.
329 'cflags!': [
330 '-Wextra',
331 '-Wall',
332 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000333 'direct_dependent_settings': {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000334 'defines': [
335 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700336 'SSL_USE_OPENSSL',
337 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000338 ],
339 },
340 'include_dirs': [
341 '../../third_party/jsoncpp/overrides/include',
342 '../../third_party/jsoncpp/source/include',
343 ],
344 'conditions': [
345 ['build_with_chromium==1', {
346 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700347 '../../webrtc_overrides',
henrike@webrtc.org6ac22e62014-08-11 21:06:30 +0000348 '../../boringssl/src/include',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000349 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700350 'conditions': [
351 ['OS=="win"', {
352 'sources': [
353 '../../webrtc_overrides/webrtc/base/win32socketinit.cc',
354 ],
355 }],
henrikg9dff0ba2015-10-02 10:07:50 -0700356 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700357 'defines': [
358 'NO_MAIN_THREAD_WRAPPING',
359 ],
360 'direct_dependent_settings': {
361 'defines': [
362 'NO_MAIN_THREAD_WRAPPING',
363 ],
364 },
365 }, {
366 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000367 'bandwidthsmoother.cc',
368 'bandwidthsmoother.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000369 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000370 'fileutils_mock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000371 'httpserver.cc',
372 'httpserver.h',
373 'json.cc',
374 'json.h',
tkchin93411912015-07-22 12:12:17 -0700375 'logsinks.cc',
376 'logsinks.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000377 'mathutils.h',
378 'multipart.cc',
379 'multipart.h',
380 'natserver.cc',
381 'natserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000382 'natsocketfactory.cc',
383 'natsocketfactory.h',
384 'nattypes.cc',
385 'nattypes.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000386 'optionsfile.cc',
387 'optionsfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000388 'profiler.cc',
389 'profiler.h',
390 'proxyserver.cc',
391 'proxyserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000392 'referencecountedsingletonfactory.h',
393 'rollingaccumulator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000394 'scopedptrcollection.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000395 'sec_buffer.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000396 'sslconfig.h',
397 'sslroots.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000398 'testbase64.h',
399 'testclient.cc',
400 'testclient.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000401 'transformadapter.cc',
402 'transformadapter.h',
403 'versionparsing.cc',
404 'versionparsing.h',
405 'virtualsocketserver.cc',
406 'virtualsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000407 'window.h',
kjellanderc8587ad2016-04-05 05:23:26 -0700408 'windowpicker.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700409 'windowpickerfactory.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000410 ],
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000411 'conditions': [
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000412 ['build_json==1', {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000413 'dependencies': [
414 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
415 ],
416 }, {
417 'include_dirs': [
418 '<(json_root)',
419 ],
420 'defines': [
421 # When defined changes the include path for json.h to where it
422 # is expected to be when building json outside of the standalone
423 # build.
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000424 'WEBRTC_EXTERNAL_JSON',
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000425 ],
426 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700427 ['OS=="linux"', {
428 'sources': [
429 'dbus.cc',
430 'dbus.h',
431 'libdbusglibsymboltable.cc',
432 'libdbusglibsymboltable.h',
433 'linuxfdwalk.c',
434 'linuxfdwalk.h',
435 ],
436 }],
437 ['os_posix==1', {
438 'sources': [
439 'latebindingsymboltable.cc',
kjellandera8a7ef62016-04-05 08:13:31 -0700440 'latebindingsymboltable.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700441 'posix.cc',
442 'posix.h',
443 ],
444 }],
445 ['OS=="mac"', {
446 'sources': [
447 'macasyncsocket.cc',
448 'macasyncsocket.h',
449 'maccocoasocketserver.h',
450 'maccocoasocketserver.mm',
451 'macsocketserver.cc',
452 'macsocketserver.h',
453 'macwindowpicker.cc',
454 'macwindowpicker.h',
455 ],
456 }],
457 ['OS=="win"', {
458 'sources': [
459 'diskcache_win32.cc',
460 'diskcache_win32.h',
461 'win32regkey.cc',
462 'win32regkey.h',
463 'win32socketinit.cc',
464 'win32socketinit.h',
465 'win32socketserver.cc',
466 'win32socketserver.h',
467 ],
468 }],
kjellander7cae30c2015-12-16 14:05:29 -0800469 ['OS=="win" and clang==1', {
470 'msvs_settings': {
471 'VCCLCompilerTool': {
472 'AdditionalOptions': [
473 # Disable warnings failing when compiling with Clang on Windows.
474 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5366
kjellander3c85cad2016-01-19 04:47:17 -0800475 '-Wno-sign-compare',
kjellander7cae30c2015-12-16 14:05:29 -0800476 '-Wno-missing-braces',
477 ],
478 },
479 },
480 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700481 ], # conditions
482 }], # build_with_chromium==0
483 ['OS=="android"', {
484 'sources': [
485 'ifaddrs-android.cc',
486 'ifaddrs-android.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000487 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000488 'link_settings': {
489 'libraries': [
490 '-llog',
491 '-lGLESv2',
492 ],
493 },
kjellandera8a7ef62016-04-05 08:13:31 -0700494 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200495 ['(OS=="mac" or OS=="ios") and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700496 'sources': [
497 'maccocoathreadhelper.h',
498 'maccocoathreadhelper.mm',
499 'macconversion.cc',
500 'macconversion.h',
501 'macifaddrs_converter.cc',
502 'scoped_autorelease_pool.h',
503 'scoped_autorelease_pool.mm',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000504 ],
505 }],
506 ['OS=="ios"', {
507 'all_dependent_settings': {
508 'xcode_settings': {
509 'OTHER_LDFLAGS': [
Zeke Chin2d3b7e22015-07-14 12:55:44 -0700510 '-framework CFNetwork',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000511 '-framework Foundation',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000512 '-framework Security',
513 '-framework SystemConfiguration',
514 '-framework UIKit',
515 ],
516 },
517 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000518 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700519 ['use_x11==1', {
520 'sources': [
521 'x11windowpicker.cc',
522 'x11windowpicker.h',
523 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000524 'link_settings': {
525 'libraries': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000526 '-ldl',
527 '-lrt',
528 '-lXext',
529 '-lX11',
530 '-lXcomposite',
531 '-lXrender',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000532 ],
533 },
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000534 }],
535 ['OS=="linux"', {
536 'link_settings': {
537 'libraries': [
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000538 '-ldl',
539 '-lrt',
540 ],
541 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000542 }],
543 ['OS=="mac"', {
kjellandera8a7ef62016-04-05 08:13:31 -0700544 'sources': [
545 'macutils.cc',
546 'macutils.h',
547 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000548 'all_dependent_settings': {
549 'link_settings': {
550 'xcode_settings': {
551 'OTHER_LDFLAGS': [
552 '-framework Cocoa',
553 '-framework Foundation',
554 '-framework IOKit',
555 '-framework Security',
556 '-framework SystemConfiguration',
557 ],
558 },
559 },
560 },
561 'conditions': [
562 ['target_arch=="ia32"', {
563 'all_dependent_settings': {
564 'link_settings': {
565 'xcode_settings': {
566 'OTHER_LDFLAGS': [
567 '-framework Carbon',
568 ],
569 },
570 },
571 },
572 }],
573 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000574 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200575 ['OS=="win" and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700576 'sources': [
577 'win32.cc',
578 'win32.h',
579 'win32filesystem.cc',
580 'win32filesystem.h',
581 'win32securityerrors.cc',
582 'win32window.cc',
583 'win32window.h',
584 'win32windowpicker.cc',
585 'win32windowpicker.h',
586 'winfirewall.cc',
587 'winfirewall.h',
588 'winping.cc',
589 'winping.h',
Guo-wei Shieh9faf1542015-12-28 14:06:55 -0800590 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000591 'link_settings': {
592 'libraries': [
593 '-lcrypt32.lib',
594 '-liphlpapi.lib',
595 '-lsecur32.lib',
596 ],
597 },
598 # Suppress warnings about WIN32_LEAN_AND_MEAN.
599 'msvs_disabled_warnings': [4005, 4703],
600 'defines': [
601 '_CRT_NONSTDC_NO_DEPRECATE',
602 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000603 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700604 ['os_posix==1', {
605 'sources': [
606 'ifaddrs_converter.cc',
607 'ifaddrs_converter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000608 'unixfilesystem.cc',
609 'unixfilesystem.h',
610 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000611 'configurations': {
612 'Debug_Base': {
613 'defines': [
614 # Chromium's build/common.gypi defines this for all posix
615 # _except_ for ios & mac. We want it there as well, e.g.
616 # because ASSERT and friends trigger off of it.
617 '_DEBUG',
618 ],
619 },
620 }
621 }],
622 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
623 'defines': [
624 'CARBON_DEPRECATED=YES',
625 ],
626 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700627 ['OS=="linux" or OS=="android"', {
628 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000629 'linux.cc',
630 'linux.h',
631 ],
632 }],
torbjorng07d09362015-09-22 11:58:04 -0700633 ['build_ssl==1', {
634 'dependencies': [
635 '<(DEPTH)/third_party/boringssl/boringssl.gyp:boringssl',
636 ],
637 }, {
638 'include_dirs': [
639 '<(ssl_root)',
640 ],
641 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000642 ],
643 },
kjellander988d31e2016-02-05 00:23:50 -0800644 {
645 'target_name': 'gtest_prod',
646 'type': 'static_library',
647 'sources': [
648 'gtest_prod_util.h',
649 ],
650 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000651 ],
652}