Revert of Revert of Add explicit support for discovering the GpuProcess to Telemetry...
[chromium-blink-merge.git] / third_party / libjingle / libjingle_nacl.gyp
blob3802aef1ee5226159bc352035d6b60cbe3c508da
1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6   'variables': {
7     'libjingle_source': "source",
8     'webrtc_base': "../webrtc/base",
9     'webrtc_xmllite': "../webrtc/libjingle/xmllite",
10     'webrtc_p2p': "../webrtc/p2p",
11   },
12   'includes': [
13     '../../native_client/build/untrusted.gypi',
14   ],
15   'targets': [
16     {
17       'target_name': 'libjingle_nacl',
18       'type': 'none',
19       'variables': {
20         'nlib_target': 'libjingle_nacl.a',
21         'nacl_untrusted_build': 1,
22         'build_glibc': 0,
23         'build_newlib': 0,
24         'build_pnacl_newlib': 1,
25         'use_openssl': 1,
26       },
27       'dependencies': [
28         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
29         '<(DEPTH)/native_client_sdk/native_client_sdk_untrusted.gyp:nacl_io_untrusted',
30         '<(DEPTH)/third_party/expat/expat_nacl.gyp:expat_nacl',
31         '<(DEPTH)/third_party/boringssl/boringssl_nacl.gyp:boringssl_nacl',
32         'libjingle_p2p_constants_nacl',
33       ],
34       'defines': [
35         'EXPAT_RELATIVE_PATH',
36         'FEATURE_ENABLE_SSL',
37         'GTEST_RELATIVE_PATH',
38         'HAVE_OPENSSL_SSL_H',
39         'NO_MAIN_THREAD_WRAPPING',
40         'NO_SOUND_SYSTEM',
41         'POSIX',
42         'WEBRTC_POSIX',
43         'SRTP_RELATIVE_PATH',
44         'SSL_USE_OPENSSL',
45         'USE_WEBRTC_DEV_BRANCH',
46         'timezone=_timezone',
47       ],
48       'configurations': {
49         'Debug': {
50           'defines': [
51             # TODO(sergeyu): Fix libjingle to use NDEBUG instead of
52             # _DEBUG and remove this define. See below as well.
53             '_DEBUG',
54           ],
55         }
56       },
57       'include_dirs': [
58         './<(libjingle_source)',
59         '../',
60       ],
61       'includes': ['libjingle_common.gypi', ],
62       'sources': [
63         '<(webrtc_base)/asyncfile.cc',
64         '<(webrtc_base)/asyncfile.h',
65         '<(webrtc_base)/asynchttprequest.cc',
66         '<(webrtc_base)/asynchttprequest.h',
67         '<(webrtc_base)/asyncpacketsocket.h',
68         '<(webrtc_base)/asyncsocket.cc',
69         '<(webrtc_base)/asyncsocket.h',
70         '<(webrtc_base)/asynctcpsocket.cc',
71         '<(webrtc_base)/asynctcpsocket.h',
72         '<(webrtc_base)/asyncudpsocket.cc',
73         '<(webrtc_base)/asyncudpsocket.h',
74         '<(webrtc_base)/autodetectproxy.cc',
75         '<(webrtc_base)/autodetectproxy.h',
76         '<(webrtc_base)/base64.cc',
77         '<(webrtc_base)/base64.h',
78         '<(webrtc_base)/basicdefs.h',
79         '<(webrtc_base)/bytebuffer.cc',
80         '<(webrtc_base)/bytebuffer.h',
81         '<(webrtc_base)/byteorder.h',
82         '<(webrtc_base)/checks.cc',
83         '<(webrtc_base)/checks.h',
84         '<(webrtc_base)/common.cc',
85         '<(webrtc_base)/common.h',
86         '<(webrtc_base)/compile_assert.h',
87         '<(webrtc_base)/cpumonitor.cc',
88         '<(webrtc_base)/cpumonitor.h',
89         '<(webrtc_base)/crc32.cc',
90         '<(webrtc_base)/crc32.h',
91         '<(webrtc_base)/criticalsection.h',
92         '<(webrtc_base)/cryptstring.h',
93         '<(webrtc_base)/diskcache.cc',
94         '<(webrtc_base)/diskcache.h',
95         '<(webrtc_base)/dscp.h',
96         '<(webrtc_base)/event.cc',
97         '<(webrtc_base)/event.h',
98         '<(webrtc_base)/fileutils.cc',
99         '<(webrtc_base)/fileutils.h',
100         '<(webrtc_base)/firewallsocketserver.cc',
101         '<(webrtc_base)/firewallsocketserver.h',
102         '<(webrtc_base)/flags.cc',
103         '<(webrtc_base)/flags.h',
104         '<(webrtc_base)/helpers.cc',
105         '<(webrtc_base)/helpers.h',
106         '<(webrtc_base)/httpbase.cc',
107         '<(webrtc_base)/httpbase.h',
108         '<(webrtc_base)/httpclient.cc',
109         '<(webrtc_base)/httpclient.h',
110         '<(webrtc_base)/httpcommon-inl.h',
111         '<(webrtc_base)/httpcommon.cc',
112         '<(webrtc_base)/httpcommon.h',
113         '<(webrtc_base)/httprequest.cc',
114         '<(webrtc_base)/httprequest.h',
115         '<(webrtc_base)/ipaddress.cc',
116         '<(webrtc_base)/ipaddress.h',
117         '<(webrtc_base)/linked_ptr.h',
118         '<(webrtc_base)/logging.cc',
119         '<(webrtc_base)/logging.h',
120         '<(webrtc_base)/maccocoathreadhelper.h',
121         '<(webrtc_base)/maccocoathreadhelper.mm',
122         '<(webrtc_base)/macconversion.cc',
123         '<(webrtc_base)/macconversion.h',
124         '<(webrtc_base)/macutils.cc',
125         '<(webrtc_base)/macutils.h',
126         '<(webrtc_base)/md5.cc',
127         '<(webrtc_base)/md5.h',
128         '<(webrtc_base)/md5digest.h',
129         '<(webrtc_base)/messagedigest.cc',
130         '<(webrtc_base)/messagedigest.h',
131         '<(webrtc_base)/messagehandler.cc',
132         '<(webrtc_base)/messagehandler.h',
133         '<(webrtc_base)/messagequeue.cc',
134         '<(webrtc_base)/messagequeue.h',
135         '<(webrtc_base)/move.h',
136         '<(webrtc_base)/nethelpers.cc',
137         '<(webrtc_base)/nethelpers.h',
138         '<(webrtc_base)/network.cc',
139         '<(webrtc_base)/network.h',
140         '<(webrtc_base)/nssidentity.cc',
141         '<(webrtc_base)/nssidentity.h',
142         '<(webrtc_base)/nssstreamadapter.cc',
143         '<(webrtc_base)/nssstreamadapter.h',
144         '<(webrtc_base)/nullsocketserver.h',
145         '<(webrtc_base)/openssladapter.cc',
146         '<(webrtc_base)/openssldigest.cc',
147         '<(webrtc_base)/opensslidentity.cc',
148         '<(webrtc_base)/opensslstreamadapter.cc',
149         '<(webrtc_base)/pathutils.cc',
150         '<(webrtc_base)/pathutils.h',
151         '<(webrtc_base)/physicalsocketserver.cc',
152         '<(webrtc_base)/physicalsocketserver.h',
153         '<(webrtc_base)/proxydetect.cc',
154         '<(webrtc_base)/proxydetect.h',
155         '<(webrtc_base)/proxyinfo.cc',
156         '<(webrtc_base)/proxyinfo.h',
157         '<(webrtc_base)/ratelimiter.cc',
158         '<(webrtc_base)/ratelimiter.h',
159         '<(webrtc_base)/ratetracker.cc',
160         '<(webrtc_base)/ratetracker.h',
161         '<(webrtc_base)/schanneladapter.cc',
162         '<(webrtc_base)/schanneladapter.h',
163         '<(webrtc_base)/scoped_autorelease_pool.h',
164         '<(webrtc_base)/scoped_autorelease_pool.mm',
165         '<(webrtc_base)/scoped_ptr.h',
166         '<(webrtc_base)/sec_buffer.h',
167         '<(webrtc_base)/sha1.cc',
168         '<(webrtc_base)/sha1.h',
169         '<(webrtc_base)/sha1digest.h',
170         '<(webrtc_base)/signalthread.cc',
171         '<(webrtc_base)/signalthread.h',
172         '<(webrtc_base)/sigslot.h',
173         '<(webrtc_base)/sigslotrepeater.h',
174         '<(webrtc_base)/socket.h',
175         '<(webrtc_base)/socketadapters.cc',
176         '<(webrtc_base)/socketadapters.h',
177         '<(webrtc_base)/socketaddress.cc',
178         '<(webrtc_base)/socketaddress.h',
179         '<(webrtc_base)/socketaddresspair.cc',
180         '<(webrtc_base)/socketaddresspair.h',
181         '<(webrtc_base)/socketfactory.h',
182         '<(webrtc_base)/socketpool.cc',
183         '<(webrtc_base)/socketpool.h',
184         '<(webrtc_base)/socketserver.h',
185         '<(webrtc_base)/socketstream.cc',
186         '<(webrtc_base)/socketstream.h',
187         '<(webrtc_base)/ssladapter.cc',
188         '<(webrtc_base)/ssladapter.h',
189         '<(webrtc_base)/sslfingerprint.cc',
190         '<(webrtc_base)/sslfingerprint.h',
191         '<(webrtc_base)/sslidentity.cc',
192         '<(webrtc_base)/sslidentity.h',
193         '<(webrtc_base)/sslsocketfactory.cc',
194         '<(webrtc_base)/sslsocketfactory.h',
195         '<(webrtc_base)/sslstreamadapter.cc',
196         '<(webrtc_base)/sslstreamadapter.h',
197         '<(webrtc_base)/sslstreamadapterhelper.cc',
198         '<(webrtc_base)/sslstreamadapterhelper.h',
199         '<(webrtc_base)/stream.cc',
200         '<(webrtc_base)/stream.h',
201         '<(webrtc_base)/stringencode.cc',
202         '<(webrtc_base)/stringencode.h',
203         '<(webrtc_base)/stringutils.cc',
204         '<(webrtc_base)/stringutils.h',
205         '<(webrtc_base)/task.cc',
206         '<(webrtc_base)/task.h',
207         '<(webrtc_base)/taskparent.cc',
208         '<(webrtc_base)/taskparent.h',
209         '<(webrtc_base)/taskrunner.cc',
210         '<(webrtc_base)/taskrunner.h',
211         '<(webrtc_base)/template_util.h',
212         '<(webrtc_base)/thread.cc',
213         '<(webrtc_base)/thread.h',
214         '<(webrtc_base)/timeutils.cc',
215         '<(webrtc_base)/timeutils.h',
216         '<(webrtc_base)/timing.cc',
217         '<(webrtc_base)/timing.h',
218         '<(webrtc_base)/unixfilesystem.cc',
219         '<(webrtc_base)/unixfilesystem.h',
220         '<(webrtc_base)/urlencode.cc',
221         '<(webrtc_base)/urlencode.h',
222         '<(webrtc_base)/win32.cc',
223         '<(webrtc_base)/win32.h',
224         '<(webrtc_base)/win32filesystem.cc',
225         '<(webrtc_base)/win32filesystem.h',
226         '<(webrtc_base)/win32securityerrors.cc',
227         '<(webrtc_base)/win32window.cc',
228         '<(webrtc_base)/win32window.h',
229         '<(webrtc_base)/winfirewall.cc',
230         '<(webrtc_base)/winfirewall.h',
231         '<(webrtc_base)/winping.cc',
232         '<(webrtc_base)/winping.h',
233         '<(webrtc_base)/worker.cc',
234         '<(webrtc_base)/worker.h',
235         '<(webrtc_xmllite)/qname.cc',
236         '<(webrtc_xmllite)/qname.h',
237         '<(webrtc_xmllite)/xmlbuilder.cc',
238         '<(webrtc_xmllite)/xmlbuilder.h',
239         '<(webrtc_xmllite)/xmlconstants.cc',
240         '<(webrtc_xmllite)/xmlconstants.h',
241         '<(webrtc_xmllite)/xmlelement.cc',
242         '<(webrtc_xmllite)/xmlelement.h',
243         '<(webrtc_xmllite)/xmlnsstack.cc',
244         '<(webrtc_xmllite)/xmlnsstack.h',
245         '<(webrtc_xmllite)/xmlparser.cc',
246         '<(webrtc_xmllite)/xmlparser.h',
247         '<(webrtc_xmllite)/xmlprinter.cc',
248         '<(webrtc_xmllite)/xmlprinter.h',
249       ],
250       'sources!': [
251         # Compiled as part of libjingle_p2p_constants_nacl.
252         '<(webrtc_p2p)/base/constants.cc',
253         '<(webrtc_p2p)/base/constants.h',
254       ],
255       'sources/': [
256         ['exclude', '/mac[a-z]+\\.(h|cc)$'],
257         ['exclude', '/scoped_autorelease_pool\\.(h|mm)$'],
258       ],
259       'conditions': [
260         ['OS!="win"', {
261           'sources/': [
262             ['exclude', '/win[a-z0-9]+\\.(h|cc)$'],
263             ['exclude', '/schanneladapter\\.(h|cc)$'],
264           ],
265         }],
266       ],
267       'direct_dependent_settings': {
268         'include_dirs': [
269           './overrides',
270           './<(libjingle_source)',
271           '../../third_party/webrtc/overrides',
272           '../../third_party',
273           '../../third_party/webrtc',
274         ],
275         'defines': [
276           'EXPAT_RELATIVE_PATH',
277           'FEATURE_ENABLE_SSL',
278           'GTEST_RELATIVE_PATH',
279           'NO_MAIN_THREAD_WRAPPING',
280           'NO_SOUND_SYSTEM',
281           'POSIX',
282           'WEBRTC_POSIX',
283           'SRTP_RELATIVE_PATH',
284           'SSL_USE_OPENSSL',
285           'USE_WEBRTC_DEV_BRANCH',
286         ],
287       },
288       'export_dependent_settings': [
289         '<(DEPTH)/native_client_sdk/native_client_sdk_untrusted.gyp:nacl_io_untrusted',
290       ],
291     },  # end of target 'libjingle_nacl'
293     {
294       'target_name': 'libjingle_p2p_constants_nacl',
295       'type': 'none',
296       'variables': {
297         'nlib_target': 'libjingle_p2p_constants_nacl.a',
298         'build_glibc': 0,
299         'build_newlib': 1,
300         'build_pnacl_newlib': 1,
301       },
302       'configurations': {
303         'Debug': {
304           'defines': [
305             # TODO(sergeyu): Fix libjingle to use NDEBUG instead of
306             # _DEBUG and remove this define. See below as well.
307             '_DEBUG',
308           ],
309         }
310       },
311       'include_dirs': [
312         './<(libjingle_source)',
313         '../'
314       ],
315       'sources': [
316         '<(webrtc_p2p)/base/constants.cc',
317         '<(webrtc_p2p)/base/constants.h',
318       ],
319     },  # end of target 'libjingle_p2p_constants_nacl'
320   ],