blob: 3efcf69c6ba790fcc640b848f2c2f831d2f4228f [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',
57 'md5.cc',
58 'md5.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +000059 'md5digest.cc',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000060 'md5digest.h',
philipel5ab4c6d2016-03-08 03:36:15 -080061 'mod_ops.h',
skvlad98bb6642016-04-07 15:36:45 -070062 'onetimeevent.h',
Karl Wibergbe579832015-11-10 22:34:18 +010063 'optional.h',
xians@webrtc.orge46bc772014-10-10 08:36:56 +000064 'platform_file.cc',
65 'platform_file.h',
Tommibebc6902015-05-18 09:51:42 +020066 'platform_thread.cc',
67 'platform_thread.h',
pbos12411ef2015-11-23 14:47:56 -080068 'platform_thread_types.h',
terelius84e78f92015-12-10 01:50:55 -080069 'random.cc',
70 'random.h',
tkchinf75d0082016-02-23 22:49:42 -080071 'rate_statistics.cc',
72 'rate_statistics.h',
Peter Boström2ee24392015-06-22 07:57:16 +020073 'ratetracker.cc',
74 'ratetracker.h',
tommi04af8392016-02-14 08:11:10 -080075 'refcount.h',
Tommid44c0772016-03-11 17:12:32 -080076 'safe_conversions.h',
77 'safe_conversions_impl.h',
tommi04af8392016-02-14 08:11:10 -080078 'scoped_ref_ptr.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000079 'stringencode.cc',
80 'stringencode.h',
81 'stringutils.cc',
82 'stringutils.h',
terelius85fa7d52016-03-24 01:51:52 -070083 'swap_queue.h',
tommiefefda62015-08-20 05:04:09 -070084 'systeminfo.cc',
85 'systeminfo.h',
tommic06b1332016-05-14 11:31:40 -070086 'task_queue.h',
tommic06b1332016-05-14 11:31:40 -070087 'task_queue_posix.h',
kwiberg@webrtc.orgaf9d56f2015-01-13 20:32:04 +000088 'template_util.h',
pbos@webrtc.org38344ed2014-09-24 06:05:00 +000089 'thread_annotations.h',
tommi@webrtc.org04cd4662015-01-26 15:27:29 +000090 'thread_checker.h',
91 'thread_checker_impl.cc',
92 'thread_checker_impl.h',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +000093 'timeutils.cc',
94 'timeutils.h',
tommi@webrtc.org7c64ed22015-03-17 14:25:37 +000095 'trace_event.h',
Noah Richards915590e2015-04-22 15:43:08 -070096 ],
97 'conditions': [
98 ['build_with_chromium==1', {
Peter Boström11e02292015-11-25 21:36:14 +010099 'dependencies': [
100 '<(DEPTH)/base/base.gyp:base',
101 ],
Noah Richards915590e2015-04-22 15:43:08 -0700102 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700103 '../../webrtc_overrides',
Noah Richards915590e2015-04-22 15:43:08 -0700104 ],
Peter Boström11e02292015-11-25 21:36:14 +0100105 'sources': [
106 '../../webrtc_overrides/webrtc/base/logging.cc',
107 '../../webrtc_overrides/webrtc/base/logging.h',
108 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700109 }, {
110 'sources': [
Tommi23edcff2015-05-25 10:45:43 +0200111 'logging.cc',
112 'logging.h',
Tommi09ca02e2016-04-24 17:32:48 +0200113 'logging_mac.mm',
Noah Richards915590e2015-04-22 15:43:08 -0700114 ],
tommic06b1332016-05-14 11:31:40 -0700115 }],
Tommi0bcbbd32016-05-15 13:42:45 +0200116 ['build_libevent==1', {
117 'dependencies': [
118 '<(DEPTH)/base/third_party/libevent/libevent.gyp:libevent',
119 ],
tommic06b1332016-05-14 11:31:40 -0700120 }],
phoglundff274392016-05-17 03:44:28 -0700121 ['enable_libevent==1', {
122 'sources': [
123 'task_queue_libevent.cc',
124 'task_queue_posix.cc',
125 ],
126 }, {
127 # If not libevent, fall back to the other task queues.
128 'conditions': [
129 ['OS=="mac" or OS=="ios"', {
130 'sources': [
131 'task_queue_gcd.cc',
132 'task_queue_posix.cc',
133 ],
134 }],
135 ['OS=="win"', {
136 'sources': [ 'task_queue_win.cc' ],
137 }]
138 ],
Noah Richards915590e2015-04-22 15:43:08 -0700139 }],
Tommi09ca02e2016-04-24 17:32:48 +0200140 ['OS=="mac" and build_with_chromium==0', {
141 'all_dependent_settings': {
142 'xcode_settings': {
143 'OTHER_LDFLAGS': [
144 # needed for logging_mac.mm
145 '-framework Foundation',
146 ],
147 },
148 },
149 }], # OS=="mac" and build_with_chromium==0
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000150 ],
151 },
152 {
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000153 'target_name': 'rtc_base',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000154 'type': 'static_library',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000155 'dependencies': [
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000156 '<(webrtc_root)/common.gyp:webrtc_common',
andrew@webrtc.org6ae5a6d2014-09-16 01:03:29 +0000157 'rtc_base_approved',
158 ],
jbroman5584bf42016-01-12 09:46:55 -0800159 'export_dependent_settings': [
160 'rtc_base_approved',
161 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000162 'defines': [
163 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700164 'SSL_USE_OPENSSL',
165 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000166 'LOGGING=1',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000167 ],
168 'sources': [
pkasting@chromium.orge7a4a122015-01-28 21:36:55 +0000169 'arraysize.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000170 'asyncfile.cc',
171 'asyncfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000172 'asyncinvoker.cc',
173 'asyncinvoker.h',
kjellander@webrtc.org2bae3212014-06-16 07:11:19 +0000174 'asyncinvoker-inl.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000175 'asyncpacketsocket.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000176 'asyncpacketsocket.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000177 'asyncresolverinterface.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000178 'asyncresolverinterface.h',
179 'asyncsocket.cc',
180 'asyncsocket.h',
181 'asynctcpsocket.cc',
182 'asynctcpsocket.h',
183 'asyncudpsocket.cc',
184 'asyncudpsocket.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000185 'autodetectproxy.cc',
186 'autodetectproxy.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000187 'base64.cc',
188 'base64.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000189 'common.cc',
190 'common.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000191 'crc32.cc',
192 'crc32.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000193 'cryptstring.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000194 'cryptstring.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000195 'diskcache.cc',
196 'diskcache.h',
tkchin93411912015-07-22 12:12:17 -0700197 'filerotatingstream.cc',
198 'filerotatingstream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000199 'fileutils.cc',
200 'fileutils.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000201 'firewallsocketserver.cc',
202 'firewallsocketserver.h',
203 'flags.cc',
204 'flags.h',
pkasting@chromium.org4591fbd2014-11-20 22:28:14 +0000205 'format_macros.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000206 'gunit_prod.h',
207 'helpers.cc',
208 'helpers.h',
209 'httpbase.cc',
210 'httpbase.h',
211 'httpclient.cc',
212 'httpclient.h',
213 'httpcommon-inl.h',
214 'httpcommon.cc',
215 'httpcommon.h',
216 'httprequest.cc',
217 'httprequest.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000218 'iosfilesystem.mm',
219 'ipaddress.cc',
220 'ipaddress.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000221 'linked_ptr.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000222 'messagedigest.cc',
223 'messagedigest.h',
224 'messagehandler.cc',
225 'messagehandler.h',
226 'messagequeue.cc',
227 'messagequeue.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000228 'nethelpers.cc',
229 'nethelpers.h',
230 'network.cc',
231 'network.h',
honghaiz023f3ef2015-10-19 09:39:32 -0700232 'networkmonitor.cc',
233 'networkmonitor.h',
danilchapbebf54c2016-04-28 01:32:48 -0700234 'nullsocketserver.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000235 'nullsocketserver.h',
torbjorng07d09362015-09-22 11:58:04 -0700236 'openssl.h',
237 'openssladapter.cc',
238 'openssladapter.h',
239 'openssldigest.cc',
240 'openssldigest.h',
241 'opensslidentity.cc',
242 'opensslidentity.h',
243 'opensslstreamadapter.cc',
244 'opensslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000245 'pathutils.cc',
246 'pathutils.h',
247 'physicalsocketserver.cc',
248 'physicalsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000249 'proxydetect.cc',
250 'proxydetect.h',
251 'proxyinfo.cc',
252 'proxyinfo.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000253 'ratelimiter.cc',
254 'ratelimiter.h',
Henrik Boström41b3a382015-08-20 12:15:54 +0200255 'rtccertificate.cc',
256 'rtccertificate.h',
Henrik Boströmda3a1da2016-04-15 17:55:21 +0200257 'rtccertificategenerator.cc',
258 'rtccertificategenerator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000259 'sha1.cc',
260 'sha1.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000261 'sha1digest.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000262 'sha1digest.h',
tommi@webrtc.orgfe196992015-02-07 22:35:54 +0000263 'sharedexclusivelock.cc',
264 'sharedexclusivelock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000265 'signalthread.cc',
266 'signalthread.h',
kwiberg@webrtc.org67186fe2015-03-09 22:21:53 +0000267 'sigslot.cc',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000268 'sigslot.h',
269 'sigslotrepeater.h',
270 'socket.h',
271 'socketadapters.cc',
272 'socketadapters.h',
273 'socketaddress.cc',
274 'socketaddress.h',
275 'socketaddresspair.cc',
276 'socketaddresspair.h',
277 'socketfactory.h',
278 'socketpool.cc',
279 'socketpool.h',
280 'socketserver.h',
281 'socketstream.cc',
282 'socketstream.h',
283 'ssladapter.cc',
284 'ssladapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000285 'sslfingerprint.cc',
286 'sslfingerprint.h',
287 'sslidentity.cc',
288 'sslidentity.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000289 'sslsocketfactory.cc',
290 'sslsocketfactory.h',
291 'sslstreamadapter.cc',
292 'sslstreamadapter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000293 'stream.cc',
294 'stream.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000295 'task.cc',
296 'task.h',
297 'taskparent.cc',
298 'taskparent.h',
299 'taskrunner.cc',
300 'taskrunner.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000301 'thread.cc',
302 'thread.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000303 'timing.cc',
304 'timing.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000305 'urlencode.cc',
306 'urlencode.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000307 'worker.cc',
308 'worker.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000309 ],
henrike@webrtc.orgb2efb672014-09-10 17:28:19 +0000310 # TODO(henrike): issue 3307, make rtc_base build without disabling
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000311 # these flags.
312 'cflags!': [
313 '-Wextra',
314 '-Wall',
315 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000316 'direct_dependent_settings': {
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000317 'defines': [
318 'FEATURE_ENABLE_SSL',
torbjorng07d09362015-09-22 11:58:04 -0700319 'SSL_USE_OPENSSL',
320 'HAVE_OPENSSL_SSL_H',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000321 ],
322 },
323 'include_dirs': [
324 '../../third_party/jsoncpp/overrides/include',
325 '../../third_party/jsoncpp/source/include',
326 ],
327 'conditions': [
328 ['build_with_chromium==1', {
329 'include_dirs': [
henrikgee2bf412015-09-30 03:48:52 -0700330 '../../webrtc_overrides',
henrike@webrtc.org6ac22e62014-08-11 21:06:30 +0000331 '../../boringssl/src/include',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000332 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700333 'conditions': [
334 ['OS=="win"', {
335 'sources': [
336 '../../webrtc_overrides/webrtc/base/win32socketinit.cc',
337 ],
338 }],
henrikg9dff0ba2015-10-02 10:07:50 -0700339 ],
kjellandera8a7ef62016-04-05 08:13:31 -0700340 'defines': [
341 'NO_MAIN_THREAD_WRAPPING',
342 ],
343 'direct_dependent_settings': {
344 'defines': [
345 'NO_MAIN_THREAD_WRAPPING',
346 ],
347 },
348 }, {
349 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000350 'bandwidthsmoother.cc',
351 'bandwidthsmoother.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000352 'callback.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000353 'fileutils_mock.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000354 'httpserver.cc',
355 'httpserver.h',
356 'json.cc',
357 'json.h',
tkchin93411912015-07-22 12:12:17 -0700358 'logsinks.cc',
359 'logsinks.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000360 'mathutils.h',
361 'multipart.cc',
362 'multipart.h',
363 'natserver.cc',
364 'natserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000365 'natsocketfactory.cc',
366 'natsocketfactory.h',
367 'nattypes.cc',
368 'nattypes.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000369 'optionsfile.cc',
370 'optionsfile.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000371 'profiler.cc',
372 'profiler.h',
373 'proxyserver.cc',
374 'proxyserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000375 'referencecountedsingletonfactory.h',
376 'rollingaccumulator.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000377 'scopedptrcollection.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000378 'sec_buffer.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000379 'sslconfig.h',
380 'sslroots.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000381 'testbase64.h',
382 'testclient.cc',
383 'testclient.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000384 'transformadapter.cc',
385 'transformadapter.h',
386 'versionparsing.cc',
387 'versionparsing.h',
388 'virtualsocketserver.cc',
389 'virtualsocketserver.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000390 'window.h',
kjellanderc8587ad2016-04-05 05:23:26 -0700391 'windowpicker.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700392 'windowpickerfactory.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000393 ],
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000394 'conditions': [
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000395 ['build_json==1', {
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000396 'dependencies': [
397 '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
398 ],
399 }, {
400 'include_dirs': [
401 '<(json_root)',
402 ],
403 'defines': [
404 # When defined changes the include path for json.h to where it
405 # is expected to be when building json outside of the standalone
406 # build.
henrike@webrtc.orga685c9d2014-06-17 14:48:44 +0000407 'WEBRTC_EXTERNAL_JSON',
henrike@webrtc.org9f36c082014-06-16 21:35:20 +0000408 ],
409 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700410 ['OS=="linux"', {
411 'sources': [
412 'dbus.cc',
413 'dbus.h',
414 'libdbusglibsymboltable.cc',
415 'libdbusglibsymboltable.h',
416 'linuxfdwalk.c',
417 'linuxfdwalk.h',
418 ],
419 }],
420 ['os_posix==1', {
421 'sources': [
422 'latebindingsymboltable.cc',
kjellandera8a7ef62016-04-05 08:13:31 -0700423 'latebindingsymboltable.h',
kjellandera8a7ef62016-04-05 08:13:31 -0700424 'posix.cc',
425 'posix.h',
426 ],
427 }],
428 ['OS=="mac"', {
429 'sources': [
430 'macasyncsocket.cc',
431 'macasyncsocket.h',
432 'maccocoasocketserver.h',
433 'maccocoasocketserver.mm',
434 'macsocketserver.cc',
435 'macsocketserver.h',
436 'macwindowpicker.cc',
437 'macwindowpicker.h',
438 ],
439 }],
440 ['OS=="win"', {
441 'sources': [
442 'diskcache_win32.cc',
443 'diskcache_win32.h',
444 'win32regkey.cc',
445 'win32regkey.h',
446 'win32socketinit.cc',
447 'win32socketinit.h',
448 'win32socketserver.cc',
449 'win32socketserver.h',
450 ],
451 }],
kjellander7cae30c2015-12-16 14:05:29 -0800452 ['OS=="win" and clang==1', {
453 'msvs_settings': {
454 'VCCLCompilerTool': {
455 'AdditionalOptions': [
456 # Disable warnings failing when compiling with Clang on Windows.
457 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5366
kjellander3c85cad2016-01-19 04:47:17 -0800458 '-Wno-sign-compare',
kjellander7cae30c2015-12-16 14:05:29 -0800459 '-Wno-missing-braces',
460 ],
461 },
462 },
463 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700464 ], # conditions
465 }], # build_with_chromium==0
466 ['OS=="android"', {
467 'sources': [
468 'ifaddrs-android.cc',
469 'ifaddrs-android.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000470 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000471 'link_settings': {
472 'libraries': [
473 '-llog',
474 '-lGLESv2',
475 ],
476 },
kjellandera8a7ef62016-04-05 08:13:31 -0700477 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200478 ['(OS=="mac" or OS=="ios") and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700479 'sources': [
480 'maccocoathreadhelper.h',
481 'maccocoathreadhelper.mm',
482 'macconversion.cc',
483 'macconversion.h',
484 'macifaddrs_converter.cc',
485 'scoped_autorelease_pool.h',
486 'scoped_autorelease_pool.mm',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000487 ],
488 }],
489 ['OS=="ios"', {
490 'all_dependent_settings': {
491 'xcode_settings': {
492 'OTHER_LDFLAGS': [
Zeke Chin2d3b7e22015-07-14 12:55:44 -0700493 '-framework CFNetwork',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000494 '-framework Foundation',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000495 '-framework Security',
496 '-framework SystemConfiguration',
497 '-framework UIKit',
498 ],
499 },
500 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000501 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700502 ['use_x11==1', {
503 'sources': [
504 'x11windowpicker.cc',
505 'x11windowpicker.h',
506 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000507 'link_settings': {
508 'libraries': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000509 '-ldl',
510 '-lrt',
511 '-lXext',
512 '-lX11',
513 '-lXcomposite',
514 '-lXrender',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000515 ],
516 },
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000517 }],
518 ['OS=="linux"', {
519 'link_settings': {
520 'libraries': [
henrike@webrtc.orgfb1eb432014-08-15 14:44:13 +0000521 '-ldl',
522 '-lrt',
523 ],
524 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000525 }],
526 ['OS=="mac"', {
kjellandera8a7ef62016-04-05 08:13:31 -0700527 'sources': [
528 'macutils.cc',
529 'macutils.h',
530 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000531 'all_dependent_settings': {
532 'link_settings': {
533 'xcode_settings': {
534 'OTHER_LDFLAGS': [
535 '-framework Cocoa',
536 '-framework Foundation',
537 '-framework IOKit',
538 '-framework Security',
539 '-framework SystemConfiguration',
540 ],
541 },
542 },
543 },
544 'conditions': [
545 ['target_arch=="ia32"', {
546 'all_dependent_settings': {
547 'link_settings': {
548 'xcode_settings': {
549 'OTHER_LDFLAGS': [
550 '-framework Carbon',
551 ],
552 },
553 },
554 },
555 }],
556 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000557 }],
kjellander@webrtc.org03d45b02016-05-20 09:52:43 +0200558 ['OS=="win" and nacl_untrusted_build==0', {
kjellandera8a7ef62016-04-05 08:13:31 -0700559 'sources': [
560 'win32.cc',
561 'win32.h',
562 'win32filesystem.cc',
563 'win32filesystem.h',
564 'win32securityerrors.cc',
565 'win32window.cc',
566 'win32window.h',
567 'win32windowpicker.cc',
568 'win32windowpicker.h',
569 'winfirewall.cc',
570 'winfirewall.h',
571 'winping.cc',
572 'winping.h',
Guo-wei Shieh9faf1542015-12-28 14:06:55 -0800573 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000574 'link_settings': {
575 'libraries': [
576 '-lcrypt32.lib',
577 '-liphlpapi.lib',
578 '-lsecur32.lib',
579 ],
580 },
581 # Suppress warnings about WIN32_LEAN_AND_MEAN.
582 'msvs_disabled_warnings': [4005, 4703],
583 'defines': [
584 '_CRT_NONSTDC_NO_DEPRECATE',
585 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000586 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700587 ['os_posix==1', {
588 'sources': [
589 'ifaddrs_converter.cc',
590 'ifaddrs_converter.h',
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000591 'unixfilesystem.cc',
592 'unixfilesystem.h',
593 ],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000594 'configurations': {
595 'Debug_Base': {
596 'defines': [
597 # Chromium's build/common.gypi defines this for all posix
598 # _except_ for ios & mac. We want it there as well, e.g.
599 # because ASSERT and friends trigger off of it.
600 '_DEBUG',
601 ],
602 },
603 }
604 }],
605 ['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
606 'defines': [
607 'CARBON_DEPRECATED=YES',
608 ],
609 }],
kjellandera8a7ef62016-04-05 08:13:31 -0700610 ['OS=="linux" or OS=="android"', {
611 'sources': [
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000612 'linux.cc',
613 'linux.h',
614 ],
615 }],
torbjorng07d09362015-09-22 11:58:04 -0700616 ['build_ssl==1', {
617 'dependencies': [
618 '<(DEPTH)/third_party/boringssl/boringssl.gyp:boringssl',
619 ],
620 }, {
621 'include_dirs': [
622 '<(ssl_root)',
623 ],
624 }],
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000625 ],
626 },
kjellander988d31e2016-02-05 00:23:50 -0800627 {
628 'target_name': 'gtest_prod',
629 'type': 'static_library',
630 'sources': [
631 'gtest_prod_util.h',
632 ],
633 },
henrike@webrtc.orgf0488722014-05-13 18:00:26 +0000634 ],
635}