diff options
author | ncteisen <ncteisen@gmail.com> | 2017-05-05 10:27:17 -0700 |
---|---|---|
committer | ncteisen <ncteisen@gmail.com> | 2017-05-05 10:27:17 -0700 |
commit | fde16afefa41510c6dc06afd88bfd6c3002467b5 (patch) | |
tree | 143deed3716f5b13f9340d7f57de27379a255e37 /templates/binding.gyp.template | |
parent | cc7e17b2d6d015d88b94c0d3b089a65e0450614b (diff) | |
parent | 6815e414a4dbca4d0d4dd62b5ec3c6faa60c9bb9 (diff) |
Merge branch 'master' of https://github.com/grpc/grpc into serialization-refactor
Diffstat (limited to 'templates/binding.gyp.template')
-rw-r--r-- | templates/binding.gyp.template | 37 |
1 files changed, 17 insertions, 20 deletions
diff --git a/templates/binding.gyp.template b/templates/binding.gyp.template index a2e8c58892..933174ab6e 100644 --- a/templates/binding.gyp.template +++ b/templates/binding.gyp.template @@ -41,15 +41,16 @@ { 'variables': { 'runtime%': 'node', - # UV integration in C core is enabled by default. It can be disabled - # by setting this argument to anything else. - 'grpc_uv%': 'true', # Some Node installations use the system installation of OpenSSL, and on # some systems, the system OpenSSL still does not have ALPN support. This # will let users recompile gRPC to work without ALPN. 'grpc_alpn%': 'true', # Indicates that the library should be built with gcov. - 'grpc_gcov%': 'false' + 'grpc_gcov%': 'false', + # Indicates that the library should be built with compatibility for musl + # libc, so that it can run on Alpine Linux. This is only necessary if not + # building on Alpine Linux + 'grpc_alpine%': 'false' }, 'target_defaults': { 'configurations': { @@ -83,17 +84,11 @@ 'include' ], 'defines': [ - 'GPR_BACKWARDS_COMPATIBILITY_MODE' + 'GPR_BACKWARDS_COMPATIBILITY_MODE', + 'GRPC_ARES=0', + 'GRPC_UV' ], 'conditions': [ - ['grpc_uv=="true"', { - 'defines': [ - 'GRPC_ARES=0', - # Disabling this while bugs are ironed out. Uncomment this to - # re-enable libuv integration in C core. - 'GRPC_UV' - ] - }], ['grpc_gcov=="true"', { % for arg, prop in [('CPPFLAGS', 'cflags'), ('DEFINES', 'defines'), ('LDFLAGS', 'ldflags')]: % if configs['gcov'].get(arg, None) is not None: @@ -105,6 +100,11 @@ % endif % endfor }], + ['grpc_alpine=="true"', { + 'defines': [ + 'GPR_MUSL_LIBC_COMPAT' + ] + }], ['OS!="win" and runtime=="electron"', { "defines": [ 'OPENSSL_NO_THREADS' @@ -233,6 +233,10 @@ } ] }, + ] + }], + ['OS == "win"', { + 'targets': [ # Only want to compile zlib under Windows % for module in node_modules: % for lib in libs: @@ -264,13 +268,6 @@ }] ], 'targets': [ - <% - for lib in libs: - if 'grpc' in lib.transitive_deps or lib.name == 'grpc': - lib.deps.append('node_modules/cares/deps/cares/cares.gyp:cares') - for module in node_modules: - module.deps.append('node_modules/cares/deps/cares/cares.gyp:cares') - %> % for module in node_modules: % for lib in libs: % if lib.name in module.transitive_deps and lib.name not in ('boringssl', 'z'): |