blob: 2ee383a95c7fc11bbbbbf0eb0b6f84af9e3a4a5d [file] [log] [blame]
murgatroid99fd994f12015-10-09 14:02:28 -07001# GRPC Node gyp file
2# This currently builds the Node extension and dependencies
3# This file has been automatically generated from a template file.
4# Please look at the templates directory instead.
5# This file can be regenerated from the template by running
6# tools/buildgen/generate_projects.sh
7
murgatroid997586db82016-01-20 14:02:42 -08008# Copyright 2015-2016, Google Inc.
murgatroid99f33b1322015-10-05 09:45:04 -07009# All rights reserved.
10#
11# Redistribution and use in source and binary forms, with or without
12# modification, are permitted provided that the following conditions are
13# met:
14#
15# * Redistributions of source code must retain the above copyright
16# notice, this list of conditions and the following disclaimer.
17# * Redistributions in binary form must reproduce the above
18# copyright notice, this list of conditions and the following disclaimer
19# in the documentation and/or other materials provided with the
20# distribution.
21# * Neither the name of Google Inc. nor the names of its
22# contributors may be used to endorse or promote products derived from
23# this software without specific prior written permission.
24#
25# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
26# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
27# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
28# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
29# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
30# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
31# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
32# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
murgatroid99fd994f12015-10-09 14:02:28 -070036
37# Some of this file is built with the help of
38# https://n8.io/converting-a-c-library-to-gyp/
murgatroid992af89e42015-10-01 11:54:00 -070039{
murgatroid99fd994f12015-10-09 14:02:28 -070040 'target_defaults': {
murgatroid99fd994f12015-10-09 14:02:28 -070041 'include_dirs': [
42 '.',
murgatroid995c56c922016-01-25 13:32:52 -080043 'include'
murgatroid99a89d9e72015-10-13 16:03:16 -070044 ],
45 'conditions': [
murgatroid995c56c922016-01-25 13:32:52 -080046 ['OS == "win"', {
murgatroid99673f65b2016-02-01 11:19:07 -080047 "include_dirs": [
48 "third_party/boringssl/include",
49 "third_party/zlib"
50 ],
Michael Lumishe2f34652016-01-27 16:41:54 -080051 "defines": [
52 '_WIN32_WINNT=0x0600',
53 'WIN32_LEAN_AND_MEAN',
54 '_HAS_EXCEPTIONS=0',
55 'UNICODE',
56 '_UNICODE',
57 'NOMINMAX',
Craig Tiller71ea4a12016-02-04 15:06:41 -080058 'OPENSSL_NO_ASM',
59 'GPR_BACKWARDS_COMPATIBILITY_MODE'
Michael Lumishe2f34652016-01-27 16:41:54 -080060 ],
61 "msvs_settings": {
62 'VCCLCompilerTool': {
63 'RuntimeLibrary': 1, # static debug
64 }
65 },
66 "libraries": [
67 "ws2_32"
68 ]
69 }, { # OS != "win"
murgatroid99673f65b2016-02-01 11:19:07 -080070 'variables': {
71 'config': '<!(echo $CONFIG)',
72 # The output of "node --version" is "v[version]". We use cut to
73 # remove the first character.
74 'target%': '<!(node --version | cut -c2-)'
75 },
murgatroid99af6c1782016-01-28 13:14:24 -080076 # Empirically, Node only exports ALPN symbols if its major version is >0.
77 # io.js always reports versions >0 and always exports ALPN symbols.
78 # Therefore, Node's major version will be truthy if and only if it
murgatroid99673f65b2016-02-01 11:19:07 -080079 # supports ALPN. The target is "[major].[minor].[patch]". We split by
80 # periods and take the first field to get the major version.
murgatroid99af6c1782016-01-28 13:14:24 -080081 'defines': [
Craig Tiller71ea4a12016-02-04 15:06:41 -080082 'TSI_OPENSSL_ALPN_SUPPORT=<!(echo <(target) | cut -d. -f1)',
83 'GPR_BACKWARDS_COMPATIBILITY_MODE'
murgatroid99af6c1782016-01-28 13:14:24 -080084 ],
murgatroid995c56c922016-01-25 13:32:52 -080085 'include_dirs': [
86 '<(node_root_dir)/deps/openssl/openssl/include',
87 '<(node_root_dir)/deps/zlib'
88 ],
murgatroid99a89d9e72015-10-13 16:03:16 -070089 'conditions': [
90 ['config=="gcov"', {
91 'cflags': [
92 '-ftest-coverage',
93 '-fprofile-arcs',
94 '-O0'
95 ],
96 'ldflags': [
97 '-ftest-coverage',
98 '-fprofile-arcs'
99 ]
100 }
murgatroid995c56c922016-01-25 13:32:52 -0800101 ],
102 ["target_arch=='ia32'", {
103 "include_dirs": [ "<(node_root_dir)/deps/openssl/config/piii" ]
104 }],
105 ["target_arch=='x64'", {
106 "include_dirs": [ "<(node_root_dir)/deps/openssl/config/k8" ]
107 }],
108 ["target_arch=='arm'", {
109 "include_dirs": [ "<(node_root_dir)/deps/openssl/config/arm" ]
110 }]
murgatroid99a89d9e72015-10-13 16:03:16 -0700111 ]
murgatroid99afe46982015-10-23 10:17:26 -0700112 }]
murgatroid99fd994f12015-10-09 14:02:28 -0700113 ]
114 },
murgatroid995c56c922016-01-25 13:32:52 -0800115 'conditions': [
116 ['OS == "win"', {
117 'targets': [
murgatroid99af6c1782016-01-28 13:14:24 -0800118 {
119 # IMPORTANT WINDOWS BUILD INFORMATION
120 # This library does not build on Windows without modifying the Node
121 # development packages that node-gyp downloads in order to build.
122 # Due to https://github.com/nodejs/node/issues/4932, the headers for
123 # BoringSSL conflict with the OpenSSL headers included by default
124 # when including the Node headers. The remedy for this is to remove
125 # the OpenSSL headers, from the downloaded Node development package,
126 # which is typically located in `.node-gyp` in your home directory.
murgatroid998e4103e2016-01-28 14:53:33 -0800127 'target_name': 'WINDOWS_BUILD_WARNING',
murgatroid99af6c1782016-01-28 13:14:24 -0800128 'actions': [
129 {
murgatroid998e4103e2016-01-28 14:53:33 -0800130 'action_name': 'WINDOWS_BUILD_WARNING',
131 'inputs': [
132 'package.json'
133 ],
134 'outputs': [
135 'ignore_this_part'
136 ],
137 'action': ['echo', 'IMPORTANT: Due to https://github.com/nodejs/node/issues/4932, to build this library on Windows, you must first remove <(node_root_dir)/include/node/openssl/']
murgatroid99af6c1782016-01-28 13:14:24 -0800138 }
139 ]
140 },
murgatroid995c56c922016-01-25 13:32:52 -0800141 # Only want to compile BoringSSL and zlib under Windows
142 {
143 'cflags': [
144 '-std=c99',
145 '-Wall',
146 '-Werror'
147 ],
148 'target_name': 'boringssl',
149 'product_prefix': 'lib',
150 'type': 'static_library',
151 'dependencies': [
152 ],
153 'sources': [
154 'src/boringssl/err_data.c',
155 'third_party/boringssl/crypto/aes/aes.c',
156 'third_party/boringssl/crypto/aes/mode_wrappers.c',
157 'third_party/boringssl/crypto/asn1/a_bitstr.c',
158 'third_party/boringssl/crypto/asn1/a_bool.c',
159 'third_party/boringssl/crypto/asn1/a_bytes.c',
160 'third_party/boringssl/crypto/asn1/a_d2i_fp.c',
161 'third_party/boringssl/crypto/asn1/a_dup.c',
162 'third_party/boringssl/crypto/asn1/a_enum.c',
163 'third_party/boringssl/crypto/asn1/a_gentm.c',
164 'third_party/boringssl/crypto/asn1/a_i2d_fp.c',
165 'third_party/boringssl/crypto/asn1/a_int.c',
166 'third_party/boringssl/crypto/asn1/a_mbstr.c',
167 'third_party/boringssl/crypto/asn1/a_object.c',
168 'third_party/boringssl/crypto/asn1/a_octet.c',
169 'third_party/boringssl/crypto/asn1/a_print.c',
170 'third_party/boringssl/crypto/asn1/a_strnid.c',
171 'third_party/boringssl/crypto/asn1/a_time.c',
172 'third_party/boringssl/crypto/asn1/a_type.c',
173 'third_party/boringssl/crypto/asn1/a_utctm.c',
174 'third_party/boringssl/crypto/asn1/a_utf8.c',
175 'third_party/boringssl/crypto/asn1/asn1_lib.c',
176 'third_party/boringssl/crypto/asn1/asn1_par.c',
177 'third_party/boringssl/crypto/asn1/asn_pack.c',
178 'third_party/boringssl/crypto/asn1/bio_asn1.c',
179 'third_party/boringssl/crypto/asn1/bio_ndef.c',
180 'third_party/boringssl/crypto/asn1/f_enum.c',
181 'third_party/boringssl/crypto/asn1/f_int.c',
182 'third_party/boringssl/crypto/asn1/f_string.c',
183 'third_party/boringssl/crypto/asn1/t_bitst.c',
184 'third_party/boringssl/crypto/asn1/t_pkey.c',
185 'third_party/boringssl/crypto/asn1/tasn_dec.c',
186 'third_party/boringssl/crypto/asn1/tasn_enc.c',
187 'third_party/boringssl/crypto/asn1/tasn_fre.c',
188 'third_party/boringssl/crypto/asn1/tasn_new.c',
189 'third_party/boringssl/crypto/asn1/tasn_prn.c',
190 'third_party/boringssl/crypto/asn1/tasn_typ.c',
191 'third_party/boringssl/crypto/asn1/tasn_utl.c',
192 'third_party/boringssl/crypto/asn1/x_bignum.c',
193 'third_party/boringssl/crypto/asn1/x_long.c',
194 'third_party/boringssl/crypto/base64/base64.c',
195 'third_party/boringssl/crypto/bio/bio.c',
196 'third_party/boringssl/crypto/bio/bio_mem.c',
197 'third_party/boringssl/crypto/bio/buffer.c',
198 'third_party/boringssl/crypto/bio/connect.c',
199 'third_party/boringssl/crypto/bio/fd.c',
200 'third_party/boringssl/crypto/bio/file.c',
201 'third_party/boringssl/crypto/bio/hexdump.c',
202 'third_party/boringssl/crypto/bio/pair.c',
203 'third_party/boringssl/crypto/bio/printf.c',
204 'third_party/boringssl/crypto/bio/socket.c',
205 'third_party/boringssl/crypto/bio/socket_helper.c',
206 'third_party/boringssl/crypto/bn/add.c',
207 'third_party/boringssl/crypto/bn/asm/x86_64-gcc.c',
208 'third_party/boringssl/crypto/bn/bn.c',
209 'third_party/boringssl/crypto/bn/bn_asn1.c',
210 'third_party/boringssl/crypto/bn/cmp.c',
211 'third_party/boringssl/crypto/bn/convert.c',
212 'third_party/boringssl/crypto/bn/ctx.c',
213 'third_party/boringssl/crypto/bn/div.c',
214 'third_party/boringssl/crypto/bn/exponentiation.c',
215 'third_party/boringssl/crypto/bn/gcd.c',
216 'third_party/boringssl/crypto/bn/generic.c',
217 'third_party/boringssl/crypto/bn/kronecker.c',
218 'third_party/boringssl/crypto/bn/montgomery.c',
219 'third_party/boringssl/crypto/bn/mul.c',
220 'third_party/boringssl/crypto/bn/prime.c',
221 'third_party/boringssl/crypto/bn/random.c',
222 'third_party/boringssl/crypto/bn/rsaz_exp.c',
223 'third_party/boringssl/crypto/bn/shift.c',
224 'third_party/boringssl/crypto/bn/sqrt.c',
225 'third_party/boringssl/crypto/buf/buf.c',
226 'third_party/boringssl/crypto/bytestring/ber.c',
227 'third_party/boringssl/crypto/bytestring/cbb.c',
228 'third_party/boringssl/crypto/bytestring/cbs.c',
229 'third_party/boringssl/crypto/chacha/chacha_generic.c',
230 'third_party/boringssl/crypto/chacha/chacha_vec.c',
231 'third_party/boringssl/crypto/cipher/aead.c',
232 'third_party/boringssl/crypto/cipher/cipher.c',
233 'third_party/boringssl/crypto/cipher/derive_key.c',
234 'third_party/boringssl/crypto/cipher/e_aes.c',
235 'third_party/boringssl/crypto/cipher/e_chacha20poly1305.c',
236 'third_party/boringssl/crypto/cipher/e_des.c',
237 'third_party/boringssl/crypto/cipher/e_null.c',
238 'third_party/boringssl/crypto/cipher/e_rc2.c',
239 'third_party/boringssl/crypto/cipher/e_rc4.c',
240 'third_party/boringssl/crypto/cipher/e_ssl3.c',
241 'third_party/boringssl/crypto/cipher/e_tls.c',
242 'third_party/boringssl/crypto/cipher/tls_cbc.c',
243 'third_party/boringssl/crypto/cmac/cmac.c',
244 'third_party/boringssl/crypto/conf/conf.c',
245 'third_party/boringssl/crypto/cpu-arm.c',
246 'third_party/boringssl/crypto/cpu-intel.c',
247 'third_party/boringssl/crypto/crypto.c',
248 'third_party/boringssl/crypto/curve25519/curve25519.c',
249 'third_party/boringssl/crypto/des/des.c',
250 'third_party/boringssl/crypto/dh/check.c',
251 'third_party/boringssl/crypto/dh/dh.c',
252 'third_party/boringssl/crypto/dh/dh_asn1.c',
253 'third_party/boringssl/crypto/dh/params.c',
254 'third_party/boringssl/crypto/digest/digest.c',
255 'third_party/boringssl/crypto/digest/digests.c',
256 'third_party/boringssl/crypto/directory_posix.c',
257 'third_party/boringssl/crypto/directory_win.c',
258 'third_party/boringssl/crypto/dsa/dsa.c',
259 'third_party/boringssl/crypto/dsa/dsa_asn1.c',
260 'third_party/boringssl/crypto/ec/ec.c',
261 'third_party/boringssl/crypto/ec/ec_asn1.c',
262 'third_party/boringssl/crypto/ec/ec_key.c',
263 'third_party/boringssl/crypto/ec/ec_montgomery.c',
264 'third_party/boringssl/crypto/ec/oct.c',
265 'third_party/boringssl/crypto/ec/p224-64.c',
266 'third_party/boringssl/crypto/ec/p256-64.c',
267 'third_party/boringssl/crypto/ec/p256-x86_64.c',
268 'third_party/boringssl/crypto/ec/simple.c',
269 'third_party/boringssl/crypto/ec/util-64.c',
270 'third_party/boringssl/crypto/ec/wnaf.c',
271 'third_party/boringssl/crypto/ecdh/ecdh.c',
272 'third_party/boringssl/crypto/ecdsa/ecdsa.c',
273 'third_party/boringssl/crypto/ecdsa/ecdsa_asn1.c',
274 'third_party/boringssl/crypto/engine/engine.c',
275 'third_party/boringssl/crypto/err/err.c',
276 'third_party/boringssl/crypto/evp/algorithm.c',
277 'third_party/boringssl/crypto/evp/digestsign.c',
278 'third_party/boringssl/crypto/evp/evp.c',
279 'third_party/boringssl/crypto/evp/evp_asn1.c',
280 'third_party/boringssl/crypto/evp/evp_ctx.c',
281 'third_party/boringssl/crypto/evp/p_dsa_asn1.c',
282 'third_party/boringssl/crypto/evp/p_ec.c',
283 'third_party/boringssl/crypto/evp/p_ec_asn1.c',
284 'third_party/boringssl/crypto/evp/p_rsa.c',
285 'third_party/boringssl/crypto/evp/p_rsa_asn1.c',
286 'third_party/boringssl/crypto/evp/pbkdf.c',
287 'third_party/boringssl/crypto/evp/sign.c',
288 'third_party/boringssl/crypto/ex_data.c',
289 'third_party/boringssl/crypto/hkdf/hkdf.c',
290 'third_party/boringssl/crypto/hmac/hmac.c',
291 'third_party/boringssl/crypto/lhash/lhash.c',
292 'third_party/boringssl/crypto/md4/md4.c',
293 'third_party/boringssl/crypto/md5/md5.c',
294 'third_party/boringssl/crypto/mem.c',
295 'third_party/boringssl/crypto/modes/cbc.c',
296 'third_party/boringssl/crypto/modes/cfb.c',
297 'third_party/boringssl/crypto/modes/ctr.c',
298 'third_party/boringssl/crypto/modes/gcm.c',
299 'third_party/boringssl/crypto/modes/ofb.c',
300 'third_party/boringssl/crypto/obj/obj.c',
301 'third_party/boringssl/crypto/obj/obj_xref.c',
302 'third_party/boringssl/crypto/pem/pem_all.c',
303 'third_party/boringssl/crypto/pem/pem_info.c',
304 'third_party/boringssl/crypto/pem/pem_lib.c',
305 'third_party/boringssl/crypto/pem/pem_oth.c',
306 'third_party/boringssl/crypto/pem/pem_pk8.c',
307 'third_party/boringssl/crypto/pem/pem_pkey.c',
308 'third_party/boringssl/crypto/pem/pem_x509.c',
309 'third_party/boringssl/crypto/pem/pem_xaux.c',
310 'third_party/boringssl/crypto/pkcs8/p5_pbe.c',
311 'third_party/boringssl/crypto/pkcs8/p5_pbev2.c',
312 'third_party/boringssl/crypto/pkcs8/p8_pkey.c',
313 'third_party/boringssl/crypto/pkcs8/pkcs8.c',
314 'third_party/boringssl/crypto/poly1305/poly1305.c',
315 'third_party/boringssl/crypto/poly1305/poly1305_arm.c',
316 'third_party/boringssl/crypto/poly1305/poly1305_vec.c',
317 'third_party/boringssl/crypto/rand/rand.c',
318 'third_party/boringssl/crypto/rand/urandom.c',
319 'third_party/boringssl/crypto/rand/windows.c',
320 'third_party/boringssl/crypto/rc4/rc4.c',
321 'third_party/boringssl/crypto/refcount_c11.c',
322 'third_party/boringssl/crypto/refcount_lock.c',
323 'third_party/boringssl/crypto/rsa/blinding.c',
324 'third_party/boringssl/crypto/rsa/padding.c',
325 'third_party/boringssl/crypto/rsa/rsa.c',
326 'third_party/boringssl/crypto/rsa/rsa_asn1.c',
327 'third_party/boringssl/crypto/rsa/rsa_impl.c',
328 'third_party/boringssl/crypto/sha/sha1.c',
329 'third_party/boringssl/crypto/sha/sha256.c',
330 'third_party/boringssl/crypto/sha/sha512.c',
331 'third_party/boringssl/crypto/stack/stack.c',
332 'third_party/boringssl/crypto/thread.c',
333 'third_party/boringssl/crypto/thread_none.c',
334 'third_party/boringssl/crypto/thread_pthread.c',
335 'third_party/boringssl/crypto/thread_win.c',
336 'third_party/boringssl/crypto/time_support.c',
337 'third_party/boringssl/crypto/x509/a_digest.c',
338 'third_party/boringssl/crypto/x509/a_sign.c',
339 'third_party/boringssl/crypto/x509/a_strex.c',
340 'third_party/boringssl/crypto/x509/a_verify.c',
341 'third_party/boringssl/crypto/x509/asn1_gen.c',
342 'third_party/boringssl/crypto/x509/by_dir.c',
343 'third_party/boringssl/crypto/x509/by_file.c',
344 'third_party/boringssl/crypto/x509/i2d_pr.c',
345 'third_party/boringssl/crypto/x509/pkcs7.c',
346 'third_party/boringssl/crypto/x509/t_crl.c',
347 'third_party/boringssl/crypto/x509/t_req.c',
348 'third_party/boringssl/crypto/x509/t_x509.c',
349 'third_party/boringssl/crypto/x509/t_x509a.c',
350 'third_party/boringssl/crypto/x509/x509.c',
351 'third_party/boringssl/crypto/x509/x509_att.c',
352 'third_party/boringssl/crypto/x509/x509_cmp.c',
353 'third_party/boringssl/crypto/x509/x509_d2.c',
354 'third_party/boringssl/crypto/x509/x509_def.c',
355 'third_party/boringssl/crypto/x509/x509_ext.c',
356 'third_party/boringssl/crypto/x509/x509_lu.c',
357 'third_party/boringssl/crypto/x509/x509_obj.c',
358 'third_party/boringssl/crypto/x509/x509_r2x.c',
359 'third_party/boringssl/crypto/x509/x509_req.c',
360 'third_party/boringssl/crypto/x509/x509_set.c',
361 'third_party/boringssl/crypto/x509/x509_trs.c',
362 'third_party/boringssl/crypto/x509/x509_txt.c',
363 'third_party/boringssl/crypto/x509/x509_v3.c',
364 'third_party/boringssl/crypto/x509/x509_vfy.c',
365 'third_party/boringssl/crypto/x509/x509_vpm.c',
366 'third_party/boringssl/crypto/x509/x509cset.c',
367 'third_party/boringssl/crypto/x509/x509name.c',
368 'third_party/boringssl/crypto/x509/x509rset.c',
369 'third_party/boringssl/crypto/x509/x509spki.c',
370 'third_party/boringssl/crypto/x509/x509type.c',
371 'third_party/boringssl/crypto/x509/x_algor.c',
372 'third_party/boringssl/crypto/x509/x_all.c',
373 'third_party/boringssl/crypto/x509/x_attrib.c',
374 'third_party/boringssl/crypto/x509/x_crl.c',
375 'third_party/boringssl/crypto/x509/x_exten.c',
376 'third_party/boringssl/crypto/x509/x_info.c',
377 'third_party/boringssl/crypto/x509/x_name.c',
378 'third_party/boringssl/crypto/x509/x_pkey.c',
379 'third_party/boringssl/crypto/x509/x_pubkey.c',
380 'third_party/boringssl/crypto/x509/x_req.c',
381 'third_party/boringssl/crypto/x509/x_sig.c',
382 'third_party/boringssl/crypto/x509/x_spki.c',
383 'third_party/boringssl/crypto/x509/x_val.c',
384 'third_party/boringssl/crypto/x509/x_x509.c',
385 'third_party/boringssl/crypto/x509/x_x509a.c',
386 'third_party/boringssl/crypto/x509v3/pcy_cache.c',
387 'third_party/boringssl/crypto/x509v3/pcy_data.c',
388 'third_party/boringssl/crypto/x509v3/pcy_lib.c',
389 'third_party/boringssl/crypto/x509v3/pcy_map.c',
390 'third_party/boringssl/crypto/x509v3/pcy_node.c',
391 'third_party/boringssl/crypto/x509v3/pcy_tree.c',
392 'third_party/boringssl/crypto/x509v3/v3_akey.c',
393 'third_party/boringssl/crypto/x509v3/v3_akeya.c',
394 'third_party/boringssl/crypto/x509v3/v3_alt.c',
395 'third_party/boringssl/crypto/x509v3/v3_bcons.c',
396 'third_party/boringssl/crypto/x509v3/v3_bitst.c',
397 'third_party/boringssl/crypto/x509v3/v3_conf.c',
398 'third_party/boringssl/crypto/x509v3/v3_cpols.c',
399 'third_party/boringssl/crypto/x509v3/v3_crld.c',
400 'third_party/boringssl/crypto/x509v3/v3_enum.c',
401 'third_party/boringssl/crypto/x509v3/v3_extku.c',
402 'third_party/boringssl/crypto/x509v3/v3_genn.c',
403 'third_party/boringssl/crypto/x509v3/v3_ia5.c',
404 'third_party/boringssl/crypto/x509v3/v3_info.c',
405 'third_party/boringssl/crypto/x509v3/v3_int.c',
406 'third_party/boringssl/crypto/x509v3/v3_lib.c',
407 'third_party/boringssl/crypto/x509v3/v3_ncons.c',
408 'third_party/boringssl/crypto/x509v3/v3_pci.c',
409 'third_party/boringssl/crypto/x509v3/v3_pcia.c',
410 'third_party/boringssl/crypto/x509v3/v3_pcons.c',
411 'third_party/boringssl/crypto/x509v3/v3_pku.c',
412 'third_party/boringssl/crypto/x509v3/v3_pmaps.c',
413 'third_party/boringssl/crypto/x509v3/v3_prn.c',
414 'third_party/boringssl/crypto/x509v3/v3_purp.c',
415 'third_party/boringssl/crypto/x509v3/v3_skey.c',
416 'third_party/boringssl/crypto/x509v3/v3_sxnet.c',
417 'third_party/boringssl/crypto/x509v3/v3_utl.c',
418 'third_party/boringssl/ssl/custom_extensions.c',
419 'third_party/boringssl/ssl/d1_both.c',
420 'third_party/boringssl/ssl/d1_clnt.c',
421 'third_party/boringssl/ssl/d1_lib.c',
422 'third_party/boringssl/ssl/d1_meth.c',
423 'third_party/boringssl/ssl/d1_pkt.c',
424 'third_party/boringssl/ssl/d1_srtp.c',
425 'third_party/boringssl/ssl/d1_srvr.c',
426 'third_party/boringssl/ssl/dtls_record.c',
427 'third_party/boringssl/ssl/pqueue/pqueue.c',
428 'third_party/boringssl/ssl/s3_both.c',
429 'third_party/boringssl/ssl/s3_clnt.c',
430 'third_party/boringssl/ssl/s3_enc.c',
431 'third_party/boringssl/ssl/s3_lib.c',
432 'third_party/boringssl/ssl/s3_meth.c',
433 'third_party/boringssl/ssl/s3_pkt.c',
434 'third_party/boringssl/ssl/s3_srvr.c',
435 'third_party/boringssl/ssl/ssl_aead_ctx.c',
436 'third_party/boringssl/ssl/ssl_asn1.c',
437 'third_party/boringssl/ssl/ssl_buffer.c',
438 'third_party/boringssl/ssl/ssl_cert.c',
439 'third_party/boringssl/ssl/ssl_cipher.c',
440 'third_party/boringssl/ssl/ssl_file.c',
441 'third_party/boringssl/ssl/ssl_lib.c',
442 'third_party/boringssl/ssl/ssl_rsa.c',
443 'third_party/boringssl/ssl/ssl_session.c',
444 'third_party/boringssl/ssl/ssl_stat.c',
445 'third_party/boringssl/ssl/t1_enc.c',
446 'third_party/boringssl/ssl/t1_lib.c',
447 'third_party/boringssl/ssl/tls_record.c',
murgatroid99af6c1782016-01-28 13:14:24 -0800448 ]
murgatroid995c56c922016-01-25 13:32:52 -0800449 },
450 {
451 'cflags': [
452 '-std=c99',
453 '-Wall',
454 '-Werror'
455 ],
456 'target_name': 'z',
457 'product_prefix': 'lib',
458 'type': 'static_library',
459 'dependencies': [
460 ],
461 'sources': [
462 'third_party/zlib/adler32.c',
463 'third_party/zlib/compress.c',
464 'third_party/zlib/crc32.c',
465 'third_party/zlib/deflate.c',
466 'third_party/zlib/gzclose.c',
467 'third_party/zlib/gzlib.c',
468 'third_party/zlib/gzread.c',
469 'third_party/zlib/gzwrite.c',
470 'third_party/zlib/infback.c',
471 'third_party/zlib/inffast.c',
472 'third_party/zlib/inflate.c',
473 'third_party/zlib/inftrees.c',
474 'third_party/zlib/trees.c',
475 'third_party/zlib/uncompr.c',
476 'third_party/zlib/zutil.c',
murgatroid99af6c1782016-01-28 13:14:24 -0800477 ]
murgatroid995c56c922016-01-25 13:32:52 -0800478 },
479 ]
480 }]
481 ],
murgatroid99fd994f12015-10-09 14:02:28 -0700482 'targets': [
483 {
murgatroid993abed312016-01-07 17:16:46 -0800484 'cflags': [
485 '-std=c99',
486 '-Wall',
487 '-Werror'
488 ],
Craig Tillerda179ce2016-02-09 12:01:53 -0800489 'target_name': 'gpr',
490 'product_prefix': 'lib',
491 'type': 'static_library',
492 'dependencies': [
493 ],
494 'sources': [
495 'src/core/profiling/basic_timers.c',
496 'src/core/profiling/stap_timers.c',
497 'src/core/support/alloc.c',
498 'src/core/support/avl.c',
Craig Tillerc72cc422016-03-11 10:54:36 -0800499 'src/core/support/backoff.c',
Craig Tillerda179ce2016-02-09 12:01:53 -0800500 'src/core/support/cmdline.c',
501 'src/core/support/cpu_iphone.c',
502 'src/core/support/cpu_linux.c',
503 'src/core/support/cpu_posix.c',
504 'src/core/support/cpu_windows.c',
505 'src/core/support/env_linux.c',
506 'src/core/support/env_posix.c',
507 'src/core/support/env_win32.c',
Craig Tillerda179ce2016-02-09 12:01:53 -0800508 'src/core/support/histogram.c',
509 'src/core/support/host_port.c',
Craig Tiller521423c2016-02-22 22:22:22 -0800510 'src/core/support/load_file.c',
Craig Tillerda179ce2016-02-09 12:01:53 -0800511 'src/core/support/log.c',
512 'src/core/support/log_android.c',
513 'src/core/support/log_linux.c',
514 'src/core/support/log_posix.c',
515 'src/core/support/log_win32.c',
516 'src/core/support/murmur_hash.c',
517 'src/core/support/slice.c',
518 'src/core/support/slice_buffer.c',
519 'src/core/support/stack_lockfree.c',
520 'src/core/support/string.c',
521 'src/core/support/string_posix.c',
522 'src/core/support/string_win32.c',
523 'src/core/support/subprocess_posix.c',
Craig Tiller1298afd2016-02-09 12:29:17 -0800524 'src/core/support/subprocess_windows.c',
Craig Tillerda179ce2016-02-09 12:01:53 -0800525 'src/core/support/sync.c',
526 'src/core/support/sync_posix.c',
527 'src/core/support/sync_win32.c',
528 'src/core/support/thd.c',
529 'src/core/support/thd_posix.c',
530 'src/core/support/thd_win32.c',
531 'src/core/support/time.c',
532 'src/core/support/time_posix.c',
533 'src/core/support/time_precise.c',
534 'src/core/support/time_win32.c',
535 'src/core/support/tls_pthread.c',
Craig Tiller521423c2016-02-22 22:22:22 -0800536 'src/core/support/tmpfile_posix.c',
537 'src/core/support/tmpfile_win32.c',
Craig Tiller1298afd2016-02-09 12:29:17 -0800538 'src/core/support/wrap_memcpy.c',
Craig Tillerda179ce2016-02-09 12:01:53 -0800539 ],
540 "conditions": [
541 ['OS == "mac"', {
542 'xcode_settings': {
543 'MACOSX_DEPLOYMENT_TARGET': '10.9'
544 }
545 }]
546 ]
547 },
548 {
549 'cflags': [
550 '-std=c99',
551 '-Wall',
552 '-Werror'
553 ],
murgatroid99fd994f12015-10-09 14:02:28 -0700554 'target_name': 'grpc',
555 'product_prefix': 'lib',
556 'type': 'static_library',
557 'dependencies': [
Craig Tillerda179ce2016-02-09 12:01:53 -0800558 'gpr',
murgatroid99fd994f12015-10-09 14:02:28 -0700559 ],
560 'sources': [
murgatroid99fd994f12015-10-09 14:02:28 -0700561 'src/core/census/grpc_context.c',
562 'src/core/census/grpc_filter.c',
Craig Tiller178edfa2016-02-17 20:54:46 -0800563 'src/core/census/grpc_plugin.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700564 'src/core/channel/channel_args.c',
565 'src/core/channel/channel_stack.c',
Craig Tiller178edfa2016-02-17 20:54:46 -0800566 'src/core/channel/channel_stack_builder.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700567 'src/core/channel/client_channel.c',
568 'src/core/channel/compress_filter.c',
569 'src/core/channel/connected_channel.c',
570 'src/core/channel/http_client_filter.c',
571 'src/core/channel/http_server_filter.c',
Craig Tillerca1593a2015-11-02 14:08:33 -0800572 'src/core/channel/subchannel_call_holder.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700573 'src/core/client_config/client_config.c',
574 'src/core/client_config/connector.c',
yang-ga6124122015-11-05 22:36:20 -0800575 'src/core/client_config/default_initial_connect_string.c',
576 'src/core/client_config/initial_connect_string.c',
Craig Tillereb841e22016-02-11 15:49:16 -0800577 'src/core/client_config/lb_policies/load_balancer_api.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700578 'src/core/client_config/lb_policies/pick_first.c',
579 'src/core/client_config/lb_policies/round_robin.c',
580 'src/core/client_config/lb_policy.c',
581 'src/core/client_config/lb_policy_factory.c',
582 'src/core/client_config/lb_policy_registry.c',
583 'src/core/client_config/resolver.c',
584 'src/core/client_config/resolver_factory.c',
585 'src/core/client_config/resolver_registry.c',
586 'src/core/client_config/resolvers/dns_resolver.c',
587 'src/core/client_config/resolvers/sockaddr_resolver.c',
588 'src/core/client_config/subchannel.c',
589 'src/core/client_config/subchannel_factory.c',
Craig Tiller694cf8b2016-01-15 21:13:25 -0800590 'src/core/client_config/subchannel_index.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700591 'src/core/client_config/uri_parser.c',
Craig Tiller521423c2016-02-22 22:22:22 -0800592 'src/core/compression/compression_algorithm.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700593 'src/core/compression/message_compress.c',
594 'src/core/debug/trace.c',
Matthew Iselin1824f052016-02-10 12:16:06 +1100595 'src/core/http/format_request.c',
596 'src/core/http/httpcli.c',
597 'src/core/http/parser.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700598 'src/core/iomgr/closure.c',
599 'src/core/iomgr/endpoint.c',
600 'src/core/iomgr/endpoint_pair_posix.c',
601 'src/core/iomgr/endpoint_pair_windows.c',
602 'src/core/iomgr/exec_ctx.c',
David Garcia Quintas63e72a72015-10-12 22:07:32 -0700603 'src/core/iomgr/executor.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700604 'src/core/iomgr/fd_posix.c',
605 'src/core/iomgr/iocp_windows.c',
606 'src/core/iomgr/iomgr.c',
607 'src/core/iomgr/iomgr_posix.c',
608 'src/core/iomgr/iomgr_windows.c',
609 'src/core/iomgr/pollset_multipoller_with_epoll.c',
610 'src/core/iomgr/pollset_multipoller_with_poll_posix.c',
611 'src/core/iomgr/pollset_posix.c',
612 'src/core/iomgr/pollset_set_posix.c',
613 'src/core/iomgr/pollset_set_windows.c',
614 'src/core/iomgr/pollset_windows.c',
615 'src/core/iomgr/resolve_address_posix.c',
616 'src/core/iomgr/resolve_address_windows.c',
617 'src/core/iomgr/sockaddr_utils.c',
618 'src/core/iomgr/socket_utils_common_posix.c',
619 'src/core/iomgr/socket_utils_linux.c',
620 'src/core/iomgr/socket_utils_posix.c',
621 'src/core/iomgr/socket_windows.c',
622 'src/core/iomgr/tcp_client_posix.c',
623 'src/core/iomgr/tcp_client_windows.c',
624 'src/core/iomgr/tcp_posix.c',
625 'src/core/iomgr/tcp_server_posix.c',
626 'src/core/iomgr/tcp_server_windows.c',
627 'src/core/iomgr/tcp_windows.c',
628 'src/core/iomgr/time_averaged_stats.c',
David Garcia Quintasb65e4212015-10-14 12:00:21 -0700629 'src/core/iomgr/timer.c',
630 'src/core/iomgr/timer_heap.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700631 'src/core/iomgr/udp_server.c',
ahedberg43df2952016-03-18 10:46:38 -0400632 'src/core/iomgr/unix_sockets_posix.c',
633 'src/core/iomgr/unix_sockets_posix_noop.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700634 'src/core/iomgr/wakeup_fd_eventfd.c',
635 'src/core/iomgr/wakeup_fd_nospecial.c',
636 'src/core/iomgr/wakeup_fd_pipe.c',
637 'src/core/iomgr/wakeup_fd_posix.c',
638 'src/core/iomgr/workqueue_posix.c',
639 'src/core/iomgr/workqueue_windows.c',
640 'src/core/json/json.c',
641 'src/core/json/json_reader.c',
642 'src/core/json/json_string.c',
643 'src/core/json/json_writer.c',
Craig Tillereb841e22016-02-11 15:49:16 -0800644 'src/core/proto/grpc/lb/v0/load_balancer.pb.c',
Nicolas "Pixel" Nobled5d83aa2016-01-31 06:21:49 +0100645 'src/core/surface/alarm.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700646 'src/core/surface/api_trace.c',
647 'src/core/surface/byte_buffer.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700648 'src/core/surface/byte_buffer_reader.c',
649 'src/core/surface/call.c',
650 'src/core/surface/call_details.c',
651 'src/core/surface/call_log_batch.c',
652 'src/core/surface/channel.c',
653 'src/core/surface/channel_connectivity.c',
654 'src/core/surface/channel_create.c',
Craig Tiller178edfa2016-02-17 20:54:46 -0800655 'src/core/surface/channel_init.c',
Craig Tiller26dab312015-12-07 14:43:47 -0800656 'src/core/surface/channel_ping.c',
Craig Tiller178edfa2016-02-17 20:54:46 -0800657 'src/core/surface/channel_stack_type.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700658 'src/core/surface/completion_queue.c',
659 'src/core/surface/event_string.c',
660 'src/core/surface/init.c',
661 'src/core/surface/lame_client.c',
662 'src/core/surface/metadata_array.c',
663 'src/core/surface/server.c',
664 'src/core/surface/server_chttp2.c',
murgatroid99c3910ca2016-01-06 13:14:23 -0800665 'src/core/surface/validate_metadata.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700666 'src/core/surface/version.c',
Craig Tillerca1593a2015-11-02 14:08:33 -0800667 'src/core/transport/byte_stream.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700668 'src/core/transport/chttp2/alpn.c',
669 'src/core/transport/chttp2/bin_encoder.c',
670 'src/core/transport/chttp2/frame_data.c',
671 'src/core/transport/chttp2/frame_goaway.c',
672 'src/core/transport/chttp2/frame_ping.c',
673 'src/core/transport/chttp2/frame_rst_stream.c',
674 'src/core/transport/chttp2/frame_settings.c',
675 'src/core/transport/chttp2/frame_window_update.c',
Craig Tillerca1593a2015-11-02 14:08:33 -0800676 'src/core/transport/chttp2/hpack_encoder.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700677 'src/core/transport/chttp2/hpack_parser.c',
678 'src/core/transport/chttp2/hpack_table.c',
679 'src/core/transport/chttp2/huffsyms.c',
680 'src/core/transport/chttp2/incoming_metadata.c',
681 'src/core/transport/chttp2/parsing.c',
682 'src/core/transport/chttp2/status_conversion.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700683 'src/core/transport/chttp2/stream_lists.c',
684 'src/core/transport/chttp2/stream_map.c',
685 'src/core/transport/chttp2/timeout_encoding.c',
686 'src/core/transport/chttp2/varint.c',
687 'src/core/transport/chttp2/writing.c',
688 'src/core/transport/chttp2_transport.c',
689 'src/core/transport/connectivity_state.c',
690 'src/core/transport/metadata.c',
Craig Tillerca1593a2015-11-02 14:08:33 -0800691 'src/core/transport/metadata_batch.c',
Craig Tiller2e7687c2015-11-18 14:56:46 -0800692 'src/core/transport/static_metadata.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700693 'src/core/transport/transport.c',
694 'src/core/transport/transport_op_string.c',
Matthew Iselin1824f052016-02-10 12:16:06 +1100695 'src/core/http/httpcli_security_connector.c',
Craig Tiller521423c2016-02-22 22:22:22 -0800696 'src/core/security/b64.c',
Nicolas "Pixel" Noble2e8fdba2016-02-19 02:09:47 +0100697 'src/core/security/client_auth_filter.c',
698 'src/core/security/credentials.c',
699 'src/core/security/credentials_metadata.c',
700 'src/core/security/credentials_posix.c',
701 'src/core/security/credentials_win32.c',
702 'src/core/security/google_default_credentials.c',
703 'src/core/security/handshake.c',
704 'src/core/security/json_token.c',
705 'src/core/security/jwt_verifier.c',
706 'src/core/security/secure_endpoint.c',
707 'src/core/security/security_connector.c',
708 'src/core/security/security_context.c',
709 'src/core/security/server_auth_filter.c',
710 'src/core/security/server_secure_chttp2.c',
711 'src/core/surface/init_secure.c',
712 'src/core/surface/secure_channel_create.c',
713 'src/core/tsi/fake_transport_security.c',
714 'src/core/tsi/ssl_transport_security.c',
715 'src/core/tsi/transport_security.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700716 'src/core/census/context.c',
717 'src/core/census/initialize.c',
Alistair Veitch77715442016-02-22 14:20:25 -0800718 'src/core/census/mlog.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700719 'src/core/census/operation.c',
Nicolas "Pixel" Noblefa132c22016-01-31 09:31:15 +0100720 'src/core/census/placeholders.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700721 'src/core/census/tracing.c',
Craig Tillereb841e22016-02-11 15:49:16 -0800722 'third_party/nanopb/pb_common.c',
723 'third_party/nanopb/pb_decode.c',
724 'third_party/nanopb/pb_encode.c',
murgatroid99fd994f12015-10-09 14:02:28 -0700725 ],
murgatroid996ffdb942015-10-22 16:10:05 -0700726 "conditions": [
727 ['OS == "mac"', {
728 'xcode_settings': {
murgatroid9922c448b2015-10-23 10:25:30 -0700729 'MACOSX_DEPLOYMENT_TARGET': '10.9'
murgatroid996ffdb942015-10-22 16:10:05 -0700730 }
731 }]
murgatroid995c56c922016-01-25 13:32:52 -0800732 ]
murgatroid99fd994f12015-10-09 14:02:28 -0700733 },
murgatroid992af89e42015-10-01 11:54:00 -0700734 {
735 'include_dirs': [
736 "<!(node -e \"require('nan')\")"
737 ],
738 'cflags': [
murgatroid993abed312016-01-07 17:16:46 -0800739 '-std=c++11',
murgatroid992af89e42015-10-01 11:54:00 -0700740 '-Wall',
741 '-pthread',
742 '-g',
743 '-zdefs',
744 '-Werror',
745 '-Wno-error=deprecated-declarations'
746 ],
747 'ldflags': [
748 '-g'
749 ],
750 "conditions": [
murgatroid995c56c922016-01-25 13:32:52 -0800751 ['OS=="mac"', {
murgatroid992af89e42015-10-01 11:54:00 -0700752 'xcode_settings': {
753 'MACOSX_DEPLOYMENT_TARGET': '10.9',
754 'OTHER_CFLAGS': [
murgatroid99673f65b2016-02-01 11:19:07 -0800755 '-stdlib=libc++',
756 '-std=c++11'
murgatroid992af89e42015-10-01 11:54:00 -0700757 ]
758 }
murgatroid995c56c922016-01-25 13:32:52 -0800759 }],
760 ['OS=="win"', {
761 'dependencies': [
762 "boringssl",
763 "z",
764 ]
Craig Tiller4bef7ce2016-02-02 08:38:43 -0800765 }],
766 ['OS=="linux"', {
767 'ldflags': [
768 '-Wl,-wrap,memcpy'
769 ]
murgatroid992af89e42015-10-01 11:54:00 -0700770 }]
771 ],
772 "target_name": "grpc_node",
773 "sources": [
774 "src/node/ext/byte_buffer.cc",
775 "src/node/ext/call.cc",
murgatroid9947f519e2015-10-07 12:34:24 -0700776 "src/node/ext/call_credentials.cc",
murgatroid992af89e42015-10-01 11:54:00 -0700777 "src/node/ext/channel.cc",
murgatroid9947f519e2015-10-07 12:34:24 -0700778 "src/node/ext/channel_credentials.cc",
murgatroid992af89e42015-10-01 11:54:00 -0700779 "src/node/ext/completion_queue_async_worker.cc",
murgatroid992af89e42015-10-01 11:54:00 -0700780 "src/node/ext/node_grpc.cc",
781 "src/node/ext/server.cc",
782 "src/node/ext/server_credentials.cc",
murgatroid99879bc4f2015-11-05 10:35:04 -0800783 "src/node/ext/timeval.cc",
murgatroid992af89e42015-10-01 11:54:00 -0700784 ],
785 "dependencies": [
murgatroid99879bc4f2015-11-05 10:35:04 -0800786 "grpc",
Craig Tillerda179ce2016-02-09 12:01:53 -0800787 "gpr",
murgatroid992af89e42015-10-01 11:54:00 -0700788 ]
murgatroid99879bc4f2015-11-05 10:35:04 -0800789 },
murgatroid99e190f352016-01-20 13:52:08 -0800790 {
791 "target_name": "action_after_build",
792 "type": "none",
793 "dependencies": [ "<(module_name)" ],
794 "copies": [
795 {
796 "files": [ "<(PRODUCT_DIR)/<(module_name).node"],
797 "destination": "<(module_path)"
798 }
799 ]
800 }
murgatroid992af89e42015-10-01 11:54:00 -0700801 ]
802}