1 # 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.
10 'target_conditions': [
11 # This part is shared between the targets defined below.
14 '../build/build_config.h',
15 'third_party/dmg_fp/dmg_fp.h',
16 'third_party/dmg_fp/g_fmt.cc',
17 'third_party/dmg_fp/dtoa_wrapper.cc',
18 'third_party/icu/icu_utf.cc',
19 'third_party/icu/icu_utf.h',
20 'third_party/nspr/prcpucfg.h',
21 'third_party/nspr/prcpucfg_freebsd.h',
22 'third_party/nspr/prcpucfg_linux.h',
23 'third_party/nspr/prcpucfg_mac.h',
24 'third_party/nspr/prcpucfg_nacl.h',
25 'third_party/nspr/prcpucfg_openbsd.h',
26 'third_party/nspr/prcpucfg_solaris.h',
27 'third_party/nspr/prcpucfg_win.h',
28 'third_party/nspr/prtime.cc',
29 'third_party/nspr/prtime.h',
30 'third_party/nspr/prtypes.h',
31 'third_party/xdg_mime/xdgmime.h',
32 'allocator/allocator_extension.cc',
33 'allocator/allocator_extension.h',
34 'allocator/type_profiler_control.cc',
35 'allocator/type_profiler_control.h',
36 'android/base_jni_registrar.cc',
37 'android/base_jni_registrar.h',
38 'android/build_info.cc',
39 'android/build_info.h',
40 'android/cpu_features.cc',
41 'android/scoped_java_ref.cc',
42 'android/scoped_java_ref.h',
43 'android/jni_android.cc',
44 'android/jni_android.h',
45 'android/jni_array.cc',
46 'android/jni_array.h',
47 'android/jni_helper.cc',
48 'android/jni_helper.h',
49 'android/jni_registrar.cc',
50 'android/jni_registrar.h',
51 'android/jni_string.cc',
52 'android/jni_string.h',
53 'android/locale_utils.cc',
54 'android/locale_utils.h',
55 'android/path_service_android.cc',
56 'android/path_service_android.h',
57 'android/path_utils.cc',
58 'android/path_utils.h',
59 'android/thread_utils.h',
63 'atomic_sequence_num.h',
65 'atomicops_internals_gcc.h',
66 'atomicops_internals_mac.h',
67 'atomicops_internals_tsan.h',
68 'atomicops_internals_x86_gcc.cc',
69 'atomicops_internals_x86_gcc.h',
70 'atomicops_internals_x86_msvc.h',
74 'base_paths_android.cc',
75 'base_paths_android.h',
78 'base_paths_posix.cc',
90 'bind_internal_win.h',
96 'callback_internal.cc',
97 'callback_internal.h',
98 'cancelable_callback.h',
99 'chromeos/chromeos_version.cc',
100 'chromeos/chromeos_version.h',
103 'compiler_specific.h',
104 'containers/linked_list.h',
105 'containers/mru_cache.h',
106 'containers/small_map.h',
107 'containers/stack_container.h',
110 'critical_closure.h',
111 'critical_closure_ios.mm',
114 'debug/crash_logging.cc',
115 'debug/crash_logging.h',
116 'debug/debug_on_start_win.cc',
117 'debug/debug_on_start_win.h',
120 'debug/debugger_posix.cc',
121 'debug/debugger_win.cc',
122 # This file depends on files from the 'allocator' target,
123 # but this target does not depend on 'allocator' (see
124 # allocator.gyp for details).
125 'debug/leak_annotations.h',
126 'debug/leak_tracker.h',
129 'debug/stack_trace.cc',
130 'debug/stack_trace.h',
131 'debug/stack_trace_android.cc',
132 'debug/stack_trace_ios.mm',
133 'debug/stack_trace_posix.cc',
134 'debug/stack_trace_win.cc',
135 'debug/trace_event.h',
136 'debug/trace_event_android.cc',
137 'debug/trace_event_impl.cc',
138 'debug/trace_event_impl.h',
139 'debug/trace_event_internal.h',
140 'debug/trace_event_win.cc',
143 'file_descriptor_posix.h',
148 'file_util_android.cc',
149 'file_util_linux.cc',
151 'file_util_posix.cc',
153 'file_version_info.h',
154 'file_version_info_mac.h',
155 'file_version_info_mac.mm',
156 'file_version_info_win.cc',
157 'file_version_info_win.h',
158 'files/dir_reader_fallback.h',
159 'files/dir_reader_linux.h',
160 'files/dir_reader_posix.h',
161 'files/file_path_watcher.cc',
162 'files/file_path_watcher.h',
163 'files/file_path_watcher_kqueue.cc',
164 'files/file_path_watcher_linux.cc',
165 'files/file_path_watcher_stub.cc',
166 'files/file_path_watcher_win.cc',
167 'files/file_util_proxy.cc',
168 'files/file_util_proxy.h',
169 'files/important_file_writer.h',
170 'files/important_file_writer.cc',
171 'files/scoped_temp_dir.cc',
172 'files/scoped_temp_dir.h',
183 'hi_res_timer_manager_posix.cc',
184 'hi_res_timer_manager_win.cc',
185 'hi_res_timer_manager.h',
188 'ios/device_util.mm',
191 'ios/scoped_critical_action.h',
192 'ios/scoped_critical_action.mm',
193 'json/json_file_value_serializer.cc',
194 'json/json_file_value_serializer.h',
195 'json/json_parser.cc',
196 'json/json_parser.h',
197 'json/json_reader.cc',
198 'json/json_reader.h',
199 'json/json_string_value_serializer.cc',
200 'json/json_string_value_serializer.h',
201 'json/json_value_converter.h',
202 'json/json_writer.cc',
203 'json/json_writer.h',
204 'json/string_escape.cc',
205 'json/string_escape.h',
214 'mac/authorization_util.h',
215 'mac/authorization_util.mm',
216 'mac/bind_objc_block.h',
217 'mac/bundle_locations.h',
218 'mac/bundle_locations.mm',
219 'mac/cocoa_protocols.h',
220 'mac/foundation_util.h',
221 'mac/foundation_util.mm',
224 'mac/libdispatch_task_runner.cc',
225 'mac/libdispatch_task_runner.h',
227 'mac/mac_logging.cc',
230 'mac/objc_property_releaser.h',
231 'mac/objc_property_releaser.mm',
232 'mac/os_crash_dumps.cc',
233 'mac/os_crash_dumps.h',
234 'mac/scoped_aedesc.h',
235 'mac/scoped_authorizationref.h',
236 'mac/scoped_block.h',
237 'mac/scoped_cftyperef.h',
238 'mac/scoped_ioobject.h',
239 'mac/scoped_launch_data.h',
240 'mac/scoped_mach_port.cc',
241 'mac/scoped_mach_port.h',
242 'mac/scoped_nsautorelease_pool.h',
243 'mac/scoped_nsautorelease_pool.mm',
244 'mac/scoped_nsexception_enabler.h',
245 'mac/scoped_nsexception_enabler.mm',
246 'mac/scoped_sending_event.h',
247 'mac/scoped_sending_event.mm',
250 'memory/aligned_memory.cc',
251 'memory/aligned_memory.h',
252 'memory/discardable_memory.cc',
253 'memory/discardable_memory.h',
254 'memory/discardable_memory_android.cc',
255 'memory/discardable_memory_mac.cc',
256 'memory/linked_ptr.h',
257 'memory/manual_constructor.h',
258 'memory/raw_scoped_refptr_mismatch_checker.h',
259 'memory/ref_counted.cc',
260 'memory/ref_counted.h',
261 'memory/ref_counted_memory.cc',
262 'memory/ref_counted_memory.h',
263 'memory/scoped_handle.h',
264 'memory/scoped_nsobject.h',
265 'memory/scoped_open_process.h',
266 'memory/scoped_policy.h',
267 'memory/scoped_ptr.h',
268 'memory/scoped_vector.h',
269 'memory/singleton.cc',
270 'memory/singleton.h',
271 'memory/weak_ptr.cc',
275 'message_loop_proxy.cc',
276 'message_loop_proxy.h',
277 'message_loop_proxy_impl.cc',
278 'message_loop_proxy_impl.h',
281 'message_pump_android.cc',
282 'message_pump_android.h',
283 'message_pump_default.cc',
284 'message_pump_default.h',
285 'message_pump_win.cc',
286 'message_pump_win.h',
287 'metrics/sample_map.cc',
288 'metrics/sample_map.h',
289 'metrics/sample_vector.cc',
290 'metrics/sample_vector.h',
291 'metrics/bucket_ranges.cc',
292 'metrics/bucket_ranges.h',
293 'metrics/histogram.cc',
294 'metrics/histogram.h',
295 'metrics/histogram_base.cc',
296 'metrics/histogram_base.h',
297 'metrics/histogram_flattener.h',
298 'metrics/histogram_samples.cc',
299 'metrics/histogram_samples.h',
300 'metrics/histogram_snapshot_manager.cc',
301 'metrics/histogram_snapshot_manager.h',
302 'metrics/sparse_histogram.cc',
303 'metrics/sparse_histogram.h',
304 'metrics/statistics_recorder.cc',
305 'metrics/statistics_recorder.h',
306 'metrics/stats_counters.cc',
307 'metrics/stats_counters.h',
308 'metrics/stats_table.cc',
309 'metrics/stats_table.h',
312 'native_library_mac.mm',
313 'native_library_posix.cc',
314 'native_library_win.cc',
316 'observer_list_threadsafe.h',
317 'os_compat_android.cc',
318 'os_compat_android.h',
329 'platform_file_posix.cc',
330 'platform_file_win.cc',
332 'posix/eintr_wrapper.h',
333 'posix/global_descriptors.cc',
334 'posix/global_descriptors.h',
335 'posix/unix_domain_socket_linux.cc',
336 'posix/unix_domain_socket_linux.h',
339 'process_info_mac.cc',
340 'process_info_win.cc',
345 'process_util_freebsd.cc',
346 'process_util_ios.mm',
347 'process_util_linux.cc',
348 'process_util_mac.mm',
349 'process_util_openbsd.cc',
350 'process_util_posix.cc',
351 'process_util_win.cc',
353 'profiler/scoped_profile.cc',
354 'profiler/scoped_profile.h',
355 'profiler/alternate_timer.cc',
356 'profiler/alternate_timer.h',
357 'profiler/tracked_time.cc',
358 'profiler/tracked_time.h',
362 'rand_util_posix.cc',
367 'safe_strerror_posix.cc',
368 'safe_strerror_posix.h',
369 'scoped_native_library.cc',
370 'scoped_native_library.h',
371 'sequence_checker.h',
372 'sequence_checker_impl.cc',
373 'sequence_checker_impl.h',
374 'sequenced_task_runner.cc',
375 'sequenced_task_runner.h',
376 'sequenced_task_runner_helpers.h',
381 'shared_memory_android.cc',
382 'shared_memory_nacl.cc',
383 'shared_memory_posix.cc',
384 'shared_memory_win.cc',
385 'single_thread_task_runner.h',
392 'string_util_posix.h',
398 'strings/string_split.cc',
399 'strings/string_split.h',
400 'strings/string_number_conversions.cc',
401 'strings/string_number_conversions.h',
402 'strings/string_tokenizer.h',
403 'strings/stringize_macros.h',
404 'strings/sys_string_conversions.h',
405 'strings/sys_string_conversions_mac.mm',
406 'strings/sys_string_conversions_posix.cc',
407 'strings/sys_string_conversions_win.cc',
408 'strings/utf_offset_string_conversions.cc',
409 'strings/utf_offset_string_conversions.h',
410 'strings/utf_string_conversion_utils.cc',
411 'strings/utf_string_conversion_utils.h',
412 'supports_user_data.cc',
413 'supports_user_data.h',
414 'synchronization/cancellation_flag.cc',
415 'synchronization/cancellation_flag.h',
416 'synchronization/condition_variable.h',
417 'synchronization/condition_variable_posix.cc',
418 'synchronization/condition_variable_win.cc',
419 'synchronization/lock.cc',
420 'synchronization/lock.h',
421 'synchronization/lock_impl.h',
422 'synchronization/lock_impl_posix.cc',
423 'synchronization/lock_impl_win.cc',
424 'synchronization/spin_wait.h',
425 'synchronization/waitable_event.h',
426 'synchronization/waitable_event_posix.cc',
427 'synchronization/waitable_event_watcher.h',
428 'synchronization/waitable_event_watcher_posix.cc',
429 'synchronization/waitable_event_watcher_win.cc',
430 'synchronization/waitable_event_win.cc',
431 'system_monitor/system_monitor.cc',
432 'system_monitor/system_monitor.h',
433 'system_monitor/system_monitor_android.cc',
434 'system_monitor/system_monitor_android.h',
435 'system_monitor/system_monitor_ios.mm',
436 'system_monitor/system_monitor_mac.mm',
437 'system_monitor/system_monitor_posix.cc',
438 'system_monitor/system_monitor_win.cc',
442 'sys_info_android.cc',
443 'sys_info_chromeos.cc',
444 'sys_info_freebsd.cc',
448 'sys_info_openbsd.cc',
453 'task_runner_util.h',
455 'thread_task_runner_handle.cc',
456 'thread_task_runner_handle.h',
457 'threading/non_thread_safe.h',
458 'threading/non_thread_safe_impl.cc',
459 'threading/non_thread_safe_impl.h',
460 'threading/platform_thread.h',
461 'threading/platform_thread_mac.mm',
462 'threading/platform_thread_posix.cc',
463 'threading/platform_thread_win.cc',
464 'threading/post_task_and_reply_impl.cc',
465 'threading/post_task_and_reply_impl.h',
466 'threading/sequenced_worker_pool.cc',
467 'threading/sequenced_worker_pool.h',
468 'threading/simple_thread.cc',
469 'threading/simple_thread.h',
470 'threading/thread.cc',
471 'threading/thread.h',
472 'threading/thread_checker.h',
473 'threading/thread_checker_impl.cc',
474 'threading/thread_checker_impl.h',
475 'threading/thread_collision_warner.cc',
476 'threading/thread_collision_warner.h',
477 'threading/thread_id_name_manager.cc',
478 'threading/thread_id_name_manager.h',
479 'threading/thread_local.h',
480 'threading/thread_local_posix.cc',
481 'threading/thread_local_storage.h',
482 'threading/thread_local_storage_posix.cc',
483 'threading/thread_local_storage_win.cc',
484 'threading/thread_local_win.cc',
485 'threading/thread_restrictions.h',
486 'threading/thread_restrictions.cc',
487 'threading/watchdog.cc',
488 'threading/watchdog.h',
489 'threading/worker_pool.h',
490 'threading/worker_pool.cc',
491 'threading/worker_pool_posix.cc',
492 'threading/worker_pool_posix.h',
493 'threading/worker_pool_win.cc',
501 'tracked_objects.cc',
506 'utf_string_conversions.cc',
507 'utf_string_conversions.h',
510 'value_conversions.cc',
511 'value_conversions.h',
516 'nix/mime_util_xdg.cc',
517 'nix/mime_util_xdg.h',
520 'win/enum_variant.h',
521 'win/enum_variant.cc',
522 'win/event_trace_consumer.h',
523 'win/event_trace_controller.cc',
524 'win/event_trace_controller.h',
525 'win/event_trace_provider.cc',
526 'win/event_trace_provider.h',
529 'win/iat_patch_function.cc',
530 'win/iat_patch_function.h',
531 'win/iunknown_impl.h',
532 'win/iunknown_impl.cc',
535 'win/object_watcher.cc',
536 'win/object_watcher.h',
539 'win/resource_util.cc',
540 'win/resource_util.h',
541 'win/sampling_profiler.cc',
542 'win/sampling_profiler.h',
543 'win/scoped_bstr.cc',
545 'win/scoped_co_mem.h',
546 'win/scoped_com_initializer.h',
547 'win/scoped_comptr.h',
548 'win/scoped_gdi_object.h',
549 'win/scoped_handle.cc',
550 'win/scoped_handle.h',
552 'win/scoped_hglobal.h',
553 'win/scoped_process_information.cc',
554 'win/scoped_process_information.h',
555 'win/scoped_propvariant.h',
556 'win/scoped_select_object.h',
557 'win/scoped_variant.cc',
558 'win/scoped_variant.h',
561 'win/startup_information.cc',
562 'win/startup_information.h',
563 'win/text_services_message_filter.cc',
564 'win/text_services_message_filter.h',
565 'win/windows_version.cc',
566 'win/windows_version.h',
569 'win/wrapped_window_proc.cc',
570 'win/wrapped_window_proc.h',
573 'BASE_IMPLEMENTATION',
578 'msvs_disabled_warnings': [
581 'target_conditions': [
582 ['<(use_glib)==0 or >(nacl_untrusted_build)==1', {
584 ['exclude', '^nix/'],
587 'atomicops_internals_x86_gcc.cc',
588 'message_pump_glib.cc',
589 'message_pump_aurax11.cc',
592 ['<(toolkit_uses_gtk)==0 or >(nacl_untrusted_build)==1', {
593 'sources!': ['message_pump_gtk.cc'],
595 ['(OS != "linux" and <(os_bsd) != 1 and OS != "android") or >(nacl_untrusted_build)==1', {
597 # Not automatically excluded by the *linux.cc rules.
602 ['>(nacl_untrusted_build)==1', {
604 'allocator/type_profiler_control.cc',
605 'allocator/type_profiler_control.h',
609 'debug/stack_trace_posix.cc',
611 'file_util_posix.cc',
612 'file_util_proxy.cc',
613 'files/file_path_watcher_kqueue.cc',
614 'native_library_posix.cc',
616 'platform_file_posix.cc',
617 'posix/unix_domain_socket_linux.cc',
620 'process_util_posix.cc',
621 'rand_util_posix.cc',
622 'scoped_native_library.cc',
623 'files/scoped_temp_dir.cc',
624 'shared_memory_posix.cc',
626 'threading/sequenced_worker_pool.cc',
627 'third_party/dynamic_annotations/dynamic_annotations.c',
629 # Metrics won't work in the NaCl sandbox.
630 'sources/': [ ['exclude', '^metrics/'] ],
632 ['OS == "android" and >(nacl_untrusted_build)==0', {
634 'base_paths_posix.cc',
635 'files/file_path_watcher_kqueue.cc',
636 'files/file_path_watcher_stub.cc',
637 'system_monitor/system_monitor_posix.cc',
640 ['include', '^files/file_path_watcher_linux\\.cc$'],
641 ['include', '^process_util_linux\\.cc$'],
642 ['include', '^posix/unix_domain_socket_linux\\.cc$'],
643 ['include', '^strings/sys_string_conversions_posix\\.cc$'],
644 ['include', '^sys_info_linux\\.cc$'],
645 ['include', '^worker_pool_linux\\.cc$'],
650 # Pull in specific Mac files for iOS (which have been filtered out
651 # by file name rules).
652 ['include', '^atomicops_internals_mac\\.'],
653 ['include', '^base_paths_mac\\.'],
654 ['include', '^file_util_mac\\.'],
655 ['include', '^file_version_info_mac\\.'],
656 ['include', '^mac/bundle_locations\\.'],
657 ['include', '^mac/foundation_util\\.'],
658 ['include', '^mac/mac_logging\\.'],
659 ['include', '^mac/objc_property_releaser\\.'],
660 ['include', '^mac/scoped_mach_port\\.'],
661 ['include', '^mac/scoped_nsautorelease_pool\\.'],
662 ['include', '^memory/discardable_memory_mac\\.'],
663 ['include', '^message_pump_mac\\.'],
664 ['include', '^threading/platform_thread_mac\\.'],
665 ['include', '^strings/sys_string_conversions_mac\\.'],
666 ['include', '^time_mac\\.'],
667 ['include', '^worker_pool_mac\\.'],
668 # Exclude all process_util except the minimal implementation
669 # needed on iOS (mostly for unit tests).
670 ['exclude', '^process_util'],
671 ['include', '^process_util_ios\\.mm$'],
674 'message_pump_libevent.cc'
677 ['OS != "mac" or >(nacl_untrusted_build)==1', {
679 'mac/scoped_aedesc.h'
682 # For now, just test the *BSD platforms enough to exclude them.
683 # Subsequent changes will include them further.
684 ['OS != "freebsd" or >(nacl_untrusted_build)==1', {
685 'sources/': [ ['exclude', '_freebsd\\.cc$'] ],
688 ['OS != "openbsd" or >(nacl_untrusted_build)==1', {
689 'sources/': [ ['exclude', '_openbsd\\.cc$'] ],
692 ['OS != "win" or >(nacl_untrusted_build)==1', {
693 'sources/': [ ['exclude', '^win/'] ],
696 ['OS != "android" or >(nacl_untrusted_build)==1', {
697 'sources/': [ ['exclude', '^android/'] ],
700 ['OS == "win" and >(nacl_untrusted_build)==0', {
702 '<(DEPTH)/third_party/wtl/include',
705 'event_recorder_stubs.cc',
706 'files/file_path_watcher_kqueue.cc',
707 'files/file_path_watcher_stub.cc',
708 'message_pump_libevent.cc',
709 'posix/file_descriptor_shuffle.cc',
710 # Not using sha1_win.cc because it may have caused a
711 # regression to page cycler moz.
716 ['OS == "linux" and >(nacl_untrusted_build)==0', {
718 'files/file_path_watcher_kqueue.cc',
719 'files/file_path_watcher_stub.cc',
722 ['(OS == "mac" or OS == "ios") and >(nacl_untrusted_build)==0', {
724 ['exclude', '^files/file_path_watcher_stub\\.cc$'],
725 ['exclude', '^base_paths_posix\\.cc$'],
726 ['exclude', '^native_library_posix\\.cc$'],
727 ['exclude', '^strings/sys_string_conversions_posix\\.cc$'],
730 ['<(os_bsd)==1 and >(nacl_untrusted_build)==0', {
732 ['exclude', '^files/file_path_watcher_linux\\.cc$'],
733 ['exclude', '^files/file_path_watcher_stub\\.cc$'],
734 ['exclude', '^file_util_linux\\.cc$'],
735 ['exclude', '^process_linux\\.cc$'],
736 ['exclude', '^process_util_linux\\.cc$'],
737 ['exclude', '^sys_info_linux\\.cc$'],
740 ['<(chromeos)!=1 or >(nacl_untrusted_build)==1', {
742 ['exclude', '^chromeos/'],
745 # Remove all unnecessary files for build_nexe.py to avoid exceeding
746 # command-line-string limitation when building NaCl on Windows.
747 ['OS == "win" and >(nacl_untrusted_build)==1', {
748 'sources/': [ ['exclude', '\\.h$'] ],
750 ['<(use_system_nspr)==1 and >(nacl_untrusted_build)==0', {
752 ['exclude', '^third_party/nspr/'],