5 # This file has been automatically generated from a template file.
6 # Please look at the templates directory instead.
7 # This file can be regenerated from the template by running
8 # tools/buildgen/generate_projects.sh
10 # Copyright 2015 gRPC authors.
12 # Licensed under the Apache License, Version 2.0 (the "License");
13 # you may not use this file except in compliance with the License.
14 # You may obtain a copy of the License at
16 # http://www.apache.org/licenses/LICENSE-2.0
18 # Unless required by applicable law or agreed to in writing, software
19 # distributed under the License is distributed on an "AS IS" BASIS,
20 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21 # See the License for the specific language governing permissions and
22 # limitations under the License.
24 def is_absl_lib(target_name):
25 return target_name.startswith("absl/");
29 # The openssl and zlib dependencies must be passed in as variables
30 # defined in an included gypi file, usually common.gypi.
31 'openssl_gyp_target%': 'Please Define openssl_gyp_target variable',
32 'zlib_gyp_target%': 'Please Define zlib_gyp_target variable',
34 'grpc_gcov%': 'false',
35 'grpc_alpine%': 'false',
39 % for name, args in configs.items():
40 % if name in ['dbg', 'opt']:
41 '${{'dbg':'Debug', 'opt': 'Release'}[name]}': {
42 % for arg, prop in [('CPPFLAGS', 'cflags'), ('DEFINES', 'defines')]:
43 % if args.get(arg, None) is not None:
45 % for item in args.get(arg).split():
55 % for arg, prop in [('CPPFLAGS', 'cflags'), ('LDFLAGS', 'ldflags')]:
56 % if defaults['global'].get(arg, None) is not None:
58 % for item in defaults['global'].get(arg).split():
81 '<(openssl_gyp_target)',
85 ['grpc_gcov=="true"', {
86 % for arg, prop in [('CPPFLAGS', 'cflags'), ('DEFINES', 'defines'), ('LDFLAGS', 'ldflags')]:
87 % if configs['gcov'].get(arg, None) is not None:
89 % for item in configs['gcov'].get(arg).split():
96 ['grpc_alpine=="true"', {
98 'GPR_MUSL_LIBC_COMPAT'
103 '_WIN32_WINNT=0x0600',
104 'WIN32_LEAN_AND_MEAN',
111 'VCCLCompilerTool': {
112 'RuntimeLibrary': 1, # static debug
121 % if defaults['global'].get('CPPFLAGS', None) is not None:
123 % for item in defaults['global'].get('CPPFLAGS').split():
127 'OTHER_CPLUSPLUSFLAGS': [
128 % for item in defaults['global'].get('CPPFLAGS').split():
133 '-Wno-error=deprecated-declarations',
142 % if getattr(lib, 'platforms', None) is None and lib.name != 'ares' and not is_absl_lib(lib.name):
144 'target_name': '${lib.name}',
145 'type': 'static_library',
147 % for dep in getattr(lib, 'deps', []):
152 % for source in lib.src: