blob: 559a7dc165603944613206d0bd6db951f5105059 [file] [log] [blame]
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001# Copyright 2013 The Chromium Authors. All rights reserved.
Torne (Richard Coles)58218062012-11-14 11:43:16 +00002# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5{
6 'variables': {
7 'chromium_code': 1,
8
9 'linux_link_kerberos%': 0,
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +010010 'use_tracing_cache_backend%': 0,
Torne (Richard Coles)58218062012-11-14 11:43:16 +000011 'conditions': [
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +000012 ['chromeos==1 or embedded==1 or OS=="android" or OS=="ios"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +000013 # Disable Kerberos on ChromeOS, Android and iOS, at least for now.
14 # It needs configuration (krb5.conf and so on).
15 'use_kerberos%': 0,
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +000016 }, { # chromeos == 0 and embedded==0 and OS!="android" and OS!="ios"
Torne (Richard Coles)58218062012-11-14 11:43:16 +000017 'use_kerberos%': 1,
18 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +000019 ['OS=="android" and target_arch != "ia32"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +000020 # The way the cache uses mmap() is inefficient on some Android devices.
21 # If this flag is set, we hackily avoid using mmap() in the disk cache.
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +000022 # We are pretty confident that mmap-ing the index would not hurt any
23 # existing x86 android devices, but we cannot be so sure about the
24 # variety of ARM devices. So enable it for x86 only for now.
Torne (Richard Coles)58218062012-11-14 11:43:16 +000025 'posix_avoid_mmap%': 1,
26 }, {
27 'posix_avoid_mmap%': 0,
28 }],
29 ['OS=="ios"', {
30 # Websockets and socket stream are not used on iOS.
31 'enable_websockets%': 0,
32 # iOS does not use V8.
33 'use_v8_in_net%': 0,
34 'enable_built_in_dns%': 0,
35 }, {
36 'enable_websockets%': 1,
37 'use_v8_in_net%': 1,
38 'enable_built_in_dns%': 1,
39 }],
40 ],
41 },
42 'includes': [
43 '../build/win_precompile.gypi',
Ben Murdocha02191e2014-04-16 11:17:03 +010044 'net.gypi',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000045 ],
46 'targets': [
47 {
48 'target_name': 'net',
49 'type': '<(component)',
50 'variables': { 'enable_wexit_time_destructors': 1, },
51 'dependencies': [
52 '../base/base.gyp:base',
53 '../base/base.gyp:base_i18n',
54 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000055 '../crypto/crypto.gyp:crypto',
56 '../sdch/sdch.gyp:sdch',
57 '../third_party/icu/icu.gyp:icui18n',
58 '../third_party/icu/icu.gyp:icuuc',
59 '../third_party/zlib/zlib.gyp:zlib',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +010060 '../url/url.gyp:url_lib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000061 'net_resources',
62 ],
63 'sources': [
Ben Murdocha02191e2014-04-16 11:17:03 +010064 '<@(net_nacl_common_sources)',
65 '<@(net_non_nacl_sources)',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000066 ],
67 'defines': [
68 'NET_IMPLEMENTATION',
69 ],
70 'export_dependent_settings': [
71 '../base/base.gyp:base',
72 ],
73 'conditions': [
74 ['chromeos==1', {
75 'sources!': [
76 'base/network_change_notifier_linux.cc',
77 'base/network_change_notifier_linux.h',
78 'base/network_change_notifier_netlink_linux.cc',
79 'base/network_change_notifier_netlink_linux.h',
80 'proxy/proxy_config_service_linux.cc',
81 'proxy/proxy_config_service_linux.h',
82 ],
83 }],
84 ['use_kerberos==1', {
85 'defines': [
86 'USE_KERBEROS',
87 ],
88 'conditions': [
89 ['OS=="openbsd"', {
90 'include_dirs': [
91 '/usr/include/kerberosV'
92 ],
93 }],
94 ['linux_link_kerberos==1', {
95 'link_settings': {
96 'ldflags': [
97 '<!@(krb5-config --libs gssapi)',
98 ],
99 },
100 }, { # linux_link_kerberos==0
101 'defines': [
102 'DLOPEN_KERBEROS',
103 ],
104 }],
105 ],
106 }, { # use_kerberos == 0
107 'sources!': [
108 'http/http_auth_gssapi_posix.cc',
109 'http/http_auth_gssapi_posix.h',
110 'http/http_auth_handler_negotiate.h',
111 'http/http_auth_handler_negotiate.cc',
112 ],
113 }],
114 ['posix_avoid_mmap==1', {
115 'defines': [
116 'POSIX_AVOID_MMAP',
117 ],
118 'direct_dependent_settings': {
119 'defines': [
120 'POSIX_AVOID_MMAP',
121 ],
122 },
123 'sources!': [
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000124 'disk_cache/blockfile/mapped_file_posix.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000125 ],
126 }, { # else
127 'sources!': [
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000128 'disk_cache/blockfile/mapped_file_avoid_mmap_posix.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000129 ],
130 }],
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +0100131 ['disable_file_support==1', {
132 # TODO(mmenke): Should probably get rid of the dependency on
133 # net_resources in this case (It's used in net_util, to format
134 # directory listings. Also used outside of net/).
135 'sources!': [
136 'base/directory_lister.cc',
137 'base/directory_lister.h',
138 'url_request/url_request_file_dir_job.cc',
139 'url_request/url_request_file_dir_job.h',
140 'url_request/url_request_file_job.cc',
141 'url_request/url_request_file_job.h',
142 'url_request/file_protocol_handler.cc',
143 'url_request/file_protocol_handler.h',
144 ],
145 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000146 ['disable_ftp_support==1', {
147 'sources/': [
148 ['exclude', '^ftp/'],
149 ],
150 'sources!': [
151 'url_request/ftp_protocol_handler.cc',
152 'url_request/ftp_protocol_handler.h',
153 'url_request/url_request_ftp_job.cc',
154 'url_request/url_request_ftp_job.h',
155 ],
156 }],
157 ['enable_built_in_dns==1', {
158 'defines': [
159 'ENABLE_BUILT_IN_DNS',
160 ]
161 }, { # else
162 'sources!': [
163 'dns/address_sorter_posix.cc',
164 'dns/address_sorter_posix.h',
165 'dns/dns_client.cc',
166 ],
167 }],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100168 ['use_tracing_cache_backend==1', {
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000169 'defines': [
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100170 'USE_TRACING_CACHE_BACKEND'
171 ],
172 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000173 ['use_openssl==1', {
174 'sources!': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000175 'base/crypto_module_nss.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000176 'base/keygen_handler_nss.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000177 'base/nss_memio.c',
178 'base/nss_memio.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100179 'cert/cert_database_nss.cc',
180 'cert/cert_verify_proc_nss.cc',
181 'cert/cert_verify_proc_nss.h',
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000182 'cert/ct_log_verifier_nss.cc',
183 'cert/ct_objects_extractor_nss.cc',
Ben Murdochbb1529c2013-08-08 10:24:53 +0100184 'cert/jwk_serializer_nss.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100185 'cert/nss_cert_database.cc',
186 'cert/nss_cert_database.h',
Ben Murdochc5cede92014-04-10 11:22:14 +0100187 'cert/nss_cert_database_chromeos.cc',
188 'cert/nss_cert_database_chromeos.h',
189 'cert/nss_profile_filter_chromeos.cc',
190 'cert/nss_profile_filter_chromeos.h',
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000191 'cert/scoped_nss_types.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100192 'cert/test_root_certs_nss.cc',
193 'cert/x509_certificate_nss.cc',
194 'cert/x509_util_nss.cc',
195 'cert/x509_util_nss.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000196 'ocsp/nss_ocsp.cc',
197 'ocsp/nss_ocsp.h',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000198 'quic/crypto/aead_base_decrypter_nss.cc',
199 'quic/crypto/aead_base_encrypter_nss.cc',
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100200 'quic/crypto/aes_128_gcm_12_decrypter_nss.cc',
201 'quic/crypto/aes_128_gcm_12_encrypter_nss.cc',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000202 'quic/crypto/chacha20_poly1305_decrypter_nss.cc',
203 'quic/crypto/chacha20_poly1305_encrypter_nss.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100204 'quic/crypto/channel_id_nss.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000205 'quic/crypto/p256_key_exchange_nss.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000206 'socket/nss_ssl_util.cc',
207 'socket/nss_ssl_util.h',
208 'socket/ssl_client_socket_nss.cc',
209 'socket/ssl_client_socket_nss.h',
210 'socket/ssl_server_socket_nss.cc',
211 'socket/ssl_server_socket_nss.h',
212 'third_party/mozilla_security_manager/nsKeygenHandler.cpp',
213 'third_party/mozilla_security_manager/nsKeygenHandler.h',
214 'third_party/mozilla_security_manager/nsNSSCertificateDB.cpp',
215 'third_party/mozilla_security_manager/nsNSSCertificateDB.h',
216 'third_party/mozilla_security_manager/nsPKCS12Blob.cpp',
217 'third_party/mozilla_security_manager/nsPKCS12Blob.h',
218 ],
Ben Murdocheffb81e2014-03-31 11:51:25 +0100219 'dependencies': [
220 '../third_party/openssl/openssl.gyp:openssl',
221 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000222 },
223 { # else !use_openssl: remove the unneeded files
224 'sources!': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000225 'base/crypto_module_openssl.cc',
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000226 'cert/ct_log_verifier_openssl.cc',
227 'cert/ct_objects_extractor_openssl.cc',
Ben Murdochbb1529c2013-08-08 10:24:53 +0100228 'cert/jwk_serializer_openssl.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100229 'cert/x509_util_openssl.cc',
230 'cert/x509_util_openssl.h',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000231 'quic/crypto/aead_base_decrypter_openssl.cc',
232 'quic/crypto/aead_base_encrypter_openssl.cc',
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100233 'quic/crypto/aes_128_gcm_12_decrypter_openssl.cc',
234 'quic/crypto/aes_128_gcm_12_encrypter_openssl.cc',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000235 'quic/crypto/chacha20_poly1305_decrypter_openssl.cc',
236 'quic/crypto/chacha20_poly1305_encrypter_openssl.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100237 'quic/crypto/channel_id_openssl.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000238 'quic/crypto/p256_key_exchange_openssl.cc',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000239 'quic/crypto/scoped_evp_aead_ctx.cc',
240 'quic/crypto/scoped_evp_aead_ctx.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000241 'socket/ssl_client_socket_openssl.cc',
242 'socket/ssl_client_socket_openssl.h',
243 'socket/ssl_server_socket_openssl.cc',
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +0000244 'socket/ssl_session_cache_openssl.cc',
245 'socket/ssl_session_cache_openssl.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000246 ],
247 },
248 ],
Ben Murdocheffb81e2014-03-31 11:51:25 +0100249 [ 'use_openssl_certs == 0', {
250 'sources!': [
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +0100251 'base/keygen_handler_openssl.cc',
Ben Murdocheffb81e2014-03-31 11:51:25 +0100252 'base/openssl_private_key_store.h',
253 'base/openssl_private_key_store_android.cc',
254 'base/openssl_private_key_store_memory.cc',
255 'cert/cert_database_openssl.cc',
256 'cert/cert_verify_proc_openssl.cc',
257 'cert/cert_verify_proc_openssl.h',
258 'cert/test_root_certs_openssl.cc',
259 'cert/x509_certificate_openssl.cc',
260 'ssl/openssl_client_key_store.cc',
261 'ssl/openssl_client_key_store.h',
262 ],
263 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000264 [ 'use_glib == 1', {
265 'dependencies': [
266 '../build/linux/system.gyp:gconf',
267 '../build/linux/system.gyp:gio',
268 ],
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000269 }],
270 [ 'desktop_linux == 1 or chromeos == 1', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000271 'conditions': [
Ben Murdocheffb81e2014-03-31 11:51:25 +0100272 ['use_openssl == 0', {
273 # use NSS
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000274 'dependencies': [
275 '../build/linux/system.gyp:ssl',
276 ],
277 }],
278 ['os_bsd==1', {
279 'sources!': [
280 'base/network_change_notifier_linux.cc',
281 'base/network_change_notifier_netlink_linux.cc',
282 'proxy/proxy_config_service_linux.cc',
283 ],
284 },{
285 'dependencies': [
286 '../build/linux/system.gyp:libresolv',
287 ],
288 }],
289 ['OS=="solaris"', {
290 'link_settings': {
291 'ldflags': [
292 '-R/usr/lib/mps',
293 ],
294 },
295 }],
296 ],
297 },
298 { # else: OS is not in the above list
299 'sources!': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000300 'base/crypto_module_nss.cc',
301 'base/keygen_handler_nss.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100302 'cert/cert_database_nss.cc',
303 'cert/nss_cert_database.cc',
304 'cert/nss_cert_database.h',
305 'cert/test_root_certs_nss.cc',
306 'cert/x509_certificate_nss.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000307 'ocsp/nss_ocsp.cc',
308 'ocsp/nss_ocsp.h',
309 'third_party/mozilla_security_manager/nsKeygenHandler.cpp',
310 'third_party/mozilla_security_manager/nsKeygenHandler.h',
311 'third_party/mozilla_security_manager/nsNSSCertificateDB.cpp',
312 'third_party/mozilla_security_manager/nsNSSCertificateDB.h',
313 'third_party/mozilla_security_manager/nsPKCS12Blob.cpp',
314 'third_party/mozilla_security_manager/nsPKCS12Blob.h',
315 ],
316 },
317 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000318 [ 'use_nss != 1', {
319 'sources!': [
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100320 'cert/cert_verify_proc_nss.cc',
321 'cert/cert_verify_proc_nss.h',
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +0000322 'ssl/client_cert_store_nss.cc',
323 'ssl/client_cert_store_nss.h',
Ben Murdochc5cede92014-04-10 11:22:14 +0100324 'ssl/client_cert_store_chromeos.cc',
325 'ssl/client_cert_store_chromeos.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000326 ],
327 }],
328 [ 'enable_websockets != 1', {
329 'sources/': [
330 ['exclude', '^socket_stream/'],
331 ['exclude', '^websockets/'],
332 ],
333 'sources!': [
334 'spdy/spdy_websocket_stream.cc',
335 'spdy/spdy_websocket_stream.h',
336 ],
337 }],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100338 [ 'enable_mdns != 1', {
339 'sources!' : [
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100340 'dns/mdns_cache.cc',
341 'dns/mdns_cache.h',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100342 'dns/mdns_client.cc',
343 'dns/mdns_client.h',
344 'dns/mdns_client_impl.cc',
345 'dns/mdns_client_impl.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100346 'dns/record_parsed.cc',
347 'dns/record_parsed.h',
348 'dns/record_rdata.cc',
349 'dns/record_rdata.h',
350 ]
351 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000352 [ 'OS == "win"', {
353 'sources!': [
354 'http/http_auth_handler_ntlm_portable.cc',
Torne (Richard Coles)58537e22013-09-12 12:10:22 +0100355 'socket/tcp_socket_libevent.cc',
356 'socket/tcp_socket_libevent.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000357 'udp/udp_socket_libevent.cc',
358 'udp/udp_socket_libevent.h',
359 ],
360 'dependencies': [
361 '../third_party/nss/nss.gyp:nspr',
362 '../third_party/nss/nss.gyp:nss',
363 'third_party/nss/ssl.gyp:libssl',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000364 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000365 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
366 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000367 }, { # else: OS != "win"
368 'sources!': [
369 'base/winsock_init.cc',
370 'base/winsock_init.h',
371 'base/winsock_util.cc',
372 'base/winsock_util.h',
373 'proxy/proxy_resolver_winhttp.cc',
374 'proxy/proxy_resolver_winhttp.h',
375 ],
376 },
377 ],
378 [ 'OS == "mac"', {
Ben Murdocheffb81e2014-03-31 11:51:25 +0100379 'conditions': [
380 [ 'use_openssl == 0', {
381 'dependencies': [
382 # defaults to nss
383 '../third_party/nss/nss.gyp:nspr',
384 '../third_party/nss/nss.gyp:nss',
385 'third_party/nss/ssl.gyp:libssl',
386 ],
387 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000388 ],
389 'link_settings': {
390 'libraries': [
391 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework',
392 '$(SDKROOT)/System/Library/Frameworks/Security.framework',
393 '$(SDKROOT)/System/Library/Frameworks/SystemConfiguration.framework',
394 '$(SDKROOT)/usr/lib/libresolv.dylib',
395 ]
396 },
397 },
398 ],
399 [ 'OS == "ios"', {
400 'dependencies': [
401 '../third_party/nss/nss.gyp:nss',
402 'third_party/nss/ssl.gyp:libssl',
403 ],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000404 'sources!': [
Ben Murdochc5cede92014-04-10 11:22:14 +0100405 'disk_cache/blockfile/file_posix.cc',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000406 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000407 'link_settings': {
408 'libraries': [
409 '$(SDKROOT)/System/Library/Frameworks/CFNetwork.framework',
410 '$(SDKROOT)/System/Library/Frameworks/MobileCoreServices.framework',
411 '$(SDKROOT)/System/Library/Frameworks/Security.framework',
412 '$(SDKROOT)/System/Library/Frameworks/SystemConfiguration.framework',
413 '$(SDKROOT)/usr/lib/libresolv.dylib',
414 ],
415 },
416 },
417 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000418 ['OS=="android" and _toolset=="target" and android_webview_build == 0', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000419 'dependencies': [
420 'net_java',
421 ],
422 }],
423 [ 'OS == "android"', {
424 'dependencies': [
425 '../third_party/openssl/openssl.gyp:openssl',
426 'net_jni_headers',
427 ],
428 'sources!': [
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000429 'base/openssl_private_key_store_memory.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100430 'cert/cert_database_openssl.cc',
431 'cert/cert_verify_proc_openssl.cc',
432 'cert/test_root_certs_openssl.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000433 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000434 # The net/android/keystore_openssl.cc source file needs to
435 # access an OpenSSL-internal header.
436 'include_dirs': [
437 '../third_party/openssl',
438 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000439 },
440 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000441 ],
442 'target_conditions': [
443 # These source files are excluded by default platform rules, but they
444 # are needed in specific cases on other platforms. Re-including them can
445 # only be done in target_conditions as it is evaluated after the
446 # platform rules.
447 ['OS == "android"', {
448 'sources/': [
449 ['include', '^base/platform_mime_util_linux\\.cc$'],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000450 ['include', '^base/address_tracker_linux\\.cc$'],
451 ['include', '^base/address_tracker_linux\\.h$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000452 ],
453 }],
454 ['OS == "ios"', {
455 'sources/': [
456 ['include', '^base/network_change_notifier_mac\\.cc$'],
457 ['include', '^base/network_config_watcher_mac\\.cc$'],
458 ['include', '^base/platform_mime_util_mac\\.mm$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000459 # The iOS implementation only partially uses NSS and thus does not
460 # defines |use_nss|. In particular the |USE_NSS| preprocessor
461 # definition is not used. The following files are needed though:
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100462 ['include', '^cert/cert_verify_proc_nss\\.cc$'],
463 ['include', '^cert/cert_verify_proc_nss\\.h$'],
464 ['include', '^cert/test_root_certs_nss\\.cc$'],
465 ['include', '^cert/x509_util_nss\\.cc$'],
466 ['include', '^cert/x509_util_nss\\.h$'],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100467 ['include', '^proxy/proxy_resolver_mac\\.cc$'],
468 ['include', '^proxy/proxy_server_mac\\.cc$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000469 ['include', '^ocsp/nss_ocsp\\.cc$'],
470 ['include', '^ocsp/nss_ocsp\\.h$'],
471 ],
472 }],
473 ],
474 },
475 {
476 'target_name': 'net_unittests',
477 'type': '<(gtest_target_type)',
478 'dependencies': [
479 '../base/base.gyp:base',
480 '../base/base.gyp:base_i18n',
481 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000482 '../crypto/crypto.gyp:crypto',
483 '../testing/gmock.gyp:gmock',
484 '../testing/gtest.gyp:gtest',
485 '../third_party/zlib/zlib.gyp:zlib',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100486 '../url/url.gyp:url_lib',
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100487 'http_server',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000488 'net',
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100489 'net_test_support'
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000490 ],
491 'sources': [
Ben Murdocha02191e2014-04-16 11:17:03 +0100492 '<@(net_test_sources)',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000493 ],
494 'conditions': [
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100495 ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', {
496 'dependencies': [
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +0100497 'balsa',
498 'epoll_server',
499 'flip_in_mem_edsm_server_base',
500 'quic_base',
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100501 ],
502 'sources': [
Ben Murdocha02191e2014-04-16 11:17:03 +0100503 '<@(net_linux_test_sources)',
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100504 ],
505 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000506 ['chromeos==1', {
507 'sources!': [
508 'base/network_change_notifier_linux_unittest.cc',
509 'proxy/proxy_config_service_linux_unittest.cc',
510 ],
511 }],
512 [ 'OS == "android"', {
513 'sources!': [
Ben Murdocheffb81e2014-03-31 11:51:25 +0100514 # See bug http://crbug.com/344533.
515 'disk_cache/blockfile/index_table_v3_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000516 # No res_ninit() et al on Android, so this doesn't make a lot of
517 # sense.
518 'dns/dns_config_service_posix_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000519 ],
520 'dependencies': [
521 'net_javatests',
522 'net_test_jni_headers',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000523 ],
524 }],
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +0000525 [ 'use_nss != 1', {
526 'sources!': [
527 'ssl/client_cert_store_nss_unittest.cc',
Ben Murdochc5cede92014-04-10 11:22:14 +0100528 'ssl/client_cert_store_chromeos_unittest.cc',
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +0000529 ],
530 }],
531 [ 'use_openssl == 1', {
532 # Avoid compiling/linking with the system library.
533 'dependencies': [
534 '../third_party/openssl/openssl.gyp:openssl',
535 ],
536 }, { # use_openssl == 0
537 'conditions': [
538 [ 'desktop_linux == 1 or chromeos == 1', {
539 'dependencies': [
540 '../build/linux/system.gyp:ssl',
541 ],
542 }, { # desktop_linux == 0 and chromeos == 0
543 'sources!': [
544 'cert/nss_cert_database_unittest.cc',
545 ],
546 }],
547 ],
548 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000549 [ 'os_posix == 1 and OS != "mac" and OS != "android" and OS != "ios"', {
550 'conditions': [
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +0100551 ['use_allocator!="none"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000552 'dependencies': [
553 '../base/allocator/allocator.gyp:allocator',
554 ],
555 }],
556 ],
557 }],
558 [ 'use_kerberos==1', {
559 'defines': [
560 'USE_KERBEROS',
561 ],
562 }, { # use_kerberos == 0
563 'sources!': [
564 'http/http_auth_gssapi_posix_unittest.cc',
565 'http/http_auth_handler_negotiate_unittest.cc',
566 'http/mock_gssapi_library_posix.cc',
567 'http/mock_gssapi_library_posix.h',
568 ],
569 }],
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000570 [ 'use_openssl == 1 or (desktop_linux == 0 and chromeos == 0 and OS != "ios")', {
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100571 # Only include this test when on Posix and using NSS for
572 # cert verification or on iOS (which also uses NSS for certs).
573 'sources!': [
574 'ocsp/nss_ocsp_unittest.cc',
575 ],
576 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000577 [ 'use_openssl==1', {
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000578 # When building for OpenSSL, we need to exclude NSS specific tests
579 # or functionality not supported by OpenSSL yet.
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000580 # TODO(bulach): Add equivalent tests when the underlying
581 # functionality is ported to OpenSSL.
582 'sources!': [
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +0000583 'cert/ct_objects_extractor_unittest.cc',
584 'cert/multi_log_ct_verifier_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100585 'cert/nss_cert_database_unittest.cc',
Ben Murdochc5cede92014-04-10 11:22:14 +0100586 'cert/nss_cert_database_chromeos_unittest.cc',
587 'cert/nss_profile_filter_chromeos_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100588 'cert/x509_util_nss_unittest.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100589 'quic/test_tools/crypto_test_utils_nss.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000590 ],
591 }, { # else !use_openssl: remove the unneeded files
592 'sources!': [
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100593 'cert/x509_util_openssl_unittest.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100594 'quic/test_tools/crypto_test_utils_openssl.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000595 'socket/ssl_client_socket_openssl_unittest.cc',
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +0000596 'socket/ssl_session_cache_openssl_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000597 ],
598 },
599 ],
Ben Murdocheffb81e2014-03-31 11:51:25 +0100600 [ 'use_openssl_certs == 0', {
601 'sources!': [
602 'ssl/openssl_client_key_store_unittest.cc',
603 ],
604 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000605 [ 'enable_websockets != 1', {
606 'sources/': [
607 ['exclude', '^socket_stream/'],
608 ['exclude', '^websockets/'],
Ben Murdocheb525c52013-07-10 11:40:50 +0100609 ['exclude', '^spdy/spdy_websocket_stream_unittest\\.cc$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000610 ],
611 }],
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +0100612 ['disable_file_support==1', {
613 'sources!': [
614 'base/directory_lister_unittest.cc',
615 'url_request/url_request_file_job_unittest.cc',
616 ],
617 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000618 [ 'disable_ftp_support==1', {
619 'sources/': [
620 ['exclude', '^ftp/'],
621 ],
622 'sources!': [
623 'url_request/url_request_ftp_job_unittest.cc',
624 ],
625 },
626 ],
627 [ 'enable_built_in_dns!=1', {
628 'sources!': [
629 'dns/address_sorter_posix_unittest.cc',
630 'dns/address_sorter_unittest.cc',
631 ],
632 },
633 ],
634 [ 'use_v8_in_net==1', {
635 'dependencies': [
636 'net_with_v8',
637 ],
638 }, { # else: !use_v8_in_net
639 'sources!': [
640 'proxy/proxy_resolver_v8_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000641 'proxy/proxy_resolver_v8_tracing_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000642 ],
643 },
644 ],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100645
646 [ 'enable_mdns != 1', {
647 'sources!' : [
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100648 'dns/mdns_cache_unittest.cc',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100649 'dns/mdns_client_unittest.cc',
650 'dns/mdns_query_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100651 'dns/record_parsed_unittest.cc',
652 'dns/record_rdata_unittest.cc',
653 ],
654 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000655 [ 'OS == "win"', {
656 'sources!': [
657 'dns/dns_config_service_posix_unittest.cc',
658 'http/http_auth_gssapi_posix_unittest.cc',
659 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000660 'dependencies': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000661 '../third_party/nss/nss.gyp:nspr',
662 '../third_party/nss/nss.gyp:nss',
663 'third_party/nss/ssl.gyp:libssl',
664 ],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000665 'conditions': [
666 [ 'icu_use_data_file_flag == 0', {
667 # This is needed to trigger the dll copy step on windows.
668 # TODO(mark): Specifying this here shouldn't be necessary.
669 'dependencies': [
670 '../third_party/icu/icu.gyp:icudata',
671 ],
672 }],
673 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000674 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
675 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000676 },
677 ],
Ben Murdocheffb81e2014-03-31 11:51:25 +0100678 [ 'OS == "mac" and use_openssl == 0', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000679 'dependencies': [
680 '../third_party/nss/nss.gyp:nspr',
681 '../third_party/nss/nss.gyp:nss',
682 'third_party/nss/ssl.gyp:libssl',
683 ],
684 },
685 ],
686 [ 'OS == "ios"', {
687 'dependencies': [
688 '../third_party/nss/nss.gyp:nss',
689 ],
690 'actions': [
691 {
692 'action_name': 'copy_test_data',
693 'variables': {
694 'test_data_files': [
695 'data/ssl/certificates/',
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100696 'data/test.html',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000697 'data/url_request_unittest/',
698 ],
699 'test_data_prefix': 'net',
700 },
701 'includes': [ '../build/copy_test_data_ios.gypi' ],
702 },
703 ],
704 'sources!': [
705 # TODO(droger): The following tests are disabled because the
706 # implementation is missing or incomplete.
707 # KeygenHandler::GenKeyAndSignChallenge() is not ported to iOS.
708 'base/keygen_handler_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000709 'disk_cache/backend_unittest.cc',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000710 'disk_cache/blockfile/block_files_unittest.cc',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000711 # Need to read input data files.
712 'filter/gzip_filter_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000713 'socket/ssl_server_socket_unittest.cc',
Bo Liu5c02ac12014-05-01 10:37:37 -0700714 'spdy/fuzzing/hpack_fuzz_util_test.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000715 # Need TestServer.
716 'proxy/proxy_script_fetcher_impl_unittest.cc',
717 'socket/ssl_client_socket_unittest.cc',
718 'url_request/url_fetcher_impl_unittest.cc',
719 'url_request/url_request_context_builder_unittest.cc',
720 # Needs GetAppOutput().
721 'test/python_utils_unittest.cc',
722
723 # The following tests are disabled because they don't apply to
724 # iOS.
725 # OS is not "linux" or "freebsd" or "openbsd".
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100726 'socket/unix_domain_socket_posix_unittest.cc',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000727
Ben Murdocheffb81e2014-03-31 11:51:25 +0100728 # See bug http://crbug.com/344533.
729 'disk_cache/blockfile/index_table_v3_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000730 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000731 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000732 [ 'OS == "android"', {
733 'dependencies': [
734 '../third_party/openssl/openssl.gyp:openssl',
735 ],
736 'sources!': [
737 'dns/dns_config_service_posix_unittest.cc',
738 ],
739 },
740 ],
741 ['OS == "android" and gtest_target_type == "shared_library"', {
742 'dependencies': [
743 '../testing/android/native_test.gyp:native_test_native_code',
744 ]
745 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000746 ],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000747 'target_conditions': [
748 # These source files are excluded by default platform rules, but they
749 # are needed in specific cases on other platforms. Re-including them can
750 # only be done in target_conditions as it is evaluated after the
751 # platform rules.
752 ['OS == "android"', {
753 'sources/': [
754 ['include', '^base/address_tracker_linux_unittest\\.cc$'],
755 ],
756 }],
757 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000758 },
759 {
760 'target_name': 'net_perftests',
761 'type': 'executable',
762 'dependencies': [
763 '../base/base.gyp:base',
764 '../base/base.gyp:base_i18n',
765 '../base/base.gyp:test_support_perf',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000766 '../testing/gtest.gyp:gtest',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100767 '../url/url.gyp:url_lib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000768 'net',
769 'net_test_support',
770 ],
771 'sources': [
772 'cookies/cookie_monster_perftest.cc',
Torne (Richard Coles)a1401312014-03-18 10:20:56 +0000773 'disk_cache/blockfile/disk_cache_perftest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000774 'proxy/proxy_resolver_perftest.cc',
775 ],
776 'conditions': [
777 [ 'use_v8_in_net==1', {
778 'dependencies': [
779 'net_with_v8',
780 ],
781 }, { # else: !use_v8_in_net
782 'sources!': [
783 'proxy/proxy_resolver_perftest.cc',
784 ],
785 },
786 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000787 [ 'OS == "win"', {
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000788 'conditions': [
789 [ 'icu_use_data_file_flag == 0', {
790 # This is needed to trigger the dll copy step on windows.
791 # TODO(mark): Specifying this here shouldn't be necessary.
792 'dependencies': [
793 '../third_party/icu/icu.gyp:icudata',
794 ],
795 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000796 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000797 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
798 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +0000799 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000800 ],
801 },
802 {
803 'target_name': 'net_test_support',
804 'type': 'static_library',
805 'dependencies': [
806 '../base/base.gyp:base',
807 '../base/base.gyp:test_support_base',
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +0100808 '../net/tools/tld_cleanup/tld_cleanup.gyp:tld_cleanup_util',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000809 '../testing/gtest.gyp:gtest',
Ben Murdocheb525c52013-07-10 11:40:50 +0100810 '../testing/gmock.gyp:gmock',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100811 '../url/url.gyp:url_lib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000812 'net',
813 ],
814 'export_dependent_settings': [
815 '../base/base.gyp:base',
816 '../base/base.gyp:test_support_base',
817 '../testing/gtest.gyp:gtest',
Ben Murdocheb525c52013-07-10 11:40:50 +0100818 '../testing/gmock.gyp:gmock',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000819 ],
820 'sources': [
821 'base/capturing_net_log.cc',
822 'base/capturing_net_log.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000823 'base/load_timing_info_test_util.cc',
824 'base/load_timing_info_test_util.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000825 'base/mock_file_stream.cc',
826 'base/mock_file_stream.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000827 'base/test_completion_callback.cc',
828 'base/test_completion_callback.h',
829 'base/test_data_directory.cc',
830 'base/test_data_directory.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100831 'cert/mock_cert_verifier.cc',
832 'cert/mock_cert_verifier.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000833 'cookies/cookie_monster_store_test.cc',
834 'cookies/cookie_monster_store_test.h',
835 'cookies/cookie_store_test_callbacks.cc',
836 'cookies/cookie_store_test_callbacks.h',
837 'cookies/cookie_store_test_helpers.cc',
838 'cookies/cookie_store_test_helpers.h',
839 'disk_cache/disk_cache_test_base.cc',
840 'disk_cache/disk_cache_test_base.h',
841 'disk_cache/disk_cache_test_util.cc',
842 'disk_cache/disk_cache_test_util.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000843 'dns/dns_test_util.cc',
844 'dns/dns_test_util.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000845 'dns/mock_host_resolver.cc',
846 'dns/mock_host_resolver.h',
Ben Murdocheb525c52013-07-10 11:40:50 +0100847 'dns/mock_mdns_socket_factory.cc',
848 'dns/mock_mdns_socket_factory.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000849 'proxy/mock_proxy_resolver.cc',
850 'proxy/mock_proxy_resolver.h',
851 'proxy/mock_proxy_script_fetcher.cc',
852 'proxy/mock_proxy_script_fetcher.h',
853 'proxy/proxy_config_service_common_unittest.cc',
854 'proxy/proxy_config_service_common_unittest.h',
855 'socket/socket_test_util.cc',
856 'socket/socket_test_util.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100857 'test/cert_test_util.cc',
858 'test/cert_test_util.h',
Torne (Richard Coles)0f1bc082013-11-06 12:27:47 +0000859 'test/ct_test_util.cc',
860 'test/ct_test_util.h',
Torne (Richard Coles)b2df76e2013-05-13 16:52:09 +0100861 'test/embedded_test_server/embedded_test_server.cc',
862 'test/embedded_test_server/embedded_test_server.h',
863 'test/embedded_test_server/http_connection.cc',
864 'test/embedded_test_server/http_connection.h',
865 'test/embedded_test_server/http_request.cc',
866 'test/embedded_test_server/http_request.h',
867 'test/embedded_test_server/http_response.cc',
868 'test/embedded_test_server/http_response.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000869 'test/net_test_suite.cc',
870 'test/net_test_suite.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000871 'test/python_utils.cc',
872 'test/python_utils.h',
Torne (Richard Coles)b2df76e2013-05-13 16:52:09 +0100873 'test/spawned_test_server/base_test_server.cc',
874 'test/spawned_test_server/base_test_server.h',
875 'test/spawned_test_server/local_test_server_posix.cc',
876 'test/spawned_test_server/local_test_server_win.cc',
877 'test/spawned_test_server/local_test_server.cc',
878 'test/spawned_test_server/local_test_server.h',
879 'test/spawned_test_server/remote_test_server.cc',
880 'test/spawned_test_server/remote_test_server.h',
881 'test/spawned_test_server/spawned_test_server.h',
882 'test/spawned_test_server/spawner_communicator.cc',
883 'test/spawned_test_server/spawner_communicator.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000884 'url_request/test_url_fetcher_factory.cc',
885 'url_request/test_url_fetcher_factory.h',
886 'url_request/url_request_test_util.cc',
887 'url_request/url_request_test_util.h',
888 ],
889 'conditions': [
Torne (Richard Coles)b2df76e2013-05-13 16:52:09 +0100890 ['OS != "ios"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000891 'dependencies': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000892 '../third_party/protobuf/protobuf.gyp:py_proto',
893 ],
894 }],
895 ['os_posix == 1 and OS != "mac" and OS != "android" and OS != "ios"', {
896 'conditions': [
897 ['use_openssl==1', {
898 'dependencies': [
899 '../third_party/openssl/openssl.gyp:openssl',
900 ],
901 }, {
902 'dependencies': [
903 '../build/linux/system.gyp:ssl',
904 ],
905 }],
906 ],
907 }],
908 ['os_posix == 1 and OS != "mac" and OS != "android" and OS != "ios"', {
909 'conditions': [
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +0100910 ['use_allocator!="none"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000911 'dependencies': [
912 '../base/allocator/allocator.gyp:allocator',
913 ],
914 }],
915 ],
916 }],
917 ['OS != "android"', {
918 'sources!': [
Torne (Richard Coles)b2df76e2013-05-13 16:52:09 +0100919 'test/spawned_test_server/remote_test_server.cc',
920 'test/spawned_test_server/remote_test_server.h',
921 'test/spawned_test_server/spawner_communicator.cc',
922 'test/spawned_test_server/spawner_communicator.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000923 ],
924 }],
925 ['OS == "ios"', {
926 'dependencies': [
927 '../third_party/nss/nss.gyp:nss',
928 ],
929 }],
930 [ 'use_v8_in_net==1', {
931 'dependencies': [
932 'net_with_v8',
933 ],
934 },
935 ],
Ben Murdocheb525c52013-07-10 11:40:50 +0100936 [ 'enable_mdns != 1', {
937 'sources!' : [
938 'dns/mock_mdns_socket_factory.cc',
939 'dns/mock_mdns_socket_factory.h'
940 ]
941 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000942 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000943 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
944 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000945 },
946 {
947 'target_name': 'net_resources',
948 'type': 'none',
949 'variables': {
950 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/net',
951 },
952 'actions': [
953 {
954 'action_name': 'net_resources',
955 'variables': {
956 'grit_grd_file': 'base/net_resources.grd',
957 },
958 'includes': [ '../build/grit_action.gypi' ],
959 },
960 ],
961 'includes': [ '../build/grit_target.gypi' ],
962 },
963 {
964 'target_name': 'http_server',
965 'type': 'static_library',
966 'variables': { 'enable_wexit_time_destructors': 1, },
967 'dependencies': [
968 '../base/base.gyp:base',
969 'net',
970 ],
971 'sources': [
972 'server/http_connection.cc',
973 'server/http_connection.h',
974 'server/http_server.cc',
975 'server/http_server.h',
976 'server/http_server_request_info.cc',
977 'server/http_server_request_info.h',
Ben Murdocha3f7b4e2013-07-24 10:36:34 +0100978 'server/http_server_response_info.cc',
979 'server/http_server_response_info.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000980 'server/web_socket.cc',
981 'server/web_socket.h',
982 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000983 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
984 'msvs_disabled_warnings': [4267, ],
985 },
986 {
987 'target_name': 'dump_cache',
988 'type': 'executable',
989 'dependencies': [
990 '../base/base.gyp:base',
991 'net',
992 'net_test_support',
993 ],
994 'sources': [
995 'tools/dump_cache/cache_dumper.cc',
996 'tools/dump_cache/cache_dumper.h',
997 'tools/dump_cache/dump_cache.cc',
998 'tools/dump_cache/dump_files.cc',
999 'tools/dump_cache/dump_files.h',
1000 'tools/dump_cache/simple_cache_dumper.cc',
1001 'tools/dump_cache/simple_cache_dumper.h',
1002 'tools/dump_cache/upgrade_win.cc',
1003 'tools/dump_cache/upgrade_win.h',
1004 'tools/dump_cache/url_to_filename_encoder.cc',
1005 'tools/dump_cache/url_to_filename_encoder.h',
1006 'tools/dump_cache/url_utilities.h',
1007 'tools/dump_cache/url_utilities.cc',
1008 ],
1009 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1010 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001011 },
1012 ],
1013 'conditions': [
1014 ['use_v8_in_net == 1', {
1015 'targets': [
1016 {
1017 'target_name': 'net_with_v8',
1018 'type': '<(component)',
1019 'variables': { 'enable_wexit_time_destructors': 1, },
1020 'dependencies': [
1021 '../base/base.gyp:base',
Ben Murdochc5cede92014-04-10 11:22:14 +01001022 '../gin/gin.gyp:gin',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +01001023 '../url/url.gyp:url_lib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001024 '../v8/tools/gyp/v8.gyp:v8',
1025 'net'
1026 ],
1027 'defines': [
1028 'NET_IMPLEMENTATION',
1029 ],
1030 'sources': [
1031 'proxy/proxy_resolver_v8.cc',
1032 'proxy/proxy_resolver_v8.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001033 'proxy/proxy_resolver_v8_tracing.cc',
1034 'proxy/proxy_resolver_v8_tracing.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001035 'proxy/proxy_service_v8.cc',
1036 'proxy/proxy_service_v8.h',
1037 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001038 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1039 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001040 },
1041 ],
1042 }],
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001043 ['OS != "ios" and OS != "android"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001044 'targets': [
1045 # iOS doesn't have the concept of simple executables, these targets
1046 # can't be compiled on the platform.
1047 {
1048 'target_name': 'crash_cache',
1049 'type': 'executable',
1050 'dependencies': [
1051 '../base/base.gyp:base',
1052 'net',
1053 'net_test_support',
1054 ],
1055 'sources': [
1056 'tools/crash_cache/crash_cache.cc',
1057 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001058 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1059 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001060 },
1061 {
1062 'target_name': 'crl_set_dump',
1063 'type': 'executable',
1064 'dependencies': [
1065 '../base/base.gyp:base',
1066 'net',
1067 ],
1068 'sources': [
1069 'tools/crl_set_dump/crl_set_dump.cc',
1070 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001071 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1072 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001073 },
1074 {
1075 'target_name': 'dns_fuzz_stub',
1076 'type': 'executable',
1077 'dependencies': [
1078 '../base/base.gyp:base',
1079 'net',
1080 ],
1081 'sources': [
1082 'tools/dns_fuzz_stub/dns_fuzz_stub.cc',
1083 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001084 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1085 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001086 },
1087 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001088 'target_name': 'gdig',
1089 'type': 'executable',
1090 'dependencies': [
1091 '../base/base.gyp:base',
1092 'net',
1093 ],
1094 'sources': [
1095 'tools/gdig/file_net_log.cc',
1096 'tools/gdig/gdig.cc',
1097 ],
1098 },
1099 {
1100 'target_name': 'get_server_time',
1101 'type': 'executable',
1102 'dependencies': [
1103 '../base/base.gyp:base',
1104 '../base/base.gyp:base_i18n',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +01001105 '../url/url.gyp:url_lib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001106 'net',
1107 ],
1108 'sources': [
1109 'tools/get_server_time/get_server_time.cc',
1110 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001111 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1112 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001113 },
1114 {
Torne (Richard Coles)010d83a2014-05-14 12:12:37 +01001115 'target_name': 'hpack_example_generator',
1116 'type': 'executable',
1117 'dependencies': [
1118 '../base/base.gyp:base',
1119 'net',
1120 ],
1121 'sources': [
1122 'spdy/fuzzing/hpack_example_generator.cc',
1123 ],
1124 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1125 'msvs_disabled_warnings': [4267, ],
1126 },
1127 {
1128 'target_name': 'hpack_fuzz_mutator',
1129 'type': 'executable',
1130 'dependencies': [
1131 '../base/base.gyp:base',
1132 'net',
1133 ],
1134 'sources': [
1135 'spdy/fuzzing/hpack_fuzz_mutator.cc',
1136 ],
1137 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1138 'msvs_disabled_warnings': [4267, ],
1139 },
1140 {
1141 'target_name': 'hpack_fuzz_wrapper',
1142 'type': 'executable',
1143 'dependencies': [
1144 '../base/base.gyp:base',
1145 'net',
1146 ],
1147 'sources': [
1148 'spdy/fuzzing/hpack_fuzz_wrapper.cc',
1149 ],
1150 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1151 'msvs_disabled_warnings': [4267, ],
1152 },
1153 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001154 'target_name': 'net_watcher',
1155 'type': 'executable',
1156 'dependencies': [
1157 '../base/base.gyp:base',
1158 'net',
1159 'net_with_v8',
1160 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001161 'conditions': [
1162 [ 'use_glib == 1', {
1163 'dependencies': [
1164 '../build/linux/system.gyp:gconf',
1165 '../build/linux/system.gyp:gio',
1166 ],
1167 },
1168 ],
1169 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001170 'sources': [
1171 'tools/net_watcher/net_watcher.cc',
1172 ],
1173 },
1174 {
1175 'target_name': 'run_testserver',
1176 'type': 'executable',
1177 'dependencies': [
1178 '../base/base.gyp:base',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001179 '../base/base.gyp:test_support_base',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001180 '../testing/gtest.gyp:gtest',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001181 'net_test_support',
1182 ],
1183 'sources': [
1184 'tools/testserver/run_testserver.cc',
1185 ],
1186 },
1187 {
1188 'target_name': 'stress_cache',
1189 'type': 'executable',
1190 'dependencies': [
1191 '../base/base.gyp:base',
1192 'net',
1193 'net_test_support',
1194 ],
1195 'sources': [
Torne (Richard Coles)a1401312014-03-18 10:20:56 +00001196 'disk_cache/blockfile/stress_cache.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001197 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001198 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1199 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001200 },
1201 {
1202 'target_name': 'tld_cleanup',
1203 'type': 'executable',
1204 'dependencies': [
1205 '../base/base.gyp:base',
1206 '../base/base.gyp:base_i18n',
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +01001207 '../net/tools/tld_cleanup/tld_cleanup.gyp:tld_cleanup_util',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001208 ],
1209 'sources': [
1210 'tools/tld_cleanup/tld_cleanup.cc',
1211 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001212 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1213 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001214 },
1215 ],
1216 }],
1217 ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', {
1218 'targets': [
1219 {
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001220 'target_name': 'balsa',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001221 'type': 'static_library',
1222 'dependencies': [
1223 '../base/base.gyp:base',
1224 'net',
1225 ],
1226 'sources': [
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001227 'tools/balsa/balsa_enums.h',
1228 'tools/balsa/balsa_frame.cc',
1229 'tools/balsa/balsa_frame.h',
1230 'tools/balsa/balsa_headers.cc',
1231 'tools/balsa/balsa_headers.h',
1232 'tools/balsa/balsa_headers_token_utils.cc',
1233 'tools/balsa/balsa_headers_token_utils.h',
1234 'tools/balsa/balsa_visitor_interface.h',
1235 'tools/balsa/http_message_constants.cc',
1236 'tools/balsa/http_message_constants.h',
1237 'tools/balsa/noop_balsa_visitor.h',
1238 'tools/balsa/simple_buffer.cc',
1239 'tools/balsa/simple_buffer.h',
1240 'tools/balsa/split.cc',
1241 'tools/balsa/split.h',
Torne (Richard Coles)a3f6a492013-12-18 16:25:09 +00001242 'tools/balsa/string_piece_utils.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001243 ],
1244 },
1245 {
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001246 'target_name': 'epoll_server',
1247 'type': 'static_library',
1248 'dependencies': [
1249 '../base/base.gyp:base',
1250 'net',
1251 ],
1252 'sources': [
1253 'tools/epoll_server/epoll_server.cc',
1254 'tools/epoll_server/epoll_server.h',
1255 ],
1256 },
1257 {
1258 'target_name': 'flip_in_mem_edsm_server_base',
Ben Murdoch2385ea32013-08-06 11:01:04 +01001259 'type': 'static_library',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001260 'cflags': [
1261 '-Wno-deprecated',
1262 ],
1263 'dependencies': [
1264 '../base/base.gyp:base',
1265 '../third_party/openssl/openssl.gyp:openssl',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001266 'balsa',
1267 'epoll_server',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001268 'net',
1269 ],
1270 'sources': [
1271 'tools/dump_cache/url_to_filename_encoder.cc',
1272 'tools/dump_cache/url_to_filename_encoder.h',
1273 'tools/dump_cache/url_utilities.h',
1274 'tools/dump_cache/url_utilities.cc',
1275 'tools/flip_server/acceptor_thread.h',
1276 'tools/flip_server/acceptor_thread.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001277 'tools/flip_server/create_listener.cc',
1278 'tools/flip_server/create_listener.h',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001279 'tools/flip_server/constants.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001280 'tools/flip_server/flip_config.cc',
1281 'tools/flip_server/flip_config.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001282 'tools/flip_server/http_interface.cc',
1283 'tools/flip_server/http_interface.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001284 'tools/flip_server/loadtime_measurement.h',
1285 'tools/flip_server/mem_cache.h',
1286 'tools/flip_server/mem_cache.cc',
1287 'tools/flip_server/output_ordering.cc',
1288 'tools/flip_server/output_ordering.h',
1289 'tools/flip_server/ring_buffer.cc',
1290 'tools/flip_server/ring_buffer.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001291 'tools/flip_server/sm_connection.cc',
1292 'tools/flip_server/sm_connection.h',
1293 'tools/flip_server/sm_interface.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001294 'tools/flip_server/spdy_ssl.cc',
1295 'tools/flip_server/spdy_ssl.h',
1296 'tools/flip_server/spdy_interface.cc',
1297 'tools/flip_server/spdy_interface.h',
1298 'tools/flip_server/spdy_util.cc',
1299 'tools/flip_server/spdy_util.h',
1300 'tools/flip_server/streamer_interface.cc',
1301 'tools/flip_server/streamer_interface.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001302 ],
1303 },
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001304 {
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +00001305 'target_name': 'flip_in_mem_edsm_server_unittests',
1306 'type': 'executable',
1307 'dependencies': [
1308 '../testing/gtest.gyp:gtest',
1309 '../testing/gmock.gyp:gmock',
1310 '../third_party/openssl/openssl.gyp:openssl',
1311 'flip_in_mem_edsm_server_base',
1312 'net',
1313 'net_test_support',
1314 ],
1315 'sources': [
1316 'tools/flip_server/flip_test_utils.cc',
1317 'tools/flip_server/flip_test_utils.h',
1318 'tools/flip_server/http_interface_test.cc',
1319 'tools/flip_server/mem_cache_test.cc',
1320 'tools/flip_server/run_all_tests.cc',
1321 'tools/flip_server/spdy_interface_test.cc',
1322 ],
1323 },
1324 {
Ben Murdoch2385ea32013-08-06 11:01:04 +01001325 'target_name': 'flip_in_mem_edsm_server',
1326 'type': 'executable',
1327 'cflags': [
1328 '-Wno-deprecated',
1329 ],
1330 'dependencies': [
1331 '../base/base.gyp:base',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001332 'flip_in_mem_edsm_server_base',
Ben Murdoch2385ea32013-08-06 11:01:04 +01001333 'net',
1334 ],
1335 'sources': [
1336 'tools/flip_server/flip_in_mem_edsm_server.cc',
1337 ],
1338 },
1339 {
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001340 'target_name': 'quic_base',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001341 'type': 'static_library',
1342 'dependencies': [
1343 '../base/base.gyp:base',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001344 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +01001345 '../crypto/crypto.gyp:crypto',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001346 '../third_party/openssl/openssl.gyp:openssl',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +01001347 '../url/url.gyp:url_lib',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001348 'balsa',
1349 'epoll_server',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001350 'net',
1351 ],
1352 'sources': [
1353 'tools/quic/quic_client.cc',
1354 'tools/quic/quic_client.h',
1355 'tools/quic/quic_client_session.cc',
1356 'tools/quic/quic_client_session.h',
Torne (Richard Coles)1e9bf3e2013-10-31 11:16:26 +00001357 'tools/quic/quic_default_packet_writer.cc',
1358 'tools/quic/quic_default_packet_writer.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001359 'tools/quic/quic_dispatcher.h',
1360 'tools/quic/quic_dispatcher.cc',
1361 'tools/quic/quic_epoll_clock.cc',
1362 'tools/quic/quic_epoll_clock.h',
1363 'tools/quic/quic_epoll_connection_helper.cc',
1364 'tools/quic/quic_epoll_connection_helper.h',
1365 'tools/quic/quic_in_memory_cache.cc',
1366 'tools/quic/quic_in_memory_cache.h',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001367 'tools/quic/quic_packet_writer_wrapper.cc',
1368 'tools/quic/quic_packet_writer_wrapper.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001369 'tools/quic/quic_server.cc',
1370 'tools/quic/quic_server.h',
1371 'tools/quic/quic_server_session.cc',
1372 'tools/quic/quic_server_session.h',
1373 'tools/quic/quic_socket_utils.cc',
1374 'tools/quic/quic_socket_utils.h',
1375 'tools/quic/quic_spdy_client_stream.cc',
1376 'tools/quic/quic_spdy_client_stream.h',
1377 'tools/quic/quic_spdy_server_stream.cc',
1378 'tools/quic/quic_spdy_server_stream.h',
1379 'tools/quic/quic_time_wait_list_manager.h',
1380 'tools/quic/quic_time_wait_list_manager.cc',
1381 'tools/quic/spdy_utils.cc',
1382 'tools/quic/spdy_utils.h',
1383 ],
1384 },
1385 {
1386 'target_name': 'quic_client',
1387 'type': 'executable',
1388 'dependencies': [
1389 '../base/base.gyp:base',
1390 '../third_party/openssl/openssl.gyp:openssl',
1391 'net',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001392 'quic_base',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001393 ],
1394 'sources': [
1395 'tools/quic/quic_client_bin.cc',
1396 ],
1397 },
1398 {
1399 'target_name': 'quic_server',
1400 'type': 'executable',
1401 'dependencies': [
1402 '../base/base.gyp:base',
1403 '../third_party/openssl/openssl.gyp:openssl',
1404 'net',
Torne (Richard Coles)4e180b62013-10-18 15:46:22 +01001405 'quic_base',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001406 ],
1407 'sources': [
1408 'tools/quic/quic_server_bin.cc',
1409 ],
Bo Liu5c02ac12014-05-01 10:37:37 -07001410 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001411 ]
1412 }],
1413 ['OS=="android"', {
1414 'targets': [
1415 {
1416 'target_name': 'net_jni_headers',
1417 'type': 'none',
1418 'sources': [
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001419 'android/java/src/org/chromium/net/AndroidCertVerifyResult.java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001420 'android/java/src/org/chromium/net/AndroidKeyStore.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001421 'android/java/src/org/chromium/net/AndroidNetworkLibrary.java',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001422 'android/java/src/org/chromium/net/AndroidPrivateKey.java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001423 'android/java/src/org/chromium/net/GURLUtils.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001424 'android/java/src/org/chromium/net/NetworkChangeNotifier.java',
1425 'android/java/src/org/chromium/net/ProxyChangeListener.java',
Torne (Richard Coles)1e9bf3e2013-10-31 11:16:26 +00001426 'android/java/src/org/chromium/net/X509Util.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001427 ],
1428 'variables': {
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001429 'jni_gen_package': 'net',
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +00001430 'jni_generator_ptr_type': 'long',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001431 },
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001432 'includes': [ '../build/jni_generator.gypi' ],
1433 },
1434 {
1435 'target_name': 'net_test_jni_headers',
1436 'type': 'none',
1437 'sources': [
1438 'android/javatests/src/org/chromium/net/AndroidKeyStoreTestUtil.java',
1439 ],
1440 'variables': {
1441 'jni_gen_package': 'net',
Torne (Richard Coles)f2477e02013-11-28 11:55:43 +00001442 'jni_generator_ptr_type': 'long',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001443 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001444 'includes': [ '../build/jni_generator.gypi' ],
1445 },
1446 {
1447 'target_name': 'net_java',
1448 'type': 'none',
1449 'variables': {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001450 'java_in_dir': '../net/android/java',
1451 },
1452 'dependencies': [
1453 '../base/base.gyp:base',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001454 'cert_verify_status_android_java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001455 'certificate_mime_types_java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001456 'net_errors_java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001457 'private_key_types_java',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001458 'remote_android_keystore_aidl',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001459 ],
1460 'includes': [ '../build/java.gypi' ],
1461 },
1462 {
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001463 # Processes the interface files for communication with an Android KeyStore
1464 # running in a separate process.
1465 'target_name': 'remote_android_keystore_aidl',
1466 'type': 'none',
1467 'variables': {
1468 'aidl_interface_file': '../net/android/java/src/org/chromium/net/IRemoteAndroidKeyStoreInterface.aidl',
1469 },
1470 'sources': [
1471 '../net/android/java/src/org/chromium/net/IRemoteAndroidKeyStore.aidl',
1472 '../net/android/java/src/org/chromium/net/IRemoteAndroidKeyStoreCallbacks.aidl',
1473 ],
1474 'includes': [ '../build/java_aidl.gypi' ],
1475 },
1476 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001477 'target_name': 'net_java_test_support',
1478 'type': 'none',
1479 'variables': {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001480 'java_in_dir': '../net/test/android/javatests',
1481 },
1482 'includes': [ '../build/java.gypi' ],
1483 },
1484 {
1485 'target_name': 'net_javatests',
1486 'type': 'none',
1487 'variables': {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001488 'java_in_dir': '../net/android/javatests',
1489 },
1490 'dependencies': [
1491 '../base/base.gyp:base',
1492 '../base/base.gyp:base_java_test_support',
1493 'net_java',
1494 ],
1495 'includes': [ '../build/java.gypi' ],
1496 },
1497 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001498 'target_name': 'net_errors_java',
1499 'type': 'none',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001500 'sources': [
1501 'android/java/NetError.template',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001502 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001503 'variables': {
1504 'package_name': 'org/chromium/net',
1505 'template_deps': ['base/net_error_list.h'],
1506 },
1507 'includes': [ '../build/android/java_cpp_template.gypi' ],
1508 },
1509 {
1510 'target_name': 'certificate_mime_types_java',
1511 'type': 'none',
1512 'sources': [
1513 'android/java/CertificateMimeType.template',
1514 ],
1515 'variables': {
1516 'package_name': 'org/chromium/net',
1517 'template_deps': ['base/mime_util_certificate_type_list.h'],
1518 },
1519 'includes': [ '../build/android/java_cpp_template.gypi' ],
1520 },
1521 {
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001522 'target_name': 'cert_verify_status_android_java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001523 'type': 'none',
1524 'sources': [
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001525 'android/java/CertVerifyStatusAndroid.template',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001526 ],
1527 'variables': {
1528 'package_name': 'org/chromium/net',
Torne (Richard Coles)5d1f7b12014-02-21 12:16:55 +00001529 'template_deps': ['android/cert_verify_status_android_list.h'],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001530 },
1531 'includes': [ '../build/android/java_cpp_template.gypi' ],
1532 },
1533 {
1534 'target_name': 'private_key_types_java',
1535 'type': 'none',
1536 'sources': [
1537 'android/java/PrivateKeyType.template',
1538 ],
1539 'variables': {
1540 'package_name': 'org/chromium/net',
1541 'template_deps': ['android/private_key_type_list.h'],
1542 },
1543 'includes': [ '../build/android/java_cpp_template.gypi' ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001544 },
1545 ],
1546 }],
1547 # Special target to wrap a gtest_target_type==shared_library
1548 # net_unittests into an android apk for execution.
1549 # See base.gyp for TODO(jrg)s about this strategy.
1550 ['OS == "android" and gtest_target_type == "shared_library"', {
1551 'targets': [
1552 {
1553 'target_name': 'net_unittests_apk',
1554 'type': 'none',
1555 'dependencies': [
1556 'net_java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001557 'net_javatests',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001558 'net_unittests',
1559 ],
1560 'variables': {
1561 'test_suite_name': 'net_unittests',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001562 },
1563 'includes': [ '../build/apk_test.gypi' ],
1564 },
1565 ],
1566 }],
Torne (Richard Coles)424c4d72013-08-30 15:14:49 +01001567 ['OS == "android" or OS == "linux"', {
1568 'targets': [
1569 {
1570 'target_name': 'disk_cache_memory_test',
1571 'type': 'executable',
1572 'dependencies': [
1573 '../base/base.gyp:base',
1574 'net',
1575 ],
1576 'sources': [
1577 'tools/disk_cache_memory_test/disk_cache_memory_test.cc',
1578 ],
1579 },
1580 ],
1581 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001582 ['test_isolation_mode != "noop"', {
1583 'targets': [
1584 {
1585 'target_name': 'net_unittests_run',
1586 'type': 'none',
1587 'dependencies': [
1588 'net_unittests',
1589 ],
1590 'includes': [
Ben Murdoch7dbb3d52013-07-17 14:55:54 +01001591 '../build/isolate.gypi',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001592 'net_unittests.isolate',
1593 ],
Ben Murdoch7dbb3d52013-07-17 14:55:54 +01001594 'sources': [
1595 'net_unittests.isolate',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001596 ],
1597 },
1598 ],
1599 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001600 ],
1601}