blob: 4b92a917e5f6045471a24a2697f81308be6d0ab2 [file] [log] [blame]
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001# Copyright (c) 2012 The Chromium Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5{
6 'variables': {
7 'chromium_code': 1,
8 },
9 'includes': [
10 '../build/win_precompile.gypi',
11 'base.gypi',
12 ],
13 'targets': [
14 {
15 'target_name': 'base',
16 'type': '<(component)',
17 'toolsets': ['host', 'target'],
18 'variables': {
19 'base_target': 1,
20 'enable_wexit_time_destructors': 1,
21 'optimize': 'max',
22 },
23 'dependencies': [
24 'base_static',
25 'allocator/allocator.gyp:allocator_extension_thunks',
26 '../testing/gtest.gyp:gtest_prod',
27 '../third_party/modp_b64/modp_b64.gyp:modp_b64',
28 'third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
29 ],
30 # TODO(gregoryd): direct_dependent_settings should be shared with the
31 # 64-bit target, but it doesn't work due to a bug in gyp
32 'direct_dependent_settings': {
33 'include_dirs': [
34 '..',
35 ],
36 },
37 'conditions': [
38 ['use_glib==1', {
39 'conditions': [
40 ['chromeos==1', {
41 'sources/': [ ['include', '_chromeos\\.cc$'] ]
42 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000043 ['toolkit_uses_gtk==1', {
44 'dependencies': [
45 '../build/linux/system.gyp:gtk',
46 ],
47 'export_dependent_settings': [
48 '../build/linux/system.gyp:gtk',
49 ],
50 }],
51 ],
52 'dependencies': [
53 'symbolize',
54 '../build/linux/system.gyp:glib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000055 'xdg_mime',
56 ],
57 'defines': [
58 'USE_SYMBOLIZE',
59 ],
60 'cflags': [
61 '-Wno-write-strings',
62 ],
63 'export_dependent_settings': [
64 '../build/linux/system.gyp:glib',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000065 ],
66 }, { # use_glib!=1
67 'sources/': [
68 ['exclude', '/xdg_user_dirs/'],
69 ['exclude', '_nss\\.cc$'],
70 ],
71 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +000072 ['use_x11==1', {
73 'dependencies': [
74 '../build/linux/system.gyp:x11',
75 ],
76 'export_dependent_settings': [
77 '../build/linux/system.gyp:x11',
78 ],
79 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000080 ['OS == "android" and _toolset == "host"', {
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +000081 # Always build base as a static_library for host toolset, even if
82 # we're doing a component build. Specifically, we only care about the
83 # target toolset using components since that's what developers are
84 # focusing on. In theory we should do this more generally for all
85 # targets when building for host, but getting the gyp magic
86 # per-toolset for the "component" variable is hard, and we really only
87 # need base on host.
88 'type': 'static_library',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000089 # Base for host support is the minimum required to run the
90 # ssl false start blacklist tool. It requires further changes
91 # to generically support host builds (and tests).
92 # Note: when building for host, gyp has OS == "android",
93 # hence the *_android.cc files are included but the actual code
94 # doesn't have OS_ANDROID / ANDROID defined.
95 'conditions': [
96 # Host build on linux depends on system.gyp::gtk as
97 # default linux build has TOOLKIT_GTK defined.
98 ['host_os == "linux"', {
99 'sources/': [
100 ['include', '^atomicops_internals_x86_gcc\\.cc$'],
101 ],
102 'dependencies': [
103 '../build/linux/system.gyp:gtk',
104 ],
105 'export_dependent_settings': [
106 '../build/linux/system.gyp:gtk',
107 ],
108 }],
109 ['host_os == "mac"', {
110 'sources/': [
111 ['exclude', '^native_library_linux\\.cc$'],
112 ['exclude', '^process_util_linux\\.cc$'],
113 ['exclude', '^sys_info_linux\\.cc$'],
114 ['exclude', '^sys_string_conversions_linux\\.cc$'],
115 ['exclude', '^worker_pool_linux\\.cc$'],
116 ],
117 }],
118 ],
119 }],
120 ['OS == "android" and _toolset == "target"', {
121 'conditions': [
122 ['target_arch == "ia32"', {
123 'sources/': [
124 ['include', '^atomicops_internals_x86_gcc\\.cc$'],
125 ],
126 }],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100127 ['target_arch == "mipsel"', {
128 'sources/': [
129 ['include', '^atomicops_internals_mips_gcc\\.cc$'],
130 ],
131 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000132 ],
133 'dependencies': [
134 'base_jni_headers',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000135 '../third_party/ashmem/ashmem.gyp:ashmem',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000136 ],
137 'include_dirs': [
138 '<(SHARED_INTERMEDIATE_DIR)/base',
139 ],
140 'link_settings': {
141 'libraries': [
142 '-llog',
143 ],
144 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000145 'sources!': [
146 'debug/stack_trace_posix.cc',
147 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000148 'includes': [
149 '../build/android/cpufeatures.gypi',
150 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000151 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000152 ['OS == "android" and _toolset == "target" and android_webview_build == 0', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000153 'dependencies': [
154 'base_java',
155 ],
156 }],
157 ['os_bsd==1', {
158 'include_dirs': [
159 '/usr/local/include',
160 ],
161 'link_settings': {
162 'libraries': [
163 '-L/usr/local/lib -lexecinfo',
164 ],
165 },
166 }],
167 ['OS == "linux"', {
168 'link_settings': {
169 'libraries': [
170 # We need rt for clock_gettime().
171 '-lrt',
172 # For 'native_library_linux.cc'
173 '-ldl',
174 ],
175 },
Ben Murdocheb525c52013-07-10 11:40:50 +0100176 'conditions': [
177 ['linux_use_tcmalloc==0', {
178 'defines': [
179 'NO_TCMALLOC',
180 ],
181 'direct_dependent_settings': {
182 'defines': [
183 'NO_TCMALLOC',
184 ],
185 },
186 }],
187 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000188 }],
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +0100189 ['OS == "mac" or (OS == "ios" and _toolset == "host")', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000190 'link_settings': {
191 'libraries': [
192 '$(SDKROOT)/System/Library/Frameworks/AppKit.framework',
193 '$(SDKROOT)/System/Library/Frameworks/ApplicationServices.framework',
194 '$(SDKROOT)/System/Library/Frameworks/Carbon.framework',
195 '$(SDKROOT)/System/Library/Frameworks/CoreFoundation.framework',
196 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework',
197 '$(SDKROOT)/System/Library/Frameworks/IOKit.framework',
198 '$(SDKROOT)/System/Library/Frameworks/Security.framework',
199 ],
200 },
201 'dependencies': [
202 '../third_party/mach_override/mach_override.gyp:mach_override',
203 ],
204 }],
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +0100205 ['OS == "ios" and _toolset != "host"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000206 'link_settings': {
207 'libraries': [
208 '$(SDKROOT)/System/Library/Frameworks/CoreFoundation.framework',
209 '$(SDKROOT)/System/Library/Frameworks/CoreGraphics.framework',
210 '$(SDKROOT)/System/Library/Frameworks/CoreText.framework',
211 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework',
212 '$(SDKROOT)/System/Library/Frameworks/UIKit.framework',
213 ],
214 },
215 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000216 ['OS != "win" and OS != "ios"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000217 'dependencies': ['../third_party/libevent/libevent.gyp:libevent'],
218 },],
219 ['component=="shared_library"', {
220 'conditions': [
221 ['OS=="win"', {
222 'sources!': [
223 'debug/debug_on_start_win.cc',
224 ],
225 }],
226 ],
227 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000228 ['use_system_nspr==1', {
229 'dependencies': [
230 'third_party/nspr/nspr.gyp:nspr',
231 ],
232 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000233 ],
234 'sources': [
235 'third_party/nspr/prcpucfg.h',
236 'third_party/nspr/prcpucfg_win.h',
237 'third_party/nspr/prtypes.h',
238 'third_party/xdg_user_dirs/xdg_user_dir_lookup.cc',
239 'third_party/xdg_user_dirs/xdg_user_dir_lookup.h',
240 'auto_reset.h',
241 'event_recorder.h',
242 'event_recorder_stubs.cc',
243 'event_recorder_win.cc',
244 'linux_util.cc',
245 'linux_util.h',
246 'md5.cc',
247 'md5.h',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100248 'message_loop/message_pump_android.cc',
249 'message_loop/message_pump_android.h',
250 'message_loop/message_pump_glib.cc',
251 'message_loop/message_pump_glib.h',
252 'message_loop/message_pump_gtk.cc',
253 'message_loop/message_pump_gtk.h',
254 'message_loop/message_pump_io_ios.cc',
255 'message_loop/message_pump_io_ios.h',
256 'message_loop/message_pump_observer.h',
257 'message_loop/message_pump_aurax11.cc',
258 'message_loop/message_pump_aurax11.h',
259 'message_loop/message_pump_libevent.cc',
260 'message_loop/message_pump_libevent.h',
261 'message_loop/message_pump_mac.h',
262 'message_loop/message_pump_mac.mm',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000263 'metrics/field_trial.cc',
264 'metrics/field_trial.h',
265 'posix/file_descriptor_shuffle.cc',
266 'posix/file_descriptor_shuffle.h',
267 'sync_socket.h',
268 'sync_socket_win.cc',
269 'sync_socket_posix.cc',
270 ],
271 },
272 {
273 'target_name': 'base_i18n',
274 'type': '<(component)',
275 'variables': {
276 'enable_wexit_time_destructors': 1,
277 'optimize': 'max',
278 },
279 'dependencies': [
280 'base',
281 'third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
282 '../third_party/icu/icu.gyp:icui18n',
283 '../third_party/icu/icu.gyp:icuuc',
284 ],
285 'conditions': [
286 ['toolkit_uses_gtk==1', {
287 'dependencies': [
288 # i18n/rtl.cc uses gtk
289 '../build/linux/system.gyp:gtk',
290 ],
291 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000292 ['OS == "win"', {
293 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
294 'msvs_disabled_warnings': [
295 4267,
296 ],
297 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000298 ],
299 'export_dependent_settings': [
300 'base',
301 ],
302 'defines': [
303 'BASE_I18N_IMPLEMENTATION',
304 ],
305 'sources': [
306 'i18n/base_i18n_export.h',
307 'i18n/bidi_line_iterator.cc',
308 'i18n/bidi_line_iterator.h',
309 'i18n/break_iterator.cc',
310 'i18n/break_iterator.h',
311 'i18n/char_iterator.cc',
312 'i18n/char_iterator.h',
313 'i18n/case_conversion.cc',
314 'i18n/case_conversion.h',
315 'i18n/file_util_icu.cc',
316 'i18n/file_util_icu.h',
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +0100317 'i18n/i18n_constants.cc',
318 'i18n/i18n_constants.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000319 'i18n/icu_encoding_detection.cc',
320 'i18n/icu_encoding_detection.h',
321 'i18n/icu_string_conversions.cc',
322 'i18n/icu_string_conversions.h',
323 'i18n/icu_util.cc',
324 'i18n/icu_util.h',
325 'i18n/number_formatting.cc',
326 'i18n/number_formatting.h',
327 'i18n/rtl.cc',
328 'i18n/rtl.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100329 'i18n/string_compare.cc',
330 'i18n/string_compare.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000331 'i18n/string_search.cc',
332 'i18n/string_search.h',
333 'i18n/time_formatting.cc',
334 'i18n/time_formatting.h',
335 ],
336 },
337 {
338 'target_name': 'base_prefs',
339 'type': '<(component)',
340 'variables': {
341 'enable_wexit_time_destructors': 1,
342 'optimize': 'max',
343 },
344 'dependencies': [
345 'base',
346 ],
347 'export_dependent_settings': [
348 'base',
349 ],
350 'defines': [
351 'BASE_PREFS_IMPLEMENTATION',
352 ],
353 'sources': [
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000354 'prefs/base_prefs_export.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000355 'prefs/default_pref_store.cc',
356 'prefs/default_pref_store.h',
357 'prefs/json_pref_store.cc',
358 'prefs/json_pref_store.h',
359 'prefs/overlay_user_pref_store.cc',
360 'prefs/overlay_user_pref_store.h',
361 'prefs/persistent_pref_store.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000362 'prefs/pref_change_registrar.cc',
363 'prefs/pref_change_registrar.h',
364 'prefs/pref_member.cc',
365 'prefs/pref_member.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000366 'prefs/pref_notifier.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000367 'prefs/pref_notifier_impl.cc',
368 'prefs/pref_notifier_impl.h',
369 'prefs/pref_observer.h',
370 'prefs/pref_registry.cc',
371 'prefs/pref_registry.h',
372 'prefs/pref_registry_simple.cc',
373 'prefs/pref_registry_simple.h',
374 'prefs/pref_service.cc',
375 'prefs/pref_service.h',
376 'prefs/pref_service_builder.cc',
377 'prefs/pref_service_builder.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000378 'prefs/pref_store.cc',
379 'prefs/pref_store.h',
380 'prefs/pref_value_map.cc',
381 'prefs/pref_value_map.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000382 'prefs/pref_value_store.cc',
383 'prefs/pref_value_store.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000384 'prefs/value_map_pref_store.cc',
385 'prefs/value_map_pref_store.h',
386 ],
387 },
388 {
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000389 'target_name': 'base_prefs_test_support',
390 'type': 'static_library',
391 'dependencies': [
392 'base',
393 'base_prefs',
394 '../testing/gmock.gyp:gmock',
395 ],
396 'sources': [
397 'prefs/mock_pref_change_callback.cc',
398 'prefs/pref_store_observer_mock.cc',
399 'prefs/pref_store_observer_mock.h',
400 'prefs/testing_pref_service.cc',
401 'prefs/testing_pref_service.h',
402 'prefs/testing_pref_store.cc',
403 'prefs/testing_pref_store.h',
404 ],
405 },
406 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000407 # This is the subset of files from base that should not be used with a
408 # dynamic library. Note that this library cannot depend on base because
409 # base depends on base_static.
410 'target_name': 'base_static',
411 'type': 'static_library',
412 'variables': {
413 'enable_wexit_time_destructors': 1,
414 'optimize': 'max',
415 },
416 'toolsets': ['host', 'target'],
417 'sources': [
418 'base_switches.cc',
419 'base_switches.h',
420 'win/pe_image.cc',
421 'win/pe_image.h',
422 ],
423 'include_dirs': [
424 '..',
425 ],
426 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000427 # Include this target for a main() function that simply instantiates
428 # and runs a base::TestSuite.
429 {
430 'target_name': 'run_all_unittests',
431 'type': 'static_library',
432 'dependencies': [
433 'test_support_base',
434 ],
435 'sources': [
436 'test/run_all_unittests.cc',
437 ],
438 },
439 {
440 'target_name': 'base_unittests',
441 'type': '<(gtest_target_type)',
442 'sources': [
443 # Tests.
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100444 'android/activity_status_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000445 'android/jni_android_unittest.cc',
446 'android/jni_array_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000447 'android/jni_string_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000448 'android/path_utils_unittest.cc',
449 'android/scoped_java_ref_unittest.cc',
450 'at_exit_unittest.cc',
451 'atomicops_unittest.cc',
452 'base64_unittest.cc',
453 'bind_helpers_unittest.cc',
454 'bind_unittest.cc',
455 'bind_unittest.nc',
456 'bits_unittest.cc',
457 'build_time_unittest.cc',
458 'callback_unittest.cc',
459 'callback_unittest.nc',
460 'cancelable_callback_unittest.cc',
461 'command_line_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100462 'containers/hash_tables_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000463 'containers/linked_list_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000464 'containers/mru_cache_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000465 'containers/small_map_unittest.cc',
466 'containers/stack_container_unittest.cc',
467 'cpu_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000468 'debug/crash_logging_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000469 'debug/leak_tracker_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100470 'debug/proc_maps_linux_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000471 'debug/stack_trace_unittest.cc',
Ben Murdochbbcdd452013-07-25 10:06:34 +0100472 'debug/trace_event_memory_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000473 'debug/trace_event_unittest.cc',
474 'debug/trace_event_unittest.h',
475 'debug/trace_event_win_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100476 'deferred_sequenced_task_runner_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000477 'environment_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000478 'file_util_unittest.cc',
479 'file_version_info_unittest.cc',
480 'files/dir_reader_posix_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000481 'files/file_path_unittest.cc',
482 'files/file_util_proxy_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000483 'files/important_file_writer_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000484 'files/scoped_temp_dir_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000485 'gmock_unittest.cc',
486 'guid_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000487 'id_map_unittest.cc',
488 'i18n/break_iterator_unittest.cc',
489 'i18n/char_iterator_unittest.cc',
490 'i18n/case_conversion_unittest.cc',
491 'i18n/file_util_icu_unittest.cc',
492 'i18n/icu_string_conversions_unittest.cc',
493 'i18n/number_formatting_unittest.cc',
494 'i18n/rtl_unittest.cc',
495 'i18n/string_search_unittest.cc',
496 'i18n/time_formatting_unittest.cc',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100497 'ini_parser_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000498 'ios/device_util_unittest.mm',
499 'json/json_parser_unittest.cc',
500 'json/json_reader_unittest.cc',
501 'json/json_value_converter_unittest.cc',
502 'json/json_value_serializer_unittest.cc',
503 'json/json_writer_unittest.cc',
504 'json/string_escape_unittest.cc',
505 'lazy_instance_unittest.cc',
506 'logging_unittest.cc',
507 'mac/bind_objc_block_unittest.mm',
508 'mac/foundation_util_unittest.mm',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000509 'mac/libdispatch_task_runner_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000510 'mac/mac_util_unittest.mm',
511 'mac/objc_property_releaser_unittest.mm',
Ben Murdocheb525c52013-07-10 11:40:50 +0100512 'mac/scoped_nsobject_unittest.mm',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000513 'mac/scoped_sending_event_unittest.mm',
514 'md5_unittest.cc',
515 'memory/aligned_memory_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000516 'memory/discardable_memory_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000517 'memory/linked_ptr_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000518 'memory/ref_counted_memory_unittest.cc',
519 'memory/ref_counted_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000520 'memory/scoped_ptr_unittest.cc',
521 'memory/scoped_ptr_unittest.nc',
522 'memory/scoped_vector_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100523 'memory/shared_memory_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000524 'memory/singleton_unittest.cc',
525 'memory/weak_ptr_unittest.cc',
526 'memory/weak_ptr_unittest.nc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100527 'message_loop/message_loop_proxy_impl_unittest.cc',
528 'message_loop/message_loop_proxy_unittest.cc',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100529 'message_loop/message_loop_unittest.cc',
530 'message_loop/message_pump_glib_unittest.cc',
531 'message_loop/message_pump_io_ios_unittest.cc',
532 'message_loop/message_pump_libevent_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000533 'metrics/sample_map_unittest.cc',
534 'metrics/sample_vector_unittest.cc',
535 'metrics/bucket_ranges_unittest.cc',
536 'metrics/field_trial_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000537 'metrics/histogram_base_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000538 'metrics/histogram_unittest.cc',
539 'metrics/sparse_histogram_unittest.cc',
540 'metrics/stats_table_unittest.cc',
541 'metrics/statistics_recorder_unittest.cc',
542 'observer_list_unittest.cc',
543 'os_compat_android_unittest.cc',
544 'path_service_unittest.cc',
545 'pickle_unittest.cc',
546 'platform_file_unittest.cc',
547 'posix/file_descriptor_shuffle_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000548 'posix/unix_domain_socket_linux_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100549 'power_monitor/power_monitor_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000550 'prefs/default_pref_store_unittest.cc',
551 'prefs/json_pref_store_unittest.cc',
552 'prefs/mock_pref_change_callback.h',
553 'prefs/overlay_user_pref_store_unittest.cc',
554 'prefs/pref_change_registrar_unittest.cc',
555 'prefs/pref_member_unittest.cc',
556 'prefs/pref_notifier_impl_unittest.cc',
557 'prefs/pref_service_unittest.cc',
558 'prefs/pref_value_map_unittest.cc',
559 'prefs/pref_value_store_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100560 'process/memory_unittest.cc',
561 'process/memory_unittest_mac.h',
562 'process/memory_unittest_mac.mm',
Ben Murdochca12bfa2013-07-23 11:17:05 +0100563 'process/process_util_unittest.cc',
564 'process/process_util_unittest_ios.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000565 'profiler/tracked_time_unittest.cc',
566 'rand_util_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000567 'safe_numerics_unittest.cc',
568 'safe_numerics_unittest.nc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100569 'scoped_clear_errno_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000570 'scoped_native_library_unittest.cc',
571 'scoped_observer.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000572 'security_unittest.cc',
573 'sequence_checker_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000574 'sha1_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000575 'stl_util_unittest.cc',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100576 'strings/nullable_string16_unittest.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100577 'strings/string16_unittest.cc',
578 'strings/stringprintf_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000579 'strings/string_number_conversions_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100580 'strings/string_piece_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000581 'strings/string_split_unittest.cc',
582 'strings/string_tokenizer_unittest.cc',
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100583 'strings/string_util_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000584 'strings/stringize_macros_unittest.cc',
585 'strings/sys_string_conversions_mac_unittest.mm',
586 'strings/sys_string_conversions_unittest.cc',
587 'strings/utf_offset_string_conversions_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100588 'strings/utf_string_conversions_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000589 'synchronization/cancellation_flag_unittest.cc',
590 'synchronization/condition_variable_unittest.cc',
591 'synchronization/lock_unittest.cc',
592 'synchronization/waitable_event_unittest.cc',
593 'synchronization/waitable_event_watcher_unittest.cc',
594 'sys_info_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000595 'system_monitor/system_monitor_unittest.cc',
596 'task_runner_util_unittest.cc',
597 'template_util_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000598 'test/expectations/expectation_unittest.cc',
599 'test/expectations/parser_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000600 'test/trace_event_analyzer_unittest.cc',
601 'threading/non_thread_safe_unittest.cc',
602 'threading/platform_thread_unittest.cc',
603 'threading/sequenced_worker_pool_unittest.cc',
604 'threading/simple_thread_unittest.cc',
605 'threading/thread_checker_unittest.cc',
606 'threading/thread_collision_warner_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000607 'threading/thread_id_name_manager_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000608 'threading/thread_local_storage_unittest.cc',
609 'threading/thread_local_unittest.cc',
610 'threading/thread_unittest.cc',
611 'threading/watchdog_unittest.cc',
612 'threading/worker_pool_posix_unittest.cc',
613 'threading/worker_pool_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100614 'time/pr_time_unittest.cc',
615 'time/time_unittest.cc',
616 'time/time_win_unittest.cc',
617 'timer/hi_res_timer_manager_unittest.cc',
618 'timer/timer_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000619 'tools_sanity_unittest.cc',
620 'tracked_objects_unittest.cc',
621 'tuple_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000622 'values_unittest.cc',
623 'version_unittest.cc',
624 'vlog_unittest.cc',
625 'win/dllmain.cc',
626 'win/enum_variant_unittest.cc',
627 'win/event_trace_consumer_unittest.cc',
628 'win/event_trace_controller_unittest.cc',
629 'win/event_trace_provider_unittest.cc',
630 'win/i18n_unittest.cc',
631 'win/iunknown_impl_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100632 'win/message_window_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000633 'win/object_watcher_unittest.cc',
634 'win/pe_image_unittest.cc',
635 'win/registry_unittest.cc',
636 'win/sampling_profiler_unittest.cc',
637 'win/scoped_bstr_unittest.cc',
638 'win/scoped_comptr_unittest.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000639 'win/scoped_handle_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000640 'win/scoped_process_information_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100641 'win/scoped_variant_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000642 'win/shortcut_unittest.cc',
643 'win/startup_information_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000644 'win/win_util_unittest.cc',
645 'win/wrapped_window_proc_unittest.cc',
646 ],
647 'dependencies': [
648 'base',
649 'base_i18n',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000650 'base_prefs',
651 'base_prefs_test_support',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000652 'base_static',
653 'run_all_unittests',
654 'test_support_base',
655 'third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
656 '../testing/gmock.gyp:gmock',
657 '../testing/gtest.gyp:gtest',
658 '../third_party/icu/icu.gyp:icui18n',
659 '../third_party/icu/icu.gyp:icuuc',
660 ],
661 'includes': ['../build/nocompile.gypi'],
662 'variables': {
663 # TODO(ajwong): Is there a way to autodetect this?
664 'module_dir': 'base'
665 },
666 'conditions': [
Ben Murdoch7dbb3d52013-07-17 14:55:54 +0100667 ['use_glib==1', {
Ben Murdocheb525c52013-07-10 11:40:50 +0100668 'defines': [
669 'USE_SYMBOLIZE',
670 ],
671 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000672 ['OS == "android"', {
673 'dependencies': [
674 'android/jni_generator/jni_generator.gyp:jni_generator_tests',
675 ],
676 'conditions': [
677 ['gtest_target_type == "shared_library"', {
678 'dependencies': [
679 '../testing/android/native_test.gyp:native_test_native_code',
680 ],
681 }],
682 ],
683 }],
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +0100684 ['OS == "ios" and _toolset != "host"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000685 'sources/': [
686 # Only test the iOS-meaningful portion of process_utils.
Ben Murdocheb525c52013-07-10 11:40:50 +0100687 ['exclude', '^process/memory_unittest'],
Ben Murdochca12bfa2013-07-23 11:17:05 +0100688 ['exclude', '^process/process_util_unittest\\.cc$'],
689 ['include', '^process/process_util_unittest_ios\\.cc$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000690 # Requires spawning processes.
691 ['exclude', '^metrics/stats_table_unittest\\.cc$'],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000692 # iOS does not use message_pump_libevent.
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100693 ['exclude', '^message_loop/message_pump_libevent_unittest\\.cc$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000694 ],
695 'conditions': [
696 ['coverage != 0', {
697 'sources!': [
698 # These sources can't be built with coverage due to a toolchain
699 # bug: http://openradar.appspot.com/radar?id=1499403
700 'json/json_reader_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100701 'strings/string_piece_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000702
703 # These tests crash when run with coverage turned on due to an
704 # issue with llvm_gcda_increment_indirect_counter:
705 # http://crbug.com/156058
706 'debug/trace_event_unittest.cc',
707 'debug/trace_event_unittest.h',
708 'logging_unittest.cc',
709 'string_util_unittest.cc',
710 'test/trace_event_analyzer_unittest.cc',
711 'utf_offset_string_conversions_unittest.cc',
712 ],
713 }],
714 ],
715 'actions': [
716 {
717 'action_name': 'copy_test_data',
718 'variables': {
719 'test_data_files': [
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100720 'test/data',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000721 ],
722 'test_data_prefix': 'base',
723 },
724 'includes': [ '../build/copy_test_data_ios.gypi' ],
725 },
726 ],
727 }],
728 ['use_glib==1', {
729 'sources!': [
730 'file_version_info_unittest.cc',
731 ],
732 'conditions': [
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000733 [ 'toolkit_uses_gtk==1', {
734 'sources': [
735 'nix/xdg_util_unittest.cc',
736 ],
737 'dependencies': [
738 '../build/linux/system.gyp:gtk',
739 ]
740 }],
741 ],
742 'dependencies': [
743 '../build/linux/system.gyp:glib',
744 '../build/linux/system.gyp:ssl',
745 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
746 ],
747 }, { # use_glib!=1
748 'sources!': [
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100749 'message_loop/message_pump_glib_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000750 ]
751 }],
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100752 ['use_ozone == 1', {
753 'sources!': [
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100754 'message_loop/message_pump_glib_unittest.cc',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100755 ]
756 }],
Ben Murdocheb525c52013-07-10 11:40:50 +0100757 ['OS == "linux" and linux_use_tcmalloc==1', {
758 'dependencies': [
759 'allocator/allocator.gyp:allocator',
760 ],
761 },
762 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000763 ['OS == "win"', {
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100764 # This is needed to trigger the dll copy step on windows.
765 # TODO(mark): This should not be necessary.
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000766 'dependencies': [
767 '../third_party/icu/icu.gyp:icudata',
768 ],
769 'sources!': [
770 'file_descriptor_shuffle_unittest.cc',
771 'files/dir_reader_posix_unittest.cc',
772 'threading/worker_pool_posix_unittest.cc',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100773 'message_loop/message_pump_libevent_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000774 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000775 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
776 'msvs_disabled_warnings': [
777 4267,
778 ],
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +0100779 # This is needed so base_unittests uses the allocator shim, as
780 # SecurityTest.MemoryAllocationRestriction* tests are dependent
781 # on tcmalloc.
782 # TODO(wfh): crbug.com/246278 Move tcmalloc specific tests into
783 # their own test suite.
784 'conditions': [
785 ['win_use_allocator_shim==1', {
786 'dependencies': [
787 'allocator/allocator.gyp:allocator',
788 ],
789 }],
790 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000791 }, { # OS != "win"
792 'dependencies': [
793 '../third_party/libevent/libevent.gyp:libevent'
794 ],
795 'sources/': [
796 ['exclude', '^win/'],
797 ],
798 'sources!': [
799 'debug/trace_event_win_unittest.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100800 'time/time_win_unittest.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000801 'win/win_util_unittest.cc',
802 ],
803 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000804 ['use_system_nspr==1', {
805 'dependencies': [
806 'third_party/nspr/nspr.gyp:nspr',
807 ],
808 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000809 ], # conditions
810 'target_conditions': [
Torne (Richard Coles)a93a17c2013-05-15 11:34:50 +0100811 ['OS == "ios" and _toolset != "host"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000812 'sources/': [
813 # Pull in specific Mac files for iOS (which have been filtered out
814 # by file name rules).
815 ['include', '^mac/objc_property_releaser_unittest\\.mm$'],
816 ['include', '^mac/bind_objc_block_unittest\\.mm$'],
Ben Murdocheb525c52013-07-10 11:40:50 +0100817 ['include', '^mac/scoped_nsobject_unittest\\.mm$'],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000818 ['include', '^sys_string_conversions_mac_unittest\\.mm$'],
819 ],
820 }],
Ben Murdocheb525c52013-07-10 11:40:50 +0100821 ['OS == "android"', {
822 'sources/': [
823 ['include', '^debug/proc_maps_linux_unittest\\.cc$'],
824 ],
825 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000826 ], # target_conditions
827 },
828 {
829 'target_name': 'test_support_base',
830 'type': 'static_library',
831 'dependencies': [
832 'base',
833 'base_static',
834 'base_i18n',
835 '../testing/gmock.gyp:gmock',
836 '../testing/gtest.gyp:gtest',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +0100837 'third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000838 ],
839 'export_dependent_settings': [
840 'base',
841 ],
842 'conditions': [
843 ['toolkit_uses_gtk==1', {
844 'dependencies': [
845 # test_suite initializes GTK.
846 '../build/linux/system.gyp:gtk',
847 ],
848 }],
849 ['os_posix==0', {
850 'sources!': [
851 'test/scoped_locale.cc',
852 'test/scoped_locale.h',
853 ],
854 }],
855 ['os_bsd==1', {
856 'sources!': [
857 'test/test_file_util_linux.cc',
858 ],
859 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000860 ],
861 'sources': [
862 'perftimer.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000863 'test/expectations/expectation.cc',
864 'test/expectations/expectation.h',
865 'test/expectations/parser.cc',
866 'test/expectations/parser.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000867 'test/mock_chrome_application_mac.h',
868 'test/mock_chrome_application_mac.mm',
869 'test/mock_devices_changed_observer.cc',
870 'test/mock_devices_changed_observer.h',
871 'test/mock_time_provider.cc',
872 'test/mock_time_provider.h',
873 'test/multiprocess_test.cc',
874 'test/multiprocess_test.h',
875 'test/multiprocess_test_android.cc',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000876 'test/null_task_runner.cc',
877 'test/null_task_runner.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000878 'test/perf_test_suite.cc',
879 'test/perf_test_suite.h',
880 'test/scoped_locale.cc',
881 'test/scoped_locale.h',
882 'test/scoped_path_override.cc',
883 'test/scoped_path_override.h',
884 'test/sequenced_task_runner_test_template.cc',
885 'test/sequenced_task_runner_test_template.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000886 'test/sequenced_worker_pool_owner.cc',
887 'test/sequenced_worker_pool_owner.h',
888 'test/simple_test_clock.cc',
889 'test/simple_test_clock.h',
890 'test/simple_test_tick_clock.cc',
891 'test/simple_test_tick_clock.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000892 'test/task_runner_test_template.cc',
893 'test/task_runner_test_template.h',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +0100894 'test/test_file_util.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000895 'test/test_file_util.h',
896 'test/test_file_util_linux.cc',
897 'test/test_file_util_mac.cc',
898 'test/test_file_util_posix.cc',
899 'test/test_file_util_win.cc',
Ben Murdocheb525c52013-07-10 11:40:50 +0100900 'test/test_launcher.cc',
901 'test/test_launcher.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000902 'test/test_listener_ios.h',
903 'test/test_listener_ios.mm',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000904 'test/test_pending_task.cc',
905 'test/test_pending_task.h',
906 'test/test_process_killer_win.cc',
907 'test/test_process_killer_win.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000908 'test/test_reg_util_win.cc',
909 'test/test_reg_util_win.h',
910 'test/test_shortcut_win.cc',
911 'test/test_shortcut_win.h',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000912 'test/test_simple_task_runner.cc',
913 'test/test_simple_task_runner.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000914 'test/test_suite.cc',
915 'test/test_suite.h',
916 'test/test_support_android.cc',
917 'test/test_support_android.h',
918 'test/test_support_ios.h',
919 'test/test_support_ios.mm',
920 'test/test_switches.cc',
921 'test/test_switches.h',
922 'test/test_timeouts.cc',
923 'test/test_timeouts.h',
924 'test/thread_test_helper.cc',
925 'test/thread_test_helper.h',
926 'test/trace_event_analyzer.cc',
927 'test/trace_event_analyzer.h',
928 'test/values_test_util.cc',
929 'test/values_test_util.h',
930 ],
931 'target_conditions': [
932 ['OS == "ios"', {
933 'sources/': [
934 # Pull in specific Mac files for iOS (which have been filtered out
935 # by file name rules).
936 ['include', '^test/test_file_util_mac\\.cc$'],
937 ],
938 }],
939 ], # target_conditions
940 },
941 {
942 'target_name': 'test_support_perf',
943 'type': 'static_library',
944 'dependencies': [
945 'base',
946 '../testing/gtest.gyp:gtest',
947 ],
948 'sources': [
949 'perftimer.cc',
950 'test/run_all_perftests.cc',
951 ],
952 'direct_dependent_settings': {
953 'defines': [
954 'PERF_TEST',
955 ],
956 },
957 'conditions': [
958 ['toolkit_uses_gtk==1', {
959 'dependencies': [
960 # Needed to handle the #include chain:
961 # base/test/perf_test_suite.h
962 # base/test/test_suite.h
963 # gtk/gtk.h
964 '../build/linux/system.gyp:gtk',
965 ],
966 }],
967 ],
968 },
969 ],
970 'conditions': [
971 ['OS!="ios"', {
972 'targets': [
973 {
974 'target_name': 'check_example',
975 'type': 'executable',
976 'sources': [
977 'check_example.cc',
978 ],
979 'dependencies': [
980 'base',
981 ],
982 },
983 ],
984 }],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +0000985 ['OS == "win" and target_arch=="ia32"', {
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000986 'targets': [
987 {
988 'target_name': 'base_nacl_win64',
989 'type': '<(component)',
990 'variables': {
991 'base_target': 1,
992 },
993 'dependencies': [
994 'base_static_win64',
995 'allocator/allocator.gyp:allocator_extension_thunks_win64',
996 'third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations_win64',
997 ],
998 # TODO(gregoryd): direct_dependent_settings should be shared with the
999 # 32-bit target, but it doesn't work due to a bug in gyp
1000 'direct_dependent_settings': {
1001 'include_dirs': [
1002 '..',
1003 ],
1004 },
1005 'defines': [
1006 '<@(nacl_win64_defines)',
1007 ],
1008 'sources!': [
1009 # base64.cc depends on modp_b64.
1010 'base64.cc',
1011 ],
1012 'configurations': {
1013 'Common_Base': {
1014 'msvs_target_platform': 'x64',
1015 },
1016 },
1017 'conditions': [
1018 ['component == "shared_library"', {
1019 'sources!': [
1020 'debug/debug_on_start_win.cc',
1021 ],
1022 }],
1023 ],
1024 },
1025 {
1026 'target_name': 'base_i18n_nacl_win64',
1027 'type': '<(component)',
1028 # TODO(gregoryd): direct_dependent_settings should be shared with the
1029 # 32-bit target, but it doesn't work due to a bug in gyp
1030 'direct_dependent_settings': {
1031 'include_dirs': [
1032 '..',
1033 ],
1034 },
1035 'defines': [
1036 '<@(nacl_win64_defines)',
1037 'BASE_I18N_IMPLEMENTATION',
1038 ],
1039 'include_dirs': [
1040 '..',
1041 ],
1042 'sources': [
1043 'i18n/icu_util_nacl_win64.cc',
1044 ],
1045 'configurations': {
1046 'Common_Base': {
1047 'msvs_target_platform': 'x64',
1048 },
1049 },
1050 },
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001051 {
1052 # TODO(rvargas): Remove this when gyp finally supports a clean model.
1053 # See bug 36232.
1054 'target_name': 'base_static_win64',
1055 'type': 'static_library',
1056 'sources': [
1057 'base_switches.cc',
1058 'base_switches.h',
1059 'win/pe_image.cc',
1060 'win/pe_image.h',
1061 ],
1062 'sources!': [
1063 # base64.cc depends on modp_b64.
1064 'base64.cc',
1065 ],
1066 'include_dirs': [
1067 '..',
1068 ],
1069 'configurations': {
1070 'Common_Base': {
1071 'msvs_target_platform': 'x64',
1072 },
1073 },
1074 'defines': [
1075 'NACL_WIN64',
1076 ],
1077 # TODO(rvargas): Bug 78117. Remove this.
1078 'msvs_disabled_warnings': [
1079 4244,
1080 ],
1081 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001082 ],
1083 }],
1084 ['os_posix==1 and OS!="mac" and OS!="ios"', {
1085 'targets': [
1086 {
1087 'target_name': 'symbolize',
1088 'type': 'static_library',
1089 'toolsets': ['host', 'target'],
1090 'variables': {
1091 'chromium_code': 0,
1092 },
1093 'conditions': [
1094 ['OS == "solaris"', {
1095 'include_dirs': [
1096 '/usr/gnu/include',
1097 '/usr/gnu/include/libelf',
1098 ],
1099 },],
1100 ],
1101 'cflags': [
1102 '-Wno-sign-compare',
1103 ],
1104 'cflags!': [
1105 '-Wextra',
1106 ],
1107 'sources': [
1108 'third_party/symbolize/config.h',
1109 'third_party/symbolize/demangle.cc',
1110 'third_party/symbolize/demangle.h',
1111 'third_party/symbolize/glog/logging.h',
1112 'third_party/symbolize/glog/raw_logging.h',
1113 'third_party/symbolize/symbolize.cc',
1114 'third_party/symbolize/symbolize.h',
1115 'third_party/symbolize/utilities.h',
1116 ],
1117 'include_dirs': [
1118 '..',
1119 ],
1120 },
1121 {
1122 'target_name': 'xdg_mime',
1123 'type': 'static_library',
1124 'toolsets': ['host', 'target'],
1125 'variables': {
1126 'chromium_code': 0,
1127 },
1128 'cflags!': [
1129 '-Wextra',
1130 ],
1131 'sources': [
1132 'third_party/xdg_mime/xdgmime.c',
1133 'third_party/xdg_mime/xdgmime.h',
1134 'third_party/xdg_mime/xdgmimealias.c',
1135 'third_party/xdg_mime/xdgmimealias.h',
1136 'third_party/xdg_mime/xdgmimecache.c',
1137 'third_party/xdg_mime/xdgmimecache.h',
1138 'third_party/xdg_mime/xdgmimeglob.c',
1139 'third_party/xdg_mime/xdgmimeglob.h',
1140 'third_party/xdg_mime/xdgmimeicon.c',
1141 'third_party/xdg_mime/xdgmimeicon.h',
1142 'third_party/xdg_mime/xdgmimeint.c',
1143 'third_party/xdg_mime/xdgmimeint.h',
1144 'third_party/xdg_mime/xdgmimemagic.c',
1145 'third_party/xdg_mime/xdgmimemagic.h',
1146 'third_party/xdg_mime/xdgmimeparent.c',
1147 'third_party/xdg_mime/xdgmimeparent.h',
1148 ],
1149 },
1150 ],
1151 }],
1152 ['OS == "android"', {
1153 'targets': [
1154 {
1155 'target_name': 'base_jni_headers',
1156 'type': 'none',
1157 'sources': [
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001158 'android/java/src/org/chromium/base/ActivityStatus.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001159 'android/java/src/org/chromium/base/BuildInfo.java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001160 'android/java/src/org/chromium/base/CpuFeatures.java',
1161 'android/java/src/org/chromium/base/ImportantFileWriterAndroid.java',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +01001162 'android/java/src/org/chromium/base/MemoryPressureListener.java',
Ben Murdochbb1529c2013-08-08 10:24:53 +01001163 'android/java/src/org/chromium/base/JavaHandlerThread.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001164 'android/java/src/org/chromium/base/PathService.java',
1165 'android/java/src/org/chromium/base/PathUtils.java',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001166 'android/java/src/org/chromium/base/PowerMonitor.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001167 'android/java/src/org/chromium/base/SystemMessageHandler.java',
Ben Murdocheb525c52013-07-10 11:40:50 +01001168 'android/java/src/org/chromium/base/SysUtils.java',
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001169 'android/java/src/org/chromium/base/ThreadUtils.java',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001170 ],
Torne (Richard Coles)b2df76e2013-05-13 16:52:09 +01001171 'conditions': [
1172 ['google_tv==1', {
1173 'sources': [
1174 'android/java/src/org/chromium/base/ContextTypes.java',
1175 ],
1176 }],
1177 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001178 'variables': {
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001179 'jni_gen_package': 'base',
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001180 },
1181 'includes': [ '../build/jni_generator.gypi' ],
1182 },
1183 {
1184 'target_name': 'base_java',
1185 'type': 'none',
1186 'variables': {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001187 'java_in_dir': '../base/android/java',
1188 },
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001189 'dependencies': [
1190 'base_java_activity_state',
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +01001191 'base_java_memory_pressure_level_list',
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001192 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001193 'includes': [ '../build/java.gypi' ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001194 'conditions': [
1195 ['android_webview_build==0', {
1196 'dependencies': [
1197 '../third_party/jsr-305/jsr-305.gyp:jsr_305_javalib',
1198 ],
1199 }]
1200 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001201 },
1202 {
Torne (Richard Coles)c2e0dbd2013-05-09 18:35:53 +01001203 'target_name': 'base_java_activity_state',
1204 'type': 'none',
1205 # This target is used to auto-generate ActivityState.java
1206 # from a template file. The source file contains a list of
1207 # Java constant declarations matching the ones in
1208 # android/activity_state_list.h.
1209 'sources': [
1210 'android/java/src/org/chromium/base/ActivityState.template',
1211 ],
1212 'variables': {
1213 'package_name': 'org/chromium/base',
1214 'template_deps': ['android/activity_state_list.h'],
1215 },
1216 'includes': [ '../build/android/java_cpp_template.gypi' ],
1217 },
1218 {
Torne (Richard Coles)7d4cd472013-06-19 11:58:07 +01001219 'target_name': 'base_java_memory_pressure_level_list',
1220 'type': 'none',
1221 'sources': [
1222 'android/java/src/org/chromium/base/MemoryPressureLevelList.template',
1223 ],
1224 'variables': {
1225 'package_name': 'org/chromium/base',
1226 'template_deps': ['memory/memory_pressure_level_list.h'],
1227 },
1228 'includes': [ '../build/android/java_cpp_template.gypi' ],
1229 },
1230 {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001231 'target_name': 'base_java_test_support',
1232 'type': 'none',
1233 'dependencies': [
1234 'base_java',
1235 ],
1236 'variables': {
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001237 'java_in_dir': '../base/test/android/javatests',
1238 },
1239 'includes': [ '../build/java.gypi' ],
1240 },
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +00001241 {
1242 'target_name': 'base_javatests',
1243 'type': 'none',
1244 'dependencies': [
1245 'base_java',
1246 'base_java_test_support',
1247 ],
1248 'variables': {
1249 'java_in_dir': '../base/android/javatests',
1250 },
1251 'includes': [ '../build/java.gypi' ],
1252 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001253 ],
1254 }],
1255 ['OS == "win"', {
1256 'targets': [
1257 {
1258 'target_name': 'debug_message',
1259 'type': 'executable',
1260 'sources': [
1261 'debug_message.cc',
1262 ],
1263 'msvs_settings': {
1264 'VCLinkerTool': {
1265 'SubSystem': '2', # Set /SUBSYSTEM:WINDOWS
1266 },
1267 },
1268 },
1269 ],
1270 }],
1271 # Special target to wrap a gtest_target_type == shared_library
1272 # base_unittests into an android apk for execution.
1273 # TODO(jrg): lib.target comes from _InstallableTargetInstallPath()
1274 # in the gyp make generator. What is the correct way to extract
1275 # this path from gyp and into 'raw' for input to antfiles?
1276 # Hard-coding in the gypfile seems a poor choice.
1277 ['OS == "android" and gtest_target_type == "shared_library"', {
1278 'targets': [
1279 {
1280 'target_name': 'base_unittests_apk',
1281 'type': 'none',
1282 'dependencies': [
1283 'base_java',
1284 'base_unittests',
1285 ],
1286 'variables': {
1287 'test_suite_name': 'base_unittests',
1288 'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)base_unittests<(SHARED_LIB_SUFFIX)',
1289 },
1290 'includes': [ '../build/apk_test.gypi' ],
1291 },
1292 ],
1293 }],
1294 ['test_isolation_mode != "noop"', {
1295 'targets': [
1296 {
1297 'target_name': 'base_unittests_run',
1298 'type': 'none',
1299 'dependencies': [
1300 'base_unittests',
1301 ],
1302 'includes': [
1303 '../build/isolate.gypi',
1304 'base_unittests.isolate',
1305 ],
1306 'sources': [
1307 'base_unittests.isolate',
1308 ],
1309 },
1310 ],
1311 }],
1312 ],
1313}