Extract the remote calls into the class (1/2)
[chromium-blink-merge.git] / base / BUILD.gn
bloba190ea38f3c4a829c23be072dacf4aa73917d6d3
1 # Copyright (c) 2013 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.
5 import("//build/config/ui.gni")
7 if (is_android) {
8   import("//build/config/android/rules.gni")
11 component("base") {
12   sources = [
13     "third_party/dmg_fp/dmg_fp.h",
14     "third_party/dmg_fp/g_fmt.cc",
15     "third_party/dmg_fp/dtoa_wrapper.cc",
16     "third_party/icu/icu_utf.cc",
17     "third_party/icu/icu_utf.h",
18     "third_party/superfasthash/superfasthash.c",
19     "allocator/allocator_extension.cc",
20     "allocator/allocator_extension.h",
21     "allocator/type_profiler_control.cc",
22     "allocator/type_profiler_control.h",
23     "android/application_status_listener.cc",
24     "android/application_status_listener.h",
25     "android/base_jni_registrar.cc",
26     "android/base_jni_registrar.h",
27     "android/build_info.cc",
28     "android/build_info.h",
29     "android/command_line_android.cc",
30     "android/command_line_android.h",
31     "android/content_uri_utils.cc",
32     "android/content_uri_utils.h",
33     "android/cpu_features.cc",
34     "android/event_log.cc",
35     "android/event_log.h",
36     "android/field_trial_list.cc",
37     "android/field_trial_list.h",
38     "android/fifo_utils.cc",
39     "android/fifo_utils.h",
40     "android/important_file_writer_android.cc",
41     "android/important_file_writer_android.h",
42     "android/scoped_java_ref.cc",
43     "android/scoped_java_ref.h",
44     "android/jni_android.cc",
45     "android/jni_android.h",
46     "android/jni_array.cc",
47     "android/jni_array.h",
48     "android/jni_registrar.cc",
49     "android/jni_registrar.h",
50     "android/jni_string.cc",
51     "android/jni_string.h",
52     "android/jni_utils.cc",
53     "android/jni_utils.h",
54     "android/jni_weak_ref.cc",
55     "android/jni_weak_ref.h",
56     "android/library_loader/library_loader_hooks.cc",
57     "android/library_loader/library_loader_hooks.h",
58     "android/memory_pressure_listener_android.cc",
59     "android/memory_pressure_listener_android.h",
60     "android/java_handler_thread.cc",
61     "android/java_handler_thread.h",
62     "android/path_service_android.cc",
63     "android/path_service_android.h",
64     "android/path_utils.cc",
65     "android/path_utils.h",
66     "android/sys_utils.cc",
67     "android/sys_utils.h",
68     "android/thread_utils.h",
69     "android/trace_event_binding.cc",
70     "android/trace_event_binding.h",
71     "async_socket_io_handler.h",
72     "async_socket_io_handler_posix.cc",
73     "async_socket_io_handler_win.cc",
74     "at_exit.cc",
75     "at_exit.h",
76     "atomic_ref_count.h",
77     "atomic_sequence_num.h",
78     "atomicops.h",
79     "atomicops_internals_gcc.h",
80     "atomicops_internals_mac.h",
81     "atomicops_internals_tsan.h",
82     "atomicops_internals_x86_gcc.cc",
83     "atomicops_internals_x86_gcc.h",
84     "atomicops_internals_x86_msvc.h",
85     "auto_reset.h",
86     "barrier_closure.cc",
87     "barrier_closure.h",
88     "base_export.h",
89     "base_paths.cc",
90     "base_paths.h",
91     "base_paths_android.cc",
92     "base_paths_android.h",
93     "base_paths_mac.h",
94     "base_paths_mac.mm",
95     "base_paths_posix.cc",
96     "base_paths_posix.h",
97     "base_paths_win.cc",
98     "base_paths_win.h",
99     "base_switches.h",
100     "base64.cc",
101     "base64.h",
102     "basictypes.h",
103     "big_endian.cc",
104     "big_endian.h",
105     "bind.h",
106     "bind_helpers.cc",
107     "bind_helpers.h",
108     "bind_internal.h",
109     "bind_internal_win.h",
110     "bits.h",
111     "build_time.cc",
112     "build_time.h",
113     "callback.h",
114     "callback_helpers.cc",
115     "callback_helpers.h",
116     "callback_internal.cc",
117     "callback_internal.h",
118     "cancelable_callback.h",
119     "command_line.cc",
120     "command_line.h",
121     "compiler_specific.h",
122     "containers/adapters.h",
123     "containers/hash_tables.h",
124     "containers/linked_list.h",
125     "containers/mru_cache.h",
126     "containers/small_map.h",
127     "containers/stack_container.h",
128     "cpu.cc",
129     "cpu.h",
130     "critical_closure.h",
131     "critical_closure_internal_ios.mm",
132     "debug/alias.cc",
133     "debug/alias.h",
134     "debug/asan_invalid_access.cc",
135     "debug/asan_invalid_access.h",
136     "debug/crash_logging.cc",
137     "debug/crash_logging.h",
138     "debug/debugger.cc",
139     "debug/debugger.h",
140     "debug/debugger_posix.cc",
141     "debug/debugger_win.cc",
142     "debug/dump_without_crashing.cc",
143     "debug/dump_without_crashing.h",
144     "debug/gdi_debug_util_win.cc",
145     "debug/gdi_debug_util_win.h",
146     # This file depends on files from the "allocator" target,
147     # but this target does not depend on "allocator" (see
148     # allocator.gyp for details).
149     "debug/leak_annotations.h",
150     "debug/leak_tracker.h",
151     "debug/proc_maps_linux.cc",
152     "debug/proc_maps_linux.h",
153     "debug/profiler.cc",
154     "debug/profiler.h",
155     "debug/stack_trace.cc",
156     "debug/stack_trace.h",
157     "debug/stack_trace_android.cc",
158     "debug/stack_trace_posix.cc",
159     "debug/stack_trace_win.cc",
160     "debug/task_annotator.cc",
161     "debug/task_annotator.h",
162     "debug/trace_event.h",
163     "debug/trace_event_android.cc",
164     "debug/trace_event_argument.cc",
165     "debug/trace_event_argument.h",
166     "debug/trace_event_impl.cc",
167     "debug/trace_event_impl.h",
168     "debug/trace_event_impl_constants.cc",
169     "debug/trace_event_memory.cc",
170     "debug/trace_event_memory.h",
171     "debug/trace_event_synthetic_delay.cc",
172     "debug/trace_event_synthetic_delay.h",
173     "debug/trace_event_system_stats_monitor.cc",
174     "debug/trace_event_system_stats_monitor.h",
175     "debug/trace_event_win.cc",
176     "deferred_sequenced_task_runner.cc",
177     "deferred_sequenced_task_runner.h",
178     "environment.cc",
179     "environment.h",
180     "event_recorder.h",
181     "event_recorder_stubs.cc",
182     "event_recorder_win.cc",
183     "file_descriptor_posix.h",
184     "file_version_info.h",
185     "file_version_info_mac.h",
186     "file_version_info_mac.mm",
187     "file_version_info_win.cc",
188     "file_version_info_win.h",
189     "files/dir_reader_fallback.h",
190     "files/dir_reader_linux.h",
191     "files/dir_reader_posix.h",
192     "files/file.cc",
193     "files/file_posix.cc",
194     "files/file_win.cc",
195     "files/file_enumerator.cc",
196     "files/file_enumerator.h",
197     "files/file_enumerator_posix.cc",
198     "files/file_enumerator_win.cc",
199     "files/file_path.cc",
200     "files/file_path.h",
201     "files/file_path_constants.cc",
202     "files/file_path_watcher.cc",
203     "files/file_path_watcher.h",
204     "files/file_path_watcher_fsevents.cc",
205     "files/file_path_watcher_fsevents.h",
206     "files/file_path_watcher_kqueue.cc",
207     "files/file_path_watcher_kqueue.h",
208     "files/file_path_watcher_linux.cc",
209     "files/file_path_watcher_mac.cc",
210     "files/file_path_watcher_win.cc",
211     "files/file_proxy.cc",
212     "files/file_proxy.h",
213     "files/file_util.cc",
214     "files/file_util.h",
215     "files/file_util_android.cc",
216     "files/file_util_linux.cc",
217     "files/file_util_mac.mm",
218     "files/file_util_posix.cc",
219     "files/file_util_proxy.cc",
220     "files/file_util_proxy.h",
221     "files/file_util_win.cc",
222     "files/important_file_writer.cc",
223     "files/important_file_writer.h",
224     "files/memory_mapped_file.cc",
225     "files/memory_mapped_file.h",
226     "files/memory_mapped_file_posix.cc",
227     "files/memory_mapped_file_win.cc",
228     "files/scoped_file.cc",
229     "files/scoped_file.h",
230     "files/scoped_temp_dir.cc",
231     "files/scoped_temp_dir.h",
232     "float_util.h",
233     "format_macros.h",
234     "gtest_prod_util.h",
235     "guid.cc",
236     "guid.h",
237     "guid_posix.cc",
238     "guid_win.cc",
239     "hash.cc",
240     "hash.h",
241     "id_map.h",
242     "ios/device_util.h",
243     "ios/device_util.mm",
244     "ios/ios_util.h",
245     "ios/ios_util.mm",
246     "ios/scoped_critical_action.h",
247     "ios/scoped_critical_action.mm",
248     "json/json_file_value_serializer.cc",
249     "json/json_file_value_serializer.h",
250     "json/json_parser.cc",
251     "json/json_parser.h",
252     "json/json_reader.cc",
253     "json/json_reader.h",
254     "json/json_string_value_serializer.cc",
255     "json/json_string_value_serializer.h",
256     "json/json_value_converter.h",
257     "json/json_writer.cc",
258     "json/json_writer.h",
259     "json/string_escape.cc",
260     "json/string_escape.h",
261     "lazy_instance.cc",
262     "lazy_instance.h",
263     "linux_util.cc",
264     "linux_util.h",
265     "location.cc",
266     "location.h",
267     "logging.cc",
268     "logging.h",
269     "logging_win.cc",
270     "logging_win.h",
271     "mac/authorization_util.h",
272     "mac/authorization_util.mm",
273     "mac/bind_objc_block.h",
274     "mac/bundle_locations.h",
275     "mac/bundle_locations.mm",
276     "mac/cocoa_protocols.h",
277     "mac/foundation_util.h",
278     "mac/foundation_util.mm",
279     "mac/launch_services_util.cc",
280     "mac/launch_services_util.h",
281     "mac/launchd.cc",
282     "mac/launchd.h",
283     "mac/libdispatch_task_runner.cc",
284     "mac/libdispatch_task_runner.h",
285     "mac/mac_logging.h",
286     "mac/mac_logging.cc",
287     "mac/mac_util.h",
288     "mac/mac_util.mm",
289     "mac/mach_logging.cc",
290     "mac/mach_logging.h",
291     "mac/objc_property_releaser.h",
292     "mac/objc_property_releaser.mm",
293     "mac/os_crash_dumps.cc",
294     "mac/os_crash_dumps.h",
295     "mac/scoped_aedesc.h",
296     "mac/scoped_authorizationref.h",
297     "mac/scoped_block.h",
298     "mac/scoped_cftyperef.h",
299     "mac/scoped_ioobject.h",
300     "mac/scoped_ioplugininterface.h",
301     "mac/scoped_launch_data.h",
302     "mac/scoped_mach_port.cc",
303     "mac/scoped_mach_port.h",
304     "mac/scoped_mach_vm.cc",
305     "mac/scoped_mach_vm.h",
306     "mac/scoped_nsautorelease_pool.h",
307     "mac/scoped_nsautorelease_pool.mm",
308     "mac/scoped_nsexception_enabler.h",
309     "mac/scoped_nsexception_enabler.mm",
310     "mac/scoped_nsobject.h",
311     "mac/scoped_objc_class_swizzler.h",
312     "mac/scoped_objc_class_swizzler.mm",
313     "mac/scoped_sending_event.h",
314     "mac/scoped_sending_event.mm",
315     "mac/sdk_forward_declarations.h",
316     "macros.h",
317     "md5.cc",
318     "md5.h",
319     "memory/aligned_memory.cc",
320     "memory/aligned_memory.h",
321     "memory/discardable_memory.cc",
322     "memory/discardable_memory.h",
323     "memory/discardable_memory_android.cc",
324     "memory/discardable_memory_emulated.cc",
325     "memory/discardable_memory_emulated.h",
326     "memory/discardable_memory_linux.cc",
327     "memory/discardable_memory_mac.cc",
328     "memory/discardable_memory_malloc.cc",
329     "memory/discardable_memory_malloc.h",
330     "memory/discardable_memory_manager.cc",
331     "memory/discardable_memory_manager.h",
332     "memory/discardable_memory_win.cc",
333     "memory/linked_ptr.h",
334     "memory/manual_constructor.h",
335     "memory/memory_pressure_listener.cc",
336     "memory/memory_pressure_listener.h",
337     "memory/raw_scoped_refptr_mismatch_checker.h",
338     "memory/ref_counted.cc",
339     "memory/ref_counted.h",
340     "memory/ref_counted_delete_on_message_loop.h",
341     "memory/ref_counted_memory.cc",
342     "memory/ref_counted_memory.h",
343     "memory/scoped_open_process.h",
344     "memory/scoped_policy.h",
345     "memory/scoped_ptr.h",
346     "memory/scoped_vector.h",
347     "memory/shared_memory.h",
348     "memory/shared_memory_android.cc",
349     "memory/shared_memory_nacl.cc",
350     "memory/shared_memory_posix.cc",
351     "memory/shared_memory_win.cc",
352     "memory/singleton.cc",
353     "memory/singleton.h",
354     "memory/weak_ptr.cc",
355     "memory/weak_ptr.h",
356     "message_loop/incoming_task_queue.cc",
357     "message_loop/incoming_task_queue.h",
358     "message_loop/message_loop.cc",
359     "message_loop/message_loop.h",
360     "message_loop/message_loop_proxy.cc",
361     "message_loop/message_loop_proxy.h",
362     "message_loop/message_loop_proxy_impl.cc",
363     "message_loop/message_loop_proxy_impl.h",
364     "message_loop/message_pump.cc",
365     "message_loop/message_pump.h",
366     "message_loop/message_pump_android.cc",
367     "message_loop/message_pump_android.h",
368     "message_loop/message_pump_default.cc",
369     "message_loop/message_pump_default.h",
370     "message_loop/message_pump_glib.cc",
371     "message_loop/message_pump_glib.h",
372     "message_loop/message_pump_io_ios.cc",
373     "message_loop/message_pump_io_ios.h",
374     "message_loop/message_pump_libevent.cc",
375     "message_loop/message_pump_libevent.h",
376     "message_loop/message_pump_mac.h",
377     "message_loop/message_pump_mac.mm",
378     "message_loop/message_pump_win.cc",
379     "message_loop/message_pump_win.h",
380     "metrics/field_trial.cc",
381     "metrics/field_trial.h",
382     "metrics/sample_map.cc",
383     "metrics/sample_map.h",
384     "metrics/sample_vector.cc",
385     "metrics/sample_vector.h",
386     "metrics/bucket_ranges.cc",
387     "metrics/bucket_ranges.h",
388     "metrics/histogram.cc",
389     "metrics/histogram.h",
390     "metrics/histogram_base.cc",
391     "metrics/histogram_base.h",
392     "metrics/histogram_delta_serialization.cc",
393     "metrics/histogram_delta_serialization.",
394     "metrics/histogram_flattener.h",
395     "metrics/histogram_samples.cc",
396     "metrics/histogram_samples.h",
397     "metrics/histogram_snapshot_manager.cc",
398     "metrics/histogram_snapshot_manager.h",
399     "metrics/sparse_histogram.cc",
400     "metrics/sparse_histogram.h",
401     "metrics/statistics_recorder.cc",
402     "metrics/statistics_recorder.h",
403     "metrics/stats_counters.cc",
404     "metrics/stats_counters.h",
405     "metrics/stats_table.cc",
406     "metrics/stats_table.h",
407     "metrics/user_metrics.cc",
408     "metrics/user_metrics.h",
409     "metrics/user_metrics_action.h",
410     "move.h",
411     "native_library.h",
412     "native_library_mac.mm",
413     "native_library_posix.cc",
414     "native_library_win.cc",
415     "numerics/safe_conversions.h",
416     "numerics/safe_conversions_impl.h",
417     "numerics/safe_math.h",
418     "numerics/safe_math_impl.h",
419     "nix/mime_util_xdg.cc",
420     "nix/mime_util_xdg.h",
421     "nix/xdg_util.cc",
422     "nix/xdg_util.h",
423     "observer_list.h",
424     "observer_list_threadsafe.h",
425     "os_compat_android.cc",
426     "os_compat_android.h",
427     "os_compat_nacl.cc",
428     "os_compat_nacl.h",
429     "path_service.cc",
430     "path_service.h",
431     "pending_task.cc",
432     "pending_task.h",
433     "pickle.cc",
434     "pickle.h",
435     "port.h",
436     "posix/eintr_wrapper.h",
437     "posix/file_descriptor_shuffle.cc",
438     "posix/global_descriptors.cc",
439     "posix/global_descriptors.h",
440     "posix/unix_domain_socket_linux.cc",
441     "posix/unix_domain_socket_linux.h",
442     "power_monitor/power_monitor.cc",
443     "power_monitor/power_monitor.h",
444     "power_monitor/power_monitor_device_source.cc",
445     "power_monitor/power_monitor_device_source.h",
446     "power_monitor/power_monitor_device_source_android.cc",
447     "power_monitor/power_monitor_device_source_android.h",
448     "power_monitor/power_monitor_device_source_chromeos.cc",
449     "power_monitor/power_monitor_device_source_ios.mm",
450     "power_monitor/power_monitor_device_source_mac.mm",
451     "power_monitor/power_monitor_device_source_posix.cc",
452     "power_monitor/power_monitor_device_source_win.cc",
453     "power_monitor/power_monitor_source.cc",
454     "power_monitor/power_monitor_source.h",
455     "power_monitor/power_observer.h",
456     "process/internal_linux.cc",
457     "process/internal_linux.h",
458     "process/kill.cc",
459     "process/kill.h",
460     "process/kill_mac.cc",
461     "process/kill_posix.cc",
462     "process/kill_win.cc",
463     "process/launch.cc",
464     "process/launch.h",
465     "process/launch_ios.cc",
466     "process/launch_mac.cc",
467     "process/launch_posix.cc",
468     "process/launch_win.cc",
469     "process/memory.cc",
470     "process/memory.h",
471     "process/memory_linux.cc",
472     "process/memory_mac.mm",
473     "process/memory_win.cc",
474     "process/process.h",
475     "process/process_handle_freebsd.cc",
476     "process/process_handle_linux.cc",
477     "process/process_handle_mac.cc",
478     "process/process_handle_openbsd.cc",
479     "process/process_handle_posix.cc",
480     "process/process_handle_win.cc",
481     "process/process_info.h",
482     "process/process_info_linux.cc",
483     "process/process_info_mac.cc",
484     "process/process_info_win.cc",
485     "process/process_iterator.cc",
486     "process/process_iterator.h",
487     "process/process_iterator_freebsd.cc",
488     "process/process_iterator_linux.cc",
489     "process/process_iterator_mac.cc",
490     "process/process_iterator_openbsd.cc",
491     "process/process_iterator_win.cc",
492     "process/process_linux.cc",
493     "process/process_metrics.cc",
494     "process/process_metrics.h",
495     "process/process_metrics_freebsd.cc",
496     "process/process_metrics_ios.cc",
497     "process/process_metrics_linux.cc",
498     "process/process_metrics_mac.cc",
499     "process/process_metrics_openbsd.cc",
500     "process/process_metrics_posix.cc",
501     "process/process_metrics_win.cc",
502     "process/process_posix.cc",
503     "process/process_win.cc",
504     "profiler/scoped_profile.cc",
505     "profiler/scoped_profile.h",
506     "profiler/alternate_timer.cc",
507     "profiler/alternate_timer.h",
508     "profiler/tracked_time.cc",
509     "profiler/tracked_time.h",
510     "rand_util.cc",
511     "rand_util.h",
512     "rand_util_nacl.cc",
513     "rand_util_posix.cc",
514     "rand_util_win.cc",
515     "run_loop.cc",
516     "run_loop.h",
517     "safe_strerror_posix.cc",
518     "safe_strerror_posix.h",
519     "scoped_generic.h",
520     "scoped_native_library.cc",
521     "scoped_native_library.h",
522     "scoped_observer.h",
523     "sequence_checker.h",
524     "sequence_checker_impl.cc",
525     "sequence_checker_impl.h",
526     "sequenced_task_runner.cc",
527     "sequenced_task_runner.h",
528     "sequenced_task_runner_helpers.h",
529     "sha1.h",
530     "sha1_portable.cc",
531     "sha1_win.cc",
532     "single_thread_task_runner.h",
533     "stl_util.h",
534     "strings/latin1_string_conversions.cc",
535     "strings/latin1_string_conversions.h",
536     "strings/nullable_string16.cc",
537     "strings/nullable_string16.h",
538     "strings/safe_sprintf.cc",
539     "strings/safe_sprintf.h",
540     "strings/string16.cc",
541     "strings/string16.h",
542     "strings/string_number_conversions.cc",
543     "strings/string_split.cc",
544     "strings/string_split.h",
545     "strings/string_number_conversions.h",
546     "strings/string_piece.cc",
547     "strings/string_piece.h",
548     "strings/string_tokenizer.h",
549     "strings/string_util.cc",
550     "strings/string_util.h",
551     "strings/string_util_constants.cc",
552     "strings/string_util_posix.h",
553     "strings/string_util_win.h",
554     "strings/stringize_macros.h",
555     "strings/stringprintf.cc",
556     "strings/stringprintf.h",
557     "strings/sys_string_conversions.h",
558     "strings/sys_string_conversions_mac.mm",
559     "strings/sys_string_conversions_posix.cc",
560     "strings/sys_string_conversions_win.cc",
561     "strings/utf_offset_string_conversions.cc",
562     "strings/utf_offset_string_conversions.h",
563     "strings/utf_string_conversion_utils.cc",
564     "strings/utf_string_conversion_utils.h",
565     "strings/utf_string_conversions.cc",
566     "strings/utf_string_conversions.h",
567     "supports_user_data.cc",
568     "supports_user_data.h",
569     "sync_socket.h",
570     "sync_socket_posix.cc",
571     "sync_socket_win.cc",
572     "synchronization/cancellation_flag.cc",
573     "synchronization/cancellation_flag.h",
574     "synchronization/condition_variable.h",
575     "synchronization/condition_variable_posix.cc",
576     "synchronization/condition_variable_win.cc",
577     "synchronization/lock.cc",
578     "synchronization/lock.h",
579     "synchronization/lock_impl.h",
580     "synchronization/lock_impl_posix.cc",
581     "synchronization/lock_impl_win.cc",
582     "synchronization/spin_wait.h",
583     "synchronization/waitable_event.h",
584     "synchronization/waitable_event_posix.cc",
585     "synchronization/waitable_event_watcher.h",
586     "synchronization/waitable_event_watcher_posix.cc",
587     "synchronization/waitable_event_watcher_win.cc",
588     "synchronization/waitable_event_win.cc",
589     "system_monitor/system_monitor.cc",
590     "system_monitor/system_monitor.h",
591     "sys_byteorder.h",
592     "sys_info.cc",
593     "sys_info.h",
594     "sys_info_android.cc",
595     "sys_info_chromeos.cc",
596     "sys_info_freebsd.cc",
597     "sys_info_ios.mm",
598     "sys_info_linux.cc",
599     "sys_info_mac.cc",
600     "sys_info_openbsd.cc",
601     "sys_info_posix.cc",
602     "sys_info_win.cc",
603     "task/cancelable_task_tracker.cc",
604     "task/cancelable_task_tracker.h",
605     "task_runner.cc",
606     "task_runner.h",
607     "task_runner_util.h",
608     "template_util.h",
609     "thread_task_runner_handle.cc",
610     "thread_task_runner_handle.h",
611     "threading/non_thread_safe.h",
612     "threading/non_thread_safe_impl.cc",
613     "threading/non_thread_safe_impl.h",
614     "threading/platform_thread.h",
615     "threading/platform_thread_android.cc",
616     "threading/platform_thread_linux.cc",
617     "threading/platform_thread_mac.mm",
618     "threading/platform_thread_posix.cc",
619     "threading/platform_thread_win.cc",
620     "threading/post_task_and_reply_impl.cc",
621     "threading/post_task_and_reply_impl.h",
622     "threading/sequenced_worker_pool.cc",
623     "threading/sequenced_worker_pool.h",
624     "threading/simple_thread.cc",
625     "threading/simple_thread.h",
626     "threading/thread.cc",
627     "threading/thread.h",
628     "threading/thread_checker.h",
629     "threading/thread_checker_impl.cc",
630     "threading/thread_checker_impl.h",
631     "threading/thread_collision_warner.cc",
632     "threading/thread_collision_warner.h",
633     "threading/thread_id_name_manager.cc",
634     "threading/thread_id_name_manager.h",
635     "threading/thread_local.h",
636     "threading/thread_local_android.cc",
637     "threading/thread_local_posix.cc",
638     "threading/thread_local_storage.cc",
639     "threading/thread_local_storage.h",
640     "threading/thread_local_storage_posix.cc",
641     "threading/thread_local_storage_win.cc",
642     "threading/thread_local_win.cc",
643     "threading/thread_restrictions.h",
644     "threading/thread_restrictions.cc",
645     "threading/watchdog.cc",
646     "threading/watchdog.h",
647     "threading/worker_pool.h",
648     "threading/worker_pool.cc",
649     "threading/worker_pool_posix.cc",
650     "threading/worker_pool_posix.h",
651     "threading/worker_pool_win.cc",
652     "time/clock.cc",
653     "time/clock.h",
654     "time/default_clock.cc",
655     "time/default_clock.h",
656     "time/default_tick_clock.cc",
657     "time/default_tick_clock.h",
658     "time/tick_clock.cc",
659     "time/tick_clock.h",
660     "time/time.cc",
661     "time/time.h",
662     "time/time_mac.cc",
663     "time/time_posix.cc",
664     "time/time_win.cc",
665     "timer/elapsed_timer.cc",
666     "timer/elapsed_timer.h",
667     "timer/hi_res_timer_manager.h",
668     "timer/hi_res_timer_manager_posix.cc",
669     "timer/hi_res_timer_manager_win.cc",
670     "timer/mock_timer.cc",
671     "timer/mock_timer.h",
672     "timer/timer.cc",
673     "timer/timer.h",
674     "tracked_objects.cc",
675     "tracked_objects.h",
676     "tracking_info.cc",
677     "tracking_info.h",
678     "tuple.h",
679     "values.cc",
680     "values.h",
681     "value_conversions.cc",
682     "value_conversions.h",
683     "version.cc",
684     "version.h",
685     "vlog.cc",
686     "vlog.h",
687     "win/enum_variant.cc",
688     "win/enum_variant.h",
689     "win/event_trace_consumer.h",
690     "win/event_trace_controller.cc",
691     "win/event_trace_controller.h",
692     "win/event_trace_provider.cc",
693     "win/event_trace_provider.h",
694     "win/i18n.cc",
695     "win/i18n.h",
696     "win/iat_patch_function.cc",
697     "win/iat_patch_function.h",
698     "win/iunknown_impl.cc",
699     "win/iunknown_impl.h",
700     "win/message_window.cc",
701     "win/message_window.h",
702     "win/metro.cc",
703     "win/metro.h",
704     "win/object_watcher.cc",
705     "win/object_watcher.h",
706     "win/registry.cc",
707     "win/registry.h",
708     "win/resource_util.cc",
709     "win/resource_util.h",
710     "win/scoped_bstr.cc",
711     "win/scoped_bstr.h",
712     "win/scoped_co_mem.h",
713     "win/scoped_com_initializer.h",
714     "win/scoped_comptr.h",
715     "win/scoped_gdi_object.h",
716     "win/scoped_handle.cc",
717     "win/scoped_handle.h",
718     "win/scoped_hdc.h",
719     "win/scoped_hglobal.h",
720     "win/scoped_process_information.cc",
721     "win/scoped_process_information.h",
722     "win/scoped_propvariant.h",
723     "win/scoped_select_object.h",
724     "win/scoped_variant.cc",
725     "win/scoped_variant.h",
726     "win/shortcut.cc",
727     "win/shortcut.h",
728     "win/startup_information.cc",
729     "win/startup_information.h",
730     "win/win_util.cc",
731     "win/win_util.h",
732     "win/windows_version.cc",
733     "win/windows_version.h",
734     "win/wrapped_window_proc.cc",
735     "win/wrapped_window_proc.h",
736   ]
738   if (is_nacl) {
739     sources += [ "files/file_path_watcher_stub.cc" ]
740   }
742   sources -= [
743     "process/process_handle_freebsd.cc",
744     "process/process_handle_openbsd.cc",
745     "process/process_iterator_freebsd.cc",
746     "process/process_iterator_openbsd.cc",
747     "process/process_metrics_freebsd.cc",
748     "process/process_metrics_openbsd.cc",
749     "sys_info_freebsd.cc",
750     "sys_info_openbsd.cc",
751   ]
753   defines = [
754     "BASE_IMPLEMENTATION",
755   ]
757   deps = [
758     ":base_static",
759     "//base/allocator:allocator_extension_thunks",
760     "//base/third_party/dynamic_annotations",
761     "//base/third_party/nspr",
762     "//third_party/modp_b64",
763   ]
765   if (is_android) {
766     sources += [
767        "memory/discardable_memory_ashmem_allocator.cc",
768        "memory/discardable_memory_ashmem_allocator.h",
769        "memory/discardable_memory_ashmem.cc",
770        "memory/discardable_memory_ashmem.h",
771     ]
772     sources -= [
773       "base_paths_posix.cc",
774       "power_monitor/power_monitor_device_source_posix.cc",
775     ]
777     # Android uses some Linux sources, put those back.
778     set_sources_assignment_filter([])
779     sources += [
780       "debug/proc_maps_linux.cc",
781       "files/file_path_watcher_linux.cc",
782       "process/memory_linux.cc",
783       "process/internal_linux.cc",
784       "process/process_handle_linux.cc",
785       "process/process_iterator_linux.cc",
786       "process/process_metrics_linux.cc",
787       "posix/unix_domain_socket_linux.cc",
788       "sys_info_linux.cc",
789     ]
790     set_sources_assignment_filter(sources_assignment_filter)
792     deps += [
793       ":base_jni_headers",
794       "//third_party/ashmem",
795       "//third_party/android_tools:cpu_features"
796     ]
798     # logging.cc uses the Android logging library.
799     libs = [ "log" ]
801     sources -= [
802       "debug/stack_trace_posix.cc",
803     ]
804   }
806   if (is_chromeos) {
807     sources -= [
808       "power_monitor/power_monitor_device_source_posix.cc",
809     ]
810   }
812   if (is_nacl) {
813     # These things would otherwise be built on a Posix build but aren't
814     # supported on NaCl.
815     sources -= [
816       "debug/stack_trace_posix.cc",
817       "files/file_enumerator_posix.cc",
818       "files/file_util_posix.cc",
819       "message_loop/message_pump_libevent.cc",
820       "process/kill_posix.cc",
821       "process/launch_posix.cc",
822       "process/process_metrics_posix.cc",
823       "process/process_posix.cc",
824       "metrics/field_trial.cc",
825       "native_library_posix.cc",
826       "memory/shared_memory_posix.cc",
827       "sync_socket_posix.cc",
828       "sys_info_posix.cc",
829     ]
830   } else {
831     # Remove nacl stuff.
832     sources -= [
833       "os_compat_nacl.cc",
834       "os_compat_nacl.h",
835       "rand_util_nacl.cc",
836       "memory/shared_memory_nacl.cc",
837     ]
838   }
840   # Windows.
841   if (is_win) {
842     sources -= [
843       "event_recorder_stubs.cc",
844       "message_loop/message_pump_libevent.cc",
845       "strings/string16.cc",
846       # Not using sha1_win.cc because it may have caused a
847       # regression to page cycler moz.
848       "sha1_win.cc",
849     ]
851     # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
852     #cflags = [ "/wd4267" ]
854     libs = [
855       "netapi32.lib",
856       "powrprof.lib",
857     ]
858     ldflags = [
859       "/DELAYLOAD:powrprof.dll",
860     ]
861   } else if (!is_nacl) {
862     # Non-Windows.
863     deps += [ "//third_party/libevent" ]
864   }
866   # Mac.
867   if (is_mac) {
868     sources -= [
869       "base_paths_posix.cc",
870       "native_library_posix.cc",
871       "strings/sys_string_conversions_posix.cc",
872     ]
873     deps += [ "//third_party/mach_override" ]
874   } else {
875     # Non-Mac.
876     sources -= [
877       "files/file_path_watcher_fsevents.cc",
878       "files/file_path_watcher_fsevents.h",
879       "files/file_path_watcher_kqueue.cc",
880       "files/file_path_watcher_kqueue.h",
881     ]
882   }
884   # Linux.
885   if (is_linux) {
886     # TODO(brettw) this will need to be parameterized at some point.
887     linux_configs = [
888       "//build/config/linux:glib",
889     ]
891     configs += linux_configs
892     all_dependent_configs = linux_configs
894     defines += [ "USE_SYMBOLIZE" ]
896     # These dependencies are not required on Android, and in the case
897     # of xdg_mime must be excluded due to licensing restrictions.
898     deps += [
899       "//base/third_party/symbolize",
900       "//base/third_party/xdg_mime",
901       "//base/third_party/xdg_user_dirs",
902     ]
903   } else {
904     # Non-Linux.
905     sources -= [
906       "nix/mime_util_xdg.cc",
907       "nix/mime_util_xdg.h",
908       "nix/xdg_util.cc",
909       "nix/xdg_util.h",
910     ]
912     if (!is_android) {
913       sources -= [
914         "linux_util.cc",
915         "linux_util.h",
916       ]
917     }
918   }
920   if (!use_glib) {
921     sources -= [
922       "message_loop/message_pump_glib.cc",
923       "message_loop/message_pump_glib.h",
924     ]
925   }
927   configs += [ "//build/config/compiler:wexit_time_destructors" ]
928   if (is_android && !is_debug) {
929     configs -= [ "//build/config/compiler:optimize" ]
930     configs += [ "//build/config/compiler:optimize_max" ]
931   }
934 # This is the subset of files from base that should not be used with a dynamic
935 # library. Note that this library cannot depend on base because base depends on
936 # base_static.
937 source_set("base_static") {
938   sources = [
939     "base_switches.cc",
940     "base_switches.h",
941     "win/pe_image.cc",
942     "win/pe_image.h",
943   ]
945   if (is_android && !is_debug) {
946     configs -= [ "//build/config/compiler:optimize" ]
947     configs += [ "//build/config/compiler:optimize_max" ]
948   }
951 component("i18n") {
952   output_name = "base_i18n"
953   sources = [
954     "i18n/base_i18n_export.h",
955     "i18n/bidi_line_iterator.cc",
956     "i18n/bidi_line_iterator.h",
957     "i18n/break_iterator.cc",
958     "i18n/break_iterator.h",
959     "i18n/case_conversion.cc",
960     "i18n/case_conversion.h",
961     "i18n/char_iterator.cc",
962     "i18n/char_iterator.h",
963     "i18n/file_util_icu.cc",
964     "i18n/file_util_icu.h",
965     "i18n/i18n_constants.cc",
966     "i18n/i18n_constants.h",
967     "i18n/icu_encoding_detection.cc",
968     "i18n/icu_encoding_detection.h",
969     "i18n/icu_string_conversions.cc",
970     "i18n/icu_string_conversions.h",
971     "i18n/icu_util.cc",
972     "i18n/icu_util.h",
973     "i18n/number_formatting.cc",
974     "i18n/number_formatting.h",
975     "i18n/rtl.cc",
976     "i18n/rtl.h",
977     "i18n/streaming_utf8_validator.cc",
978     "i18n/streaming_utf8_validator.h",
979     "i18n/string_compare.cc",
980     "i18n/string_compare.h",
981     "i18n/string_search.cc",
982     "i18n/string_search.h",
983     "i18n/time_formatting.cc",
984     "i18n/time_formatting.h",
985     "i18n/timezone.cc",
986     "i18n/timezone.h",
987     "i18n/utf8_validator_tables.cc",
988     "i18n/utf8_validator_tables.h",
989   ]
990   defines = [ "BASE_I18N_IMPLEMENTATION" ]
991   configs += [ "//build/config/compiler:wexit_time_destructors" ]
992   deps = [
993     ":base",
994     "//base/third_party/dynamic_annotations",
995     "//third_party/icu",
996   ]
998   if (is_android && !is_debug) {
999     configs -= [ "//build/config/compiler:optimize" ]
1000     configs += [ "//build/config/compiler:optimize_max" ]
1001   }
1004 source_set("prefs") {
1005   sources = [
1006     "prefs/base_prefs_export.h",
1007     "prefs/default_pref_store.cc",
1008     "prefs/default_pref_store.h",
1009     "prefs/json_pref_store.cc",
1010     "prefs/json_pref_store.h",
1011     "prefs/overlay_user_pref_store.cc",
1012     "prefs/overlay_user_pref_store.h",
1013     "prefs/persistent_pref_store.h",
1014     "prefs/pref_change_registrar.cc",
1015     "prefs/pref_change_registrar.h",
1016     "prefs/pref_filter.h",
1017     "prefs/pref_member.cc",
1018     "prefs/pref_member.h",
1019     "prefs/pref_notifier.h",
1020     "prefs/pref_notifier_impl.cc",
1021     "prefs/pref_notifier_impl.h",
1022     "prefs/pref_observer.h",
1023     "prefs/pref_registry.cc",
1024     "prefs/pref_registry.h",
1025     "prefs/pref_registry_simple.cc",
1026     "prefs/pref_registry_simple.h",
1027     "prefs/pref_service.cc",
1028     "prefs/pref_service.h",
1029     "prefs/pref_service_factory.cc",
1030     "prefs/pref_service_factory.h",
1031     "prefs/pref_store.cc",
1032     "prefs/pref_store.h",
1033     "prefs/pref_value_map.cc",
1034     "prefs/pref_value_map.h",
1035     "prefs/pref_value_store.cc",
1036     "prefs/pref_value_store.h",
1037     "prefs/scoped_user_pref_update.cc",
1038     "prefs/scoped_user_pref_update.h",
1039     "prefs/value_map_pref_store.cc",
1040     "prefs/value_map_pref_store.h",
1041     "prefs/writeable_pref_store.h",
1042   ]
1044   defines = [ "BASE_PREFS_IMPLEMENTATION" ]
1046   deps = [ ":base" ]
1048   if (is_android && !is_debug) {
1049     configs -= [ "//build/config/compiler:optimize" ]
1050     configs += [ "//build/config/compiler:optimize_max" ]
1051   }
1054 source_set("prefs_test_support") {
1055   testonly = true
1056   sources = [
1057     "prefs/mock_pref_change_callback.cc",
1058     "prefs/mock_pref_change_callback.h",
1059     "prefs/pref_store_observer_mock.cc",
1060     "prefs/pref_store_observer_mock.h",
1061     "prefs/testing_pref_service.cc",
1062     "prefs/testing_pref_service.h",
1063     "prefs/testing_pref_store.cc",
1064     "prefs/testing_pref_store.h",
1065   ]
1067   deps = [
1068     ":base",
1069     ":prefs",
1070     "//testing/gmock",
1071     "//testing/gtest",
1072   ]
1075 source_set("message_loop_tests") {
1076   testonly = true
1077   sources = [
1078     "message_loop/message_loop_test.cc",
1079     "message_loop/message_loop_test.h",
1080   ]
1082   deps = [
1083     ":base",
1084     "//testing/gtest",
1085   ]
1088 test("base_unittests") {
1089   sources = [
1090     "android/application_status_listener_unittest.cc",
1091     "android/jni_android_unittest.cc",
1092     "android/jni_array_unittest.cc",
1093     "android/jni_string_unittest.cc",
1094     "android/path_utils_unittest.cc",
1095     "android/scoped_java_ref_unittest.cc",
1096     "android/sys_utils_unittest.cc",
1097     "async_socket_io_handler_unittest.cc",
1098     "at_exit_unittest.cc",
1099     "atomicops_unittest.cc",
1100     "barrier_closure_unittest.cc",
1101     "base64_unittest.cc",
1102     "big_endian_unittest.cc",
1103     "bind_unittest.cc",
1104     "bind_unittest.nc",
1105     "bits_unittest.cc",
1106     "build_time_unittest.cc",
1107     "callback_helpers_unittest.cc",
1108     "callback_list_unittest.cc",
1109     "callback_list_unittest.nc",
1110     "callback_unittest.cc",
1111     "callback_unittest.nc",
1112     "cancelable_callback_unittest.cc",
1113     "command_line_unittest.cc",
1114     "containers/adapters_unittest.cc",
1115     "containers/hash_tables_unittest.cc",
1116     "containers/linked_list_unittest.cc",
1117     "containers/mru_cache_unittest.cc",
1118     "containers/small_map_unittest.cc",
1119     "containers/stack_container_unittest.cc",
1120     "cpu_unittest.cc",
1121     "debug/crash_logging_unittest.cc",
1122     "debug/leak_tracker_unittest.cc",
1123     "debug/proc_maps_linux_unittest.cc",
1124     "debug/stack_trace_unittest.cc",
1125     "debug/task_annotator_unittest.cc",
1126     "debug/trace_event_argument_unittest.cc",
1127     "debug/trace_event_memory_unittest.cc",
1128     "debug/trace_event_synthetic_delay_unittest.cc",
1129     "debug/trace_event_system_stats_monitor_unittest.cc",
1130     "debug/trace_event_unittest.cc",
1131     "debug/trace_event_unittest.h",
1132     "debug/trace_event_win_unittest.cc",
1133     "deferred_sequenced_task_runner_unittest.cc",
1134     "environment_unittest.cc",
1135     "file_version_info_unittest.cc",
1136     "files/dir_reader_posix_unittest.cc",
1137     "files/file_path_unittest.cc",
1138     "files/file_proxy_unittest.cc",
1139     "files/file_unittest.cc",
1140     "files/file_util_proxy_unittest.cc",
1141     "files/file_util_unittest.cc",
1142     "files/important_file_writer_unittest.cc",
1143     "files/scoped_temp_dir_unittest.cc",
1144     "gmock_unittest.cc",
1145     "guid_unittest.cc",
1146     "hash_unittest.cc",
1147     "id_map_unittest.cc",
1148     "i18n/break_iterator_unittest.cc",
1149     "i18n/char_iterator_unittest.cc",
1150     "i18n/case_conversion_unittest.cc",
1151     "i18n/file_util_icu_unittest.cc",
1152     "i18n/icu_string_conversions_unittest.cc",
1153     "i18n/number_formatting_unittest.cc",
1154     "i18n/rtl_unittest.cc",
1155     "i18n/streaming_utf8_validator_unittest.cc",
1156     "i18n/string_search_unittest.cc",
1157     "i18n/time_formatting_unittest.cc",
1158     "i18n/timezone_unittest.cc",
1159     "ios/device_util_unittest.mm",
1160     "json/json_parser_unittest.cc",
1161     "json/json_reader_unittest.cc",
1162     "json/json_value_converter_unittest.cc",
1163     "json/json_value_serializer_unittest.cc",
1164     "json/json_writer_unittest.cc",
1165     "json/string_escape_unittest.cc",
1166     "lazy_instance_unittest.cc",
1167     "logging_unittest.cc",
1168     "mac/bind_objc_block_unittest.mm",
1169     "mac/foundation_util_unittest.mm",
1170     "mac/libdispatch_task_runner_unittest.cc",
1171     "mac/mac_util_unittest.mm",
1172     "mac/objc_property_releaser_unittest.mm",
1173     "mac/scoped_nsobject_unittest.mm",
1174     "mac/scoped_objc_class_swizzler_unittest.mm",
1175     "mac/scoped_sending_event_unittest.mm",
1176     "md5_unittest.cc",
1177     "memory/aligned_memory_unittest.cc",
1178     "memory/discardable_memory_manager_unittest.cc",
1179     "memory/discardable_memory_unittest.cc",
1180     "memory/linked_ptr_unittest.cc",
1181     "memory/ref_counted_memory_unittest.cc",
1182     "memory/ref_counted_unittest.cc",
1183     "memory/scoped_ptr_unittest.cc",
1184     "memory/scoped_ptr_unittest.nc",
1185     "memory/scoped_vector_unittest.cc",
1186     "memory/shared_memory_unittest.cc",
1187     "memory/singleton_unittest.cc",
1188     "memory/weak_ptr_unittest.cc",
1189     "memory/weak_ptr_unittest.nc",
1190     "message_loop/message_loop_proxy_impl_unittest.cc",
1191     "message_loop/message_loop_proxy_unittest.cc",
1192     "message_loop/message_loop_unittest.cc",
1193     "message_loop/message_pump_glib_unittest.cc",
1194     "message_loop/message_pump_io_ios_unittest.cc",
1195     "metrics/sample_map_unittest.cc",
1196     "metrics/sample_vector_unittest.cc",
1197     "metrics/bucket_ranges_unittest.cc",
1198     "metrics/field_trial_unittest.cc",
1199     "metrics/histogram_base_unittest.cc",
1200     "metrics/histogram_delta_serialization_unittest.cc",
1201     "metrics/histogram_snapshot_manager_unittest.cc",
1202     "metrics/histogram_unittest.cc",
1203     "metrics/sparse_histogram_unittest.cc",
1204     "metrics/stats_table_unittest.cc",
1205     "metrics/statistics_recorder_unittest.cc",
1206     "observer_list_unittest.cc",
1207     "os_compat_android_unittest.cc",
1208     "path_service_unittest.cc",
1209     "pickle_unittest.cc",
1210     "posix/file_descriptor_shuffle_unittest.cc",
1211     "posix/unix_domain_socket_linux_unittest.cc",
1212     "power_monitor/power_monitor_unittest.cc",
1213     "prefs/default_pref_store_unittest.cc",
1214     "prefs/json_pref_store_unittest.cc",
1215     "prefs/overlay_user_pref_store_unittest.cc",
1216     "prefs/pref_change_registrar_unittest.cc",
1217     "prefs/pref_member_unittest.cc",
1218     "prefs/pref_notifier_impl_unittest.cc",
1219     "prefs/pref_service_unittest.cc",
1220     "prefs/pref_value_map_unittest.cc",
1221     "prefs/pref_value_store_unittest.cc",
1222     "prefs/scoped_user_pref_update_unittest.cc",
1223     "process/memory_unittest.cc",
1224     "process/memory_unittest_mac.h",
1225     "process/memory_unittest_mac.mm",
1226     "process/process_metrics_unittest.cc",
1227     "process/process_metrics_unittest_ios.cc",
1228     "process/process_util_unittest.cc",
1229     "process/process_util_unittest_ios.cc",
1230     "profiler/tracked_time_unittest.cc",
1231     "rand_util_unittest.cc",
1232     "numerics/safe_numerics_unittest.cc",
1233     "scoped_clear_errno_unittest.cc",
1234     "scoped_generic_unittest.cc",
1235     "scoped_native_library_unittest.cc",
1236     "security_unittest.cc",
1237     "sequence_checker_unittest.cc",
1238     "sha1_unittest.cc",
1239     "stl_util_unittest.cc",
1240     "strings/nullable_string16_unittest.cc",
1241     "strings/safe_sprintf_unittest.cc",
1242     "strings/string16_unittest.cc",
1243     "strings/stringprintf_unittest.cc",
1244     "strings/string_number_conversions_unittest.cc",
1245     "strings/string_piece_unittest.cc",
1246     "strings/string_split_unittest.cc",
1247     "strings/string_tokenizer_unittest.cc",
1248     "strings/string_util_unittest.cc",
1249     "strings/stringize_macros_unittest.cc",
1250     "strings/sys_string_conversions_mac_unittest.mm",
1251     "strings/sys_string_conversions_unittest.cc",
1252     "strings/utf_offset_string_conversions_unittest.cc",
1253     "strings/utf_string_conversions_unittest.cc",
1254     "supports_user_data_unittest.cc",
1255     "sync_socket_unittest.cc",
1256     "synchronization/cancellation_flag_unittest.cc",
1257     "synchronization/condition_variable_unittest.cc",
1258     "synchronization/lock_unittest.cc",
1259     "synchronization/waitable_event_unittest.cc",
1260     "synchronization/waitable_event_watcher_unittest.cc",
1261     "sys_info_unittest.cc",
1262     "system_monitor/system_monitor_unittest.cc",
1263     "task/cancelable_task_tracker_unittest.cc",
1264     "task_runner_util_unittest.cc",
1265     "template_util_unittest.cc",
1266     "test/expectations/expectation_unittest.cc",
1267     "test/expectations/parser_unittest.cc",
1268     "test/histogram_tester_unittest.cc",
1269     "test/test_reg_util_win_unittest.cc",
1270     "test/trace_event_analyzer_unittest.cc",
1271     "threading/non_thread_safe_unittest.cc",
1272     "threading/platform_thread_unittest.cc",
1273     "threading/sequenced_worker_pool_unittest.cc",
1274     "threading/simple_thread_unittest.cc",
1275     "threading/thread_checker_unittest.cc",
1276     "threading/thread_collision_warner_unittest.cc",
1277     "threading/thread_id_name_manager_unittest.cc",
1278     "threading/thread_local_storage_unittest.cc",
1279     "threading/thread_local_unittest.cc",
1280     "threading/thread_unittest.cc",
1281     "threading/watchdog_unittest.cc",
1282     "threading/worker_pool_posix_unittest.cc",
1283     "threading/worker_pool_unittest.cc",
1284     "time/pr_time_unittest.cc",
1285     "time/time_unittest.cc",
1286     "time/time_win_unittest.cc",
1287     "timer/hi_res_timer_manager_unittest.cc",
1288     "timer/mock_timer_unittest.cc",
1289     "timer/timer_unittest.cc",
1290     "tools_sanity_unittest.cc",
1291     "tracked_objects_unittest.cc",
1292     "tuple_unittest.cc",
1293     "values_unittest.cc",
1294     "version_unittest.cc",
1295     "vlog_unittest.cc",
1296     "win/dllmain.cc",
1297     "win/enum_variant_unittest.cc",
1298     "win/event_trace_consumer_unittest.cc",
1299     "win/event_trace_controller_unittest.cc",
1300     "win/event_trace_provider_unittest.cc",
1301     "win/i18n_unittest.cc",
1302     "win/iunknown_impl_unittest.cc",
1303     "win/message_window_unittest.cc",
1304     "win/object_watcher_unittest.cc",
1305     "win/pe_image_unittest.cc",
1306     "win/registry_unittest.cc",
1307     "win/scoped_bstr_unittest.cc",
1308     "win/scoped_comptr_unittest.cc",
1309     "win/scoped_process_information_unittest.cc",
1310     "win/scoped_variant_unittest.cc",
1311     "win/shortcut_unittest.cc",
1312     "win/startup_information_unittest.cc",
1313     "win/win_util_unittest.cc",
1314     "win/wrapped_window_proc_unittest.cc",
1315   ]
1317   deps = [
1318     ":base",
1319     ":i18n",
1320     ":message_loop_tests",
1321     ":prefs",
1322     ":prefs_test_support",
1323     "//base/allocator",
1324     "//base/test:run_all_unittests",
1325     "//base/test:test_support",
1326     "//base/third_party/dynamic_annotations",
1327     "//base/third_party/nspr",
1328     "//testing/gmock",
1329     "//testing/gtest",
1330     "//third_party/icu",
1331   ]
1333   if (is_ios) {
1334     sources -= [
1335       "metrics/stats_table_uinittest.cc",  # Requires spawning a process.
1336       "process/memory_unittest.cc",
1337       "process/memory_unittest_mac.h",
1338       "process/memory_unittest_mac.mm",
1339       "process/process_util_unittest.cc",
1340     ]
1342     # Pull in specific Mac files for iOS (which have been filtered out by file
1343     # name rules).
1344     set_sources_assignment_filter([])
1345     sources += [
1346       "mac/bind_objc_block_unittest.mm",
1347       "mac/foundation_util_unittest.mm",
1348       "mac/objc_property_releaser_unittest.mm",
1349       "mac/scoped_nsobject_unittest.mm",
1350       "sys_string_conversions_mac_unittest.mm",
1351     ]
1352     set_sources_assignment_filter(sources_assignment_filter)
1354     # TODO(GYP): dep on copy_test_data_ios action.
1355   }
1357   if (is_linux) {
1358     sources -= [ "file_version_info_unittest.cc" ]
1359     sources += [ "nix/xdg_util_unittest.cc" ]
1360     defines = [ "USE_SYMBOLIZE" ]
1361     configs += [ "//build/config/linux:glib" ]
1362   }
1364   if (!is_linux || use_ozone) {
1365     sources -= [ "message_loop/message_pump_glib_unittest.cc" ]
1366   }
1368   if (is_posix || is_ios) {
1369     sources += [ "message_loop/message_pump_libevent_unittest.cc" ]
1370     deps += [ "//third_party/libevent" ]
1371   }
1373   if (is_android) {
1374     deps += [
1375       "//testing/android:native_test_native_code",
1376     ]
1377     set_sources_assignment_filter([])
1378     sources += [ "debug/proc_maps_linux_unittest.cc" ]
1379     set_sources_assignment_filter(sources_assignment_filter)
1380   }
1383 if (is_android) {
1384   # GYP: //base.gyp:base_jni_headers
1385   generate_jni("base_jni_headers") {
1386     sources = [
1387       "android/java/src/org/chromium/base/ApplicationStatus.java",
1388       "android/java/src/org/chromium/base/BuildInfo.java",
1389       "android/java/src/org/chromium/base/CommandLine.java",
1390       "android/java/src/org/chromium/base/ContentUriUtils.java",
1391       "android/java/src/org/chromium/base/CpuFeatures.java",
1392       "android/java/src/org/chromium/base/EventLog.java",
1393       "android/java/src/org/chromium/base/FieldTrialList.java",
1394       "android/java/src/org/chromium/base/ImportantFileWriterAndroid.java",
1395       "android/java/src/org/chromium/base/JNIUtils.java",
1396       "android/java/src/org/chromium/base/library_loader/LibraryLoader.java",
1397       "android/java/src/org/chromium/base/MemoryPressureListener.java",
1398       "android/java/src/org/chromium/base/JavaHandlerThread.java",
1399       "android/java/src/org/chromium/base/PathService.java",
1400       "android/java/src/org/chromium/base/PathUtils.java",
1401       "android/java/src/org/chromium/base/PowerMonitor.java",
1402       "android/java/src/org/chromium/base/SystemMessageHandler.java",
1403       "android/java/src/org/chromium/base/SysUtils.java",
1404       "android/java/src/org/chromium/base/ThreadUtils.java",
1405       "android/java/src/org/chromium/base/TraceEvent.java",
1406     ]
1407     jni_package = "base"
1408   }
1410   # GYP: //base.gyp:base_java
1411   android_library("base_java") {
1412     srcjar_deps = [
1413       ":base_java_application_state",
1414       ":base_java_memory_pressure_level_list",
1415       ":base_native_libraries_gen",
1416     ]
1418     deps = [
1419       "//third_party/jsr-305:jsr_305_javalib"
1420     ]
1422     DEPRECATED_java_in_dir = "android/java/src"
1424     # A new version of NativeLibraries.java (with the actual correct values)
1425     # will be created when creating an apk.
1426     jar_excluded_patterns = [
1427       "*/NativeLibraries.class",
1428       "*/NativeLibraries##*.class",
1429     ]
1430   }
1432   # GYP: //base.gyp:base_javatests
1433   android_library("base_javatests") {
1434     deps = [
1435       ":base_java",
1436       ":base_java_test_support",
1437     ]
1438     DEPRECATED_java_in_dir = "android/javatests/src"
1439   }
1441   # GYP: //base.gyp:base_java_test_support
1442   android_library("base_java_test_support") {
1443     deps = [
1444       ":base_java",
1445     ]
1446     DEPRECATED_java_in_dir = "test/android/javatests/src"
1447   }
1449   # GYP: //base.gyp:base_java_application_state
1450   java_cpp_template("base_java_application_state") {
1451     sources = [
1452       "android/java/src/org/chromium/base/ApplicationState.template",
1453     ]
1454     inputs = [
1455       "android/application_state_list.h"
1456     ]
1458     package_name = "org/chromium/base"
1459   }
1461   # GYP: //base.gyp:base_java_memory_pressure_level_list
1462   java_cpp_template("base_java_memory_pressure_level_list") {
1463     sources = [
1464       "android/java/src/org/chromium/base/MemoryPressureLevelList.template",
1465     ]
1466     inputs = [
1467       "memory/memory_pressure_level_list.h"
1468     ]
1470     package_name = "org/chromium/base"
1471   }
1473   # GYP: //base/base.gyp:base_native_libraries_gen
1474   java_cpp_template("base_native_libraries_gen") {
1475     sources = [
1476       "android/java/templates/NativeLibraries.template",
1477     ]
1478     package_name = "org/chromium/base/library_loader"
1479   }
1481   # GYP: //base.gyp:base_java_unittest_support
1482   android_library("base_java_unittest_support") {
1483     deps = [":base_java"]
1484     java_files = [
1485       "test/android/java/src/org/chromium/base/ContentUriTestUtils.java"
1486     ]
1487   }
1489   # GYP: //base.gyp:base_unittests_apk
1490   unittest_apk("base_unittests_apk") {
1491     deps = [
1492       ":base_java",
1493       ":base_java_unittest_support",
1494       ":base_unittests",
1495     ]
1496     unittests_dep = ":base_unittests"
1497   }