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 # The core sync library.
12 # TODO(akalin): Rename this to something like 'sync_core' and
13 # reserve the 'sync' name for the overarching library that clients
16 'target_name': 'sync',
17 # TODO(akalin): Change this to '<(component)'. When we rename
18 # this to 'sync_core' and make the overarching 'sync' library,
19 # make that one '<(component)'.
20 'type': 'static_library',
21 'variables': { 'enable_wexit_time_destructors': 1, },
26 'SYNC_IMPLEMENTATION',
29 '../base/base.gyp:base',
30 '../build/temp_gyp/googleurl.gyp:googleurl',
31 '../crypto/crypto.gyp:crypto',
32 '../google_apis/google_apis.gyp:google_apis',
35 'protocol/sync_proto.gyp:sync_proto',
37 'export_dependent_settings': [
38 # Propagate sync_proto since our headers include its generated
40 'protocol/sync_proto.gyp:sync_proto',
44 'internal_api/public/base/enum_set.h',
45 'internal_api/public/base/invalidation.cc',
46 'internal_api/public/base/invalidation.h',
47 'internal_api/public/base/model_type.h',
48 'internal_api/public/base/model_type_invalidation_map.cc',
49 'internal_api/public/base/model_type_invalidation_map.h',
50 'internal_api/public/base/node_ordinal.cc',
51 'internal_api/public/base/node_ordinal.h',
52 'internal_api/public/base/ordinal.h',
53 'internal_api/public/engine/model_safe_worker.cc',
54 'internal_api/public/engine/model_safe_worker.h',
55 'internal_api/public/engine/passive_model_worker.cc',
56 'internal_api/public/engine/passive_model_worker.h',
57 'internal_api/public/engine/polling_constants.cc',
58 'internal_api/public/engine/polling_constants.h',
59 'internal_api/public/engine/sync_status.cc',
60 'internal_api/public/engine/sync_status.h',
61 'internal_api/public/sessions/model_neutral_state.cc',
62 'internal_api/public/sessions/model_neutral_state.h',
63 'internal_api/public/sessions/sync_session_snapshot.cc',
64 'internal_api/public/sessions/sync_session_snapshot.h',
65 'internal_api/public/sessions/sync_source_info.cc',
66 'internal_api/public/sessions/sync_source_info.h',
67 'internal_api/public/util/experiments.h',
68 'internal_api/public/util/immutable.h',
69 'internal_api/public/util/syncer_error.cc',
70 'internal_api/public/util/syncer_error.h',
71 'internal_api/public/util/sync_string_conversions.cc',
72 'internal_api/public/util/sync_string_conversions.h',
73 'internal_api/public/util/report_unrecoverable_error_function.h',
74 'internal_api/public/util/unrecoverable_error_handler.h',
75 'internal_api/public/util/unrecoverable_error_info.h',
76 'internal_api/public/util/unrecoverable_error_info.cc',
77 'internal_api/public/util/weak_handle.cc',
78 'internal_api/public/util/weak_handle.h',
79 'engine/all_status.cc',
80 'engine/all_status.h',
81 'engine/apply_control_data_updates.cc',
82 'engine/apply_control_data_updates.h',
83 'engine/apply_updates_command.cc',
84 'engine/apply_updates_command.h',
85 'engine/backoff_delay_provider.cc',
86 'engine/backoff_delay_provider.h',
87 'engine/build_commit_command.cc',
88 'engine/build_commit_command.h',
91 'engine/conflict_resolver.cc',
92 'engine/conflict_resolver.h',
93 'engine/conflict_util.cc',
94 'engine/conflict_util.h',
95 'engine/download_updates_command.cc',
96 'engine/download_updates_command.h',
97 'engine/get_commit_ids_command.cc',
98 'engine/get_commit_ids_command.h',
99 'engine/model_changing_syncer_command.cc',
100 'engine/model_changing_syncer_command.h',
101 'engine/net/server_connection_manager.cc',
102 'engine/net/server_connection_manager.h',
103 'engine/net/url_translator.cc',
104 'engine/net/url_translator.h',
105 'engine/nudge_source.cc',
106 'engine/nudge_source.h',
107 'engine/process_commit_response_command.cc',
108 'engine/process_commit_response_command.h',
109 'engine/process_updates_command.cc',
110 'engine/process_updates_command.h',
111 'engine/resolve_conflicts_command.cc',
112 'engine/resolve_conflicts_command.h',
113 'engine/store_timestamps_command.cc',
114 'engine/store_timestamps_command.h',
115 'engine/sync_engine_event.cc',
116 'engine/sync_engine_event.h',
117 'engine/sync_scheduler.cc',
118 'engine/sync_scheduler.h',
119 'engine/sync_scheduler_impl.cc',
120 'engine/sync_scheduler_impl.h',
123 'engine/syncer_command.cc',
124 'engine/syncer_command.h',
125 'engine/syncer_proto_util.cc',
126 'engine/syncer_proto_util.h',
127 'engine/syncer_types.h',
128 'engine/syncer_util.cc',
129 'engine/syncer_util.h',
130 'engine/throttled_data_type_tracker.cc',
131 'engine/throttled_data_type_tracker.h',
132 'engine/traffic_logger.cc',
133 'engine/traffic_logger.h',
134 'engine/traffic_recorder.cc',
135 'engine/traffic_recorder.h',
136 'engine/update_applicator.cc',
137 'engine/update_applicator.h',
138 'engine/verify_updates_command.cc',
139 'engine/verify_updates_command.h',
143 'js/js_controller.h',
144 'js/js_event_details.cc',
145 'js/js_event_details.h',
146 'js/js_event_handler.h',
147 'js/js_reply_handler.h',
148 'js/sync_js_controller.cc',
149 'js/sync_js_controller.h',
150 'protocol/proto_enum_conversions.cc',
151 'protocol/proto_enum_conversions.h',
152 'protocol/proto_value_conversions.cc',
153 'protocol/proto_value_conversions.h',
154 'protocol/sync_protocol_error.cc',
155 'protocol/sync_protocol_error.h',
156 'sessions/debug_info_getter.h',
157 'sessions/ordered_commit_set.cc',
158 'sessions/ordered_commit_set.h',
159 'sessions/session_state.cc',
160 'sessions/session_state.h',
161 'sessions/status_controller.cc',
162 'sessions/status_controller.h',
163 'sessions/sync_session.cc',
164 'sessions/sync_session.h',
165 'sessions/sync_session_context.cc',
166 'sessions/sync_session_context.h',
167 'syncable/base_transaction.cc',
168 'syncable/base_transaction.h',
170 'syncable/dir_open_result.h',
171 'syncable/directory.cc',
172 'syncable/directory.h',
173 'syncable/directory_backing_store.cc',
174 'syncable/directory_backing_store.h',
175 'syncable/directory_change_delegate.h',
178 'syncable/entry_kernel.cc',
179 'syncable/entry_kernel.h',
180 'syncable/in_memory_directory_backing_store.cc',
181 'syncable/in_memory_directory_backing_store.h',
182 'syncable/invalid_directory_backing_store.cc',
183 'syncable/invalid_directory_backing_store.h',
184 'syncable/metahandle_set.h',
185 'syncable/model_type.cc',
186 'syncable/mutable_entry.cc',
187 'syncable/mutable_entry.h',
188 'syncable/nigori_handler.h',
189 'syncable/nigori_handler.cc',
190 'syncable/nigori_util.cc',
191 'syncable/nigori_util.h',
192 'syncable/on_disk_directory_backing_store.cc',
193 'syncable/on_disk_directory_backing_store.h',
194 'syncable/read_transaction.cc',
195 'syncable/read_transaction.h',
196 'syncable/scoped_kernel_lock.h',
197 'syncable/syncable-inl.h',
198 'syncable/syncable_changes_version.h',
199 'syncable/syncable_columns.h',
200 'syncable/syncable_enum_conversions.cc',
201 'syncable/syncable_enum_conversions.h',
202 'syncable/syncable_id.cc',
203 'syncable/syncable_id.h',
204 'syncable/syncable_proto_util.cc',
205 'syncable/syncable_proto_util.h',
206 'syncable/syncable_util.cc',
207 'syncable/syncable_util.h',
208 'syncable/transaction_observer.h',
209 'syncable/write_transaction.cc',
210 'syncable/write_transaction.h',
211 'syncable/write_transaction_info.cc',
212 'syncable/write_transaction_info.h',
213 'util/cryptographer.cc',
214 'util/cryptographer.h',
216 # TODO(akalin): Figure out a better place to put
217 # data_encryption_win*; it's also used by autofill.
218 'util/data_encryption_win.cc',
219 'util/data_encryption_win.h',
221 'util/data_type_histogram.h',
223 'util/extensions_activity_monitor.cc',
224 'util/extensions_activity_monitor.h',
225 'util/get_session_name.cc',
226 'util/get_session_name.h',
227 'util/get_session_name_mac.mm',
228 'util/get_session_name_mac.h',
229 'util/get_session_name_win.cc',
230 'util/get_session_name_win.h',
235 'util/session_utils_android.cc',
236 'util/session_utils_android.h',
242 # The sync notifications library.
244 'target_name': 'sync_notifier',
245 'type': 'static_library',
246 'variables': { 'enable_wexit_time_destructors': 1, },
251 '../base/base.gyp:base',
252 '../jingle/jingle.gyp:jingle_glue',
253 '../jingle/jingle.gyp:notifier',
254 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation',
255 # TODO(akalin): Remove this (http://crbug.com/133352).
256 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_proto_cpp',
259 'export_dependent_settings': [
260 '../jingle/jingle.gyp:notifier',
261 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation',
264 'notifier/invalidation_handler.h',
265 'notifier/invalidation_util.cc',
266 'notifier/invalidation_util.h',
267 'notifier/invalidator_factory.cc',
268 'notifier/invalidator_factory.h',
269 'notifier/invalidator.h',
270 'notifier/invalidator_registrar.cc',
271 'notifier/invalidator_registrar.h',
272 'notifier/invalidator_state.cc',
273 'notifier/invalidator_state.h',
274 'notifier/object_id_invalidation_map.cc',
275 'notifier/object_id_invalidation_map.h',
278 ['OS != "android"', {
280 'notifier/invalidation_notifier.cc',
281 'notifier/invalidation_notifier.h',
282 'notifier/invalidation_state_tracker.h',
283 'notifier/non_blocking_invalidator.cc',
284 'notifier/non_blocking_invalidator.h',
285 'notifier/p2p_invalidator.cc',
286 'notifier/p2p_invalidator.h',
287 'notifier/push_client_channel.cc',
288 'notifier/push_client_channel.h',
289 'notifier/registration_manager.cc',
290 'notifier/registration_manager.h',
291 'notifier/state_writer.h',
292 'notifier/sync_invalidation_listener.cc',
293 'notifier/sync_invalidation_listener.h',
294 'notifier/sync_system_resources.cc',
295 'notifier/sync_system_resources.h',
300 '../third_party/libjingle/libjingle.gyp:libjingle',
305 # The sync internal API library.
307 'target_name': 'syncapi_core',
308 'type': 'static_library',
309 'variables': { 'enable_wexit_time_destructors': 1, },
314 '../base/base.gyp:base',
315 '../build/temp_gyp/googleurl.gyp:googleurl',
316 '../net/net.gyp:net',
317 'protocol/sync_proto.gyp:sync_proto',
321 'export_dependent_settings': [
322 # Propagate sync_proto since our headers include its generated
324 'protocol/sync_proto.gyp:sync_proto',
328 'internal_api/public/base_node.h',
329 'internal_api/public/base_transaction.h',
330 'internal_api/public/change_record.h',
331 'internal_api/public/configure_reason.h',
332 'internal_api/public/http_bridge.h',
333 'internal_api/public/http_post_provider_factory.h',
334 'internal_api/public/http_post_provider_interface.h',
335 'internal_api/public/internal_components_factory.h',
336 'internal_api/public/internal_components_factory_impl.h',
337 'internal_api/public/read_node.h',
338 'internal_api/public/read_transaction.h',
339 'internal_api/public/sync_manager.h',
340 'internal_api/public/sync_encryption_handler.cc',
341 'internal_api/public/sync_encryption_handler.h',
342 'internal_api/public/sync_manager.cc',
343 'internal_api/public/sync_manager_factory.h',
344 'internal_api/public/user_share.h',
345 'internal_api/public/write_node.h',
346 'internal_api/public/write_transaction.h',
347 'internal_api/base_node.cc',
348 'internal_api/base_transaction.cc',
349 'internal_api/change_record.cc',
350 'internal_api/change_reorder_buffer.cc',
351 'internal_api/change_reorder_buffer.h',
352 'internal_api/debug_info_event_listener.cc',
353 'internal_api/debug_info_event_listener.h',
354 'internal_api/http_bridge.cc',
355 'internal_api/internal_components_factory_impl.cc',
356 'internal_api/js_mutation_event_observer.cc',
357 'internal_api/js_mutation_event_observer.h',
358 'internal_api/js_sync_encryption_handler_observer.cc',
359 'internal_api/js_sync_encryption_handler_observer.h',
360 'internal_api/js_sync_manager_observer.cc',
361 'internal_api/js_sync_manager_observer.h',
362 'internal_api/read_node.cc',
363 'internal_api/read_transaction.cc',
364 'internal_api/syncapi_internal.cc',
365 'internal_api/syncapi_internal.h',
366 'internal_api/syncapi_server_connection_manager.cc',
367 'internal_api/syncapi_server_connection_manager.h',
368 'internal_api/sync_encryption_handler_impl.cc',
369 'internal_api/sync_encryption_handler_impl.h',
370 'internal_api/sync_manager_factory.cc',
371 'internal_api/sync_manager_impl.cc',
372 'internal_api/sync_manager_impl.h',
373 'internal_api/user_share.cc',
374 'internal_api/write_node.cc',
375 'internal_api/write_transaction.cc',
379 # The sync external API library.
381 'target_name': 'syncapi_service',
382 'type': 'static_library',
383 'variables': { 'enable_wexit_time_destructors': 1, },
388 '../base/base.gyp:base',
389 'protocol/sync_proto.gyp:sync_proto',
392 # We avoid including header files from sync_proto in our public
393 # header files so we don't need to export its settings.
395 'api/string_ordinal.h',
396 'api/syncable_service.cc',
397 'api/syncable_service.h',
401 'api/sync_change.cc',
402 'api/sync_change_processor.h',
403 'api/sync_change_processor.cc',
406 'api/sync_error_factory.h',
407 'api/sync_error_factory.cc',
412 # Test support files for the 'sync' target.
414 'target_name': 'test_support_sync',
415 'type': 'static_library',
416 'variables': { 'enable_wexit_time_destructors': 1, },
421 '../base/base.gyp:base',
422 '../testing/gmock.gyp:gmock',
423 '../testing/gtest.gyp:gtest',
424 'protocol/sync_proto.gyp:sync_proto',
427 'export_dependent_settings': [
428 '../testing/gmock.gyp:gmock',
429 '../testing/gtest.gyp:gtest',
430 'protocol/sync_proto.gyp:sync_proto',
434 'internal_api/public/base/invalidation_test_util.cc',
435 'internal_api/public/base/invalidation_test_util.h',
436 'internal_api/public/base/model_type_invalidation_map_test_util.cc',
437 'internal_api/public/base/model_type_invalidation_map_test_util.h',
438 'internal_api/public/base/model_type_test_util.cc',
439 'internal_api/public/base/model_type_test_util.h',
440 'js/js_test_util.cc',
442 'sessions/test_util.cc',
443 'sessions/test_util.h',
444 'syncable/syncable_mock.cc',
445 'syncable/syncable_mock.h',
446 'test/callback_counter.h',
447 'test/engine/fake_model_worker.cc',
448 'test/engine/fake_model_worker.h',
449 'test/engine/fake_sync_scheduler.cc',
450 'test/engine/fake_sync_scheduler.h',
451 'test/engine/mock_connection_manager.cc',
452 'test/engine/mock_connection_manager.h',
453 'test/engine/syncer_command_test.cc',
454 'test/engine/syncer_command_test.h',
455 'test/engine/test_directory_setter_upper.cc',
456 'test/engine/test_directory_setter_upper.h',
457 'test/engine/test_id_factory.h',
458 'test/engine/test_syncable_utils.cc',
459 'test/engine/test_syncable_utils.h',
460 'test/fake_encryptor.cc',
461 'test/fake_encryptor.h',
462 'test/fake_sync_encryption_handler.h',
463 'test/fake_sync_encryption_handler.cc',
464 'test/fake_extensions_activity_monitor.cc',
465 'test/fake_extensions_activity_monitor.h',
466 'test/null_directory_change_delegate.cc',
467 'test/null_directory_change_delegate.h',
468 'test/null_transaction_observer.cc',
469 'test/null_transaction_observer.h',
470 'test/sessions/test_scoped_session_event_listener.h',
471 'test/test_directory_backing_store.cc',
472 'test/test_directory_backing_store.h',
473 'util/test_unrecoverable_error_handler.cc',
474 'util/test_unrecoverable_error_handler.h',
478 # Test support files for the 'sync_notifier' target.
480 'target_name': 'test_support_sync_notifier',
481 'type': 'static_library',
486 '../testing/gmock.gyp:gmock',
487 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_proto_cpp',
490 'export_dependent_settings': [
491 '../testing/gmock.gyp:gmock',
492 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_proto_cpp',
496 'notifier/fake_invalidation_state_tracker.cc',
497 'notifier/fake_invalidation_state_tracker.h',
498 'notifier/fake_invalidator.cc',
499 'notifier/fake_invalidator.h',
500 'notifier/fake_invalidation_handler.cc',
501 'notifier/fake_invalidation_handler.h',
502 'notifier/invalidator_test_template.cc',
503 'notifier/invalidator_test_template.h',
504 'notifier/object_id_invalidation_map_test_util.cc',
505 'notifier/object_id_invalidation_map_test_util.h',
509 # Test support files for the 'syncapi_core' target.
511 'target_name': 'test_support_syncapi_core',
512 'type': 'static_library',
513 'variables': { 'enable_wexit_time_destructors': 1, },
518 '../base/base.gyp:base',
519 '../testing/gtest.gyp:gtest',
524 'export_dependent_settings': [
525 '../testing/gtest.gyp:gtest',
531 'internal_api/public/test/fake_sync_manager.h',
532 'internal_api/public/test/test_entry_factory.h',
533 'internal_api/public/test/test_internal_components_factory.h',
534 'internal_api/public/test/test_user_share.h',
535 'internal_api/test/fake_sync_manager.cc',
536 'internal_api/test/test_entry_factory.cc',
537 'internal_api/test/test_internal_components_factory.cc',
538 'internal_api/test/test_user_share.cc',
542 # Test support files for the 'syncapi_service' target.
544 'target_name': 'test_support_syncapi_service',
545 'type': 'static_library',
550 '../testing/gmock.gyp:gmock',
553 'export_dependent_settings': [
554 '../testing/gmock.gyp:gmock',
558 'api/fake_syncable_service.cc',
559 'api/fake_syncable_service.h',
560 'api/sync_error_factory_mock.cc',
561 'api/sync_error_factory_mock.h',
565 # Unit tests for the 'sync' target. This cannot be a static
566 # library because the unit test files have to be compiled directly
567 # into the executable, so we push the target files to the
568 # depending executable target via direct_dependent_settings.
570 'target_name': 'sync_tests',
572 # We only want unit test executables to include this target.
573 'suppress_wildcard': 1,
575 '../base/base.gyp:base',
576 '../testing/gmock.gyp:gmock',
577 '../testing/gtest.gyp:gtest',
578 'protocol/sync_proto.gyp:sync_proto',
582 # Propagate all dependencies since the actual compilation
583 # happens in the dependents.
584 'export_dependent_settings': [
585 '../base/base.gyp:base',
586 '../testing/gmock.gyp:gmock',
587 '../testing/gtest.gyp:gtest',
588 'protocol/sync_proto.gyp:sync_proto',
592 'direct_dependent_settings': {
597 'internal_api/public/base/enum_set_unittest.cc',
598 'internal_api/public/base/model_type_invalidation_map_unittest.cc',
599 'internal_api/public/base/node_ordinal_unittest.cc',
600 'internal_api/public/base/ordinal_unittest.cc',
601 'internal_api/public/engine/model_safe_worker_unittest.cc',
602 'internal_api/public/util/immutable_unittest.cc',
603 'engine/apply_control_data_updates_unittest.cc',
604 'engine/apply_updates_command_unittest.cc',
605 'engine/backoff_delay_provider_unittest.cc',
606 'engine/build_commit_command_unittest.cc',
607 'engine/download_updates_command_unittest.cc',
608 'engine/model_changing_syncer_command_unittest.cc',
609 'engine/process_commit_response_command_unittest.cc',
610 'engine/process_updates_command_unittest.cc',
611 'engine/sync_scheduler_unittest.cc',
612 'engine/sync_scheduler_whitebox_unittest.cc',
613 'engine/syncer_proto_util_unittest.cc',
614 'engine/syncer_unittest.cc',
615 'engine/throttled_data_type_tracker_unittest.cc',
616 'engine/traffic_recorder_unittest.cc',
617 'engine/verify_updates_command_unittest.cc',
618 'js/js_arg_list_unittest.cc',
619 'js/js_event_details_unittest.cc',
620 'js/sync_js_controller_unittest.cc',
621 'protocol/proto_enum_conversions_unittest.cc',
622 'protocol/proto_value_conversions_unittest.cc',
623 'sessions/ordered_commit_set_unittest.cc',
624 'sessions/session_state_unittest.cc',
625 'sessions/status_controller_unittest.cc',
626 'sessions/sync_session_unittest.cc',
627 'syncable/directory_backing_store_unittest.cc',
628 'syncable/model_type_unittest.cc',
629 'syncable/nigori_util_unittest.cc',
630 'syncable/syncable_enum_conversions_unittest.cc',
631 'syncable/syncable_id_unittest.cc',
632 'syncable/syncable_unittest.cc',
633 'util/cryptographer_unittest.cc',
634 'util/data_encryption_win_unittest.cc',
635 'util/data_type_histogram_unittest.cc',
636 'util/get_session_name_unittest.cc',
637 'util/nigori_unittest.cc',
638 'util/protobuf_unittest.cc',
639 'internal_api/public/util/weak_handle_unittest.cc',
644 # Unit tests for the 'sync_notifier' target. This cannot be a static
645 # library because the unit test files have to be compiled directly
646 # into the executable, so we push the target files to the
647 # depending executable target via direct_dependent_settings.
649 'target_name': 'sync_notifier_tests',
651 # We only want unit test executables to include this target.
652 'suppress_wildcard': 1,
654 '../base/base.gyp:base',
655 '../jingle/jingle.gyp:notifier_test_util',
656 '../net/net.gyp:net_test_support',
657 '../testing/gmock.gyp:gmock',
658 '../testing/gtest.gyp:gtest',
659 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation',
662 'test_support_sync_notifier',
664 # Propagate all dependencies since the actual compilation
665 # happens in the dependents.
666 'export_dependent_settings': [
667 '../base/base.gyp:base',
668 '../jingle/jingle.gyp:notifier_test_util',
669 '../net/net.gyp:net_test_support',
670 '../testing/gmock.gyp:gmock',
671 '../testing/gtest.gyp:gtest',
672 '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation',
675 'test_support_sync_notifier',
677 'direct_dependent_settings': {
682 'notifier/invalidator_factory_unittest.cc',
685 ['OS != "android"', {
687 'notifier/fake_invalidator_unittest.cc',
688 'notifier/invalidation_notifier_unittest.cc',
689 'notifier/invalidator_registrar_unittest.cc',
690 'notifier/non_blocking_invalidator_unittest.cc',
691 'notifier/p2p_invalidator_unittest.cc',
692 'notifier/push_client_channel_unittest.cc',
693 'notifier/registration_manager_unittest.cc',
694 'notifier/sync_invalidation_listener_unittest.cc',
695 'notifier/sync_system_resources_unittest.cc',
703 '../third_party/libjingle/libjingle.gyp:libjingle',
705 'export_dependent_settings': [
706 '../third_party/libjingle/libjingle.gyp:libjingle',
712 # Unit tests for the 'syncapi_core' target. This cannot be a static
713 # library because the unit test files have to be compiled directly
714 # into the executable, so we push the target files to the
715 # depending executable target via direct_dependent_settings.
717 'target_name': 'syncapi_core_tests',
719 # We only want unit test executables to include this target.
720 'suppress_wildcard': 1,
722 '../base/base.gyp:base',
723 '../net/net.gyp:net',
724 '../net/net.gyp:net_test_support',
725 '../testing/gmock.gyp:gmock',
726 '../testing/gtest.gyp:gtest',
727 'protocol/sync_proto.gyp:sync_proto',
731 'test_support_syncapi_core',
733 # Propagate all dependencies since the actual compilation
734 # happens in the dependents.
735 'export_dependent_settings': [
736 '../base/base.gyp:base',
737 '../net/net.gyp:net',
738 '../net/net.gyp:net_test_support',
739 '../testing/gmock.gyp:gmock',
740 '../testing/gtest.gyp:gtest',
741 'protocol/sync_proto.gyp:sync_proto',
745 'test_support_syncapi_core',
747 'direct_dependent_settings': {
752 'internal_api/public/change_record_unittest.cc',
753 'internal_api/debug_info_event_listener_unittest.cc',
754 'internal_api/http_bridge_unittest.cc',
755 'internal_api/js_mutation_event_observer_unittest.cc',
756 'internal_api/js_sync_encryption_handler_observer_unittest.cc',
757 'internal_api/js_sync_manager_observer_unittest.cc',
758 'internal_api/syncapi_server_connection_manager_unittest.cc',
759 'internal_api/sync_encryption_handler_impl_unittest.cc',
760 'internal_api/sync_manager_impl_unittest.cc',
765 # Unit tests for the 'syncapi_service' target. This cannot be a static
766 # library because the unit test files have to be compiled directly
767 # into the executable, so we push the target files to the
768 # depending executable target via direct_dependent_settings.
770 'target_name': 'syncapi_service_tests',
772 # We only want unit test executables to include this target.
773 'suppress_wildcard': 1,
775 '../base/base.gyp:base',
776 '../testing/gtest.gyp:gtest',
777 'protocol/sync_proto.gyp:sync_proto',
780 'test_support_syncapi_service',
782 # Propagate all dependencies since the actual compilation
783 # happens in the dependents.
784 'export_dependent_settings': [
785 '../base/base.gyp:base',
786 '../testing/gtest.gyp:gtest',
787 'protocol/sync_proto.gyp:sync_proto',
790 'test_support_syncapi_service',
792 'direct_dependent_settings': {
797 'api/sync_change_unittest.cc',
798 'api/sync_error_unittest.cc',
803 # The unit test executable for sync tests.
805 'target_name': 'sync_unit_tests',
806 'type': '<(gtest_target_type)',
807 # Typed-parametrized tests generate exit-time destructors.
808 'variables': { 'enable_wexit_time_destructors': 0, },
810 '../base/base.gyp:run_all_unittests',
812 'sync_notifier_tests',
813 'syncapi_core_tests',
814 'syncapi_service_tests',
816 # TODO(akalin): This is needed because histogram.cc uses
817 # leak_annotations.h, which pulls this in. Make 'base'
818 # propagate this dependency.
820 ['OS=="linux" and linux_use_tcmalloc==1', {
822 '../base/allocator/allocator.gyp:allocator',
825 ['OS=="linux" and chromeos==1', {
826 # TODO(kochi): Remove this once we get rid of dependency from
827 # get_session_name.cc.
829 '../chrome/chrome.gyp:browser',
832 ['OS == "android" and gtest_target_type == "shared_library"', {
834 '../testing/android/native_test.gyp:native_test_native_code',
843 # A tool to listen to sync notifications and print them out.
845 'target_name': 'sync_listen_notifications',
846 'type': 'executable',
848 '../base/base.gyp:base',
849 '../jingle/jingle.gyp:notifier',
850 '../net/net.gyp:net',
851 '../net/net.gyp:net_test_support',
856 'tools/sync_listen_notifications.cc',
860 # A standalone command-line sync client.
862 'target_name': 'sync_client',
863 'type': 'executable',
868 '../base/base.gyp:base',
869 '../jingle/jingle.gyp:notifier',
870 '../net/net.gyp:net',
871 '../net/net.gyp:net_test_support',
877 'tools/sync_client.cc',
882 # Special target to wrap a gtest_target_type==shared_library
883 # sync_unit_tests into an android apk for execution.
884 ['OS == "android" and gtest_target_type == "shared_library"', {
887 'target_name': 'sync_unit_tests_apk',
893 'test_suite_name': 'sync_unit_tests',
894 'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)sync_unit_tests<(SHARED_LIB_SUFFIX)',
896 'includes': [ '../build/apk_test.gypi' ],