Skip managed bookmarks at the BookmarkChangeProcessor.
[chromium-blink-merge.git] / sync / sync.gyp
blob86460138f22330bd8aca3e339e14fce7065d16e8
1 # Copyright 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.
6   'variables': {
7     'chromium_code': 1,
8   },
10   'includes': [
11     'sync_android.gypi',
12     'sync_tests.gypi',
13   ],
15   'targets': [
16     # This target will add '-lsync_core' and '-lsync_proto' to the link line of
17     # targets that depend on it.  Anything that depends on sync code should
18     # declare a dependency on this target.
19     {
20       'target_name': 'sync',
21       'type': 'none',
22       'dependencies': [
23         'sync_core',
24         'sync_proto',
25       ],
26       'export_dependent_settings': [
27         'sync_proto',
28       ],
29     },
31     # Contains everything related to sync implementation that does not depend
32     # on chrome/ or components/.  Do not depend on this directly.  Depend on
33     # the 'sync' target to get the sync protobufs, too.
34     {
35       'target_name': 'sync_core',
36       'type': '<(component)',
37       'variables': { 'enable_wexit_time_desctructors': 1, },
38       'defines': [
39         'SYNC_IMPLEMENTATION',
40       ],
41       'include_dirs': [
42         '..',
43       ],
44       'dependencies': [
45         '../base/base.gyp:base',
46         '../base/base.gyp:base_i18n',
47         '../crypto/crypto.gyp:crypto',
48         '../google_apis/google_apis.gyp:google_apis',
49         '../net/net.gyp:net',
50         '../sql/sql.gyp:sql',
51         '../third_party/protobuf/protobuf.gyp:protobuf_lite',
52         '../third_party/zlib/zlib.gyp:zlib',
53         '../url/url.gyp:url_lib',
54         'sync_proto',
55       ],
56       'export_dependent_settings': [
57         'sync_proto',
58       ],
59       'sources': [
60         'api/attachments/attachment.cc',
61         'api/attachments/attachment.h',
62         'api/attachments/attachment_id.cc',
63         'api/attachments/attachment_id.h',
64         'api/attachments/attachment_store.cc',
65         'api/attachments/attachment_store.h',
66         'api/attachments/fake_attachment_store.cc',
67         'api/attachments/fake_attachment_store.h',
68         'api/string_ordinal.h',
69         'api/sync_change.cc',
70         'api/sync_change.h',
71         'api/sync_change_processor.cc',
72         'api/sync_change_processor.h',
73         'api/sync_data.cc',
74         'api/sync_data.h',
75         'api/sync_error.cc',
76         'api/sync_error.h',
77         'api/sync_error_factory.cc',
78         'api/sync_error_factory.h',
79         'api/sync_merge_result.cc',
80         'api/sync_merge_result.h',
81         'api/syncable_service.cc',
82         'api/syncable_service.h',
83         'api/time.h',
84         'base/sync_export.h',
85         'engine/all_status.cc',
86         'engine/all_status.h',
87         'engine/apply_control_data_updates.cc',
88         'engine/apply_control_data_updates.h',
89         'engine/backoff_delay_provider.cc',
90         'engine/backoff_delay_provider.h',
91         'engine/commit.cc',
92         'engine/commit.h',
93         'engine/commit_contribution.cc',
94         'engine/commit_contribution.h',
95         'engine/commit_contributor.cc',
96         'engine/commit_contributor.h',
97         'engine/commit_processor.cc',
98         'engine/commit_processor.h',
99         'engine/commit_util.cc',
100         'engine/commit_util.h',
101         'engine/conflict_resolver.cc',
102         'engine/conflict_resolver.h',
103         'engine/conflict_util.cc',
104         'engine/conflict_util.h',
105         'engine/directory_commit_contribution.cc',
106         'engine/directory_commit_contribution.h',
107         'engine/directory_commit_contributor.cc',
108         'engine/directory_commit_contributor.h',
109         'engine/directory_update_handler.cc',
110         'engine/directory_update_handler.h',
111         'engine/entity_tracker.cc',
112         'engine/entity_tracker.h',
113         'engine/get_commit_ids.cc',
114         'engine/get_commit_ids.h',
115         'engine/get_updates_delegate.cc',
116         'engine/get_updates_delegate.h',
117         'engine/get_updates_processor.cc',
118         'engine/get_updates_processor.h',
119         'engine/model_type_entity.cc',
120         'engine/model_type_entity.h',
121         'engine/model_type_sync_proxy.cc',
122         'engine/model_type_sync_proxy.h',
123         'engine/model_type_sync_proxy_impl.cc',
124         'engine/model_type_sync_proxy_impl.h',
125         'engine/model_type_sync_worker.cc',
126         'engine/model_type_sync_worker.h',
127         'engine/model_type_sync_worker_impl.cc',
128         'engine/model_type_sync_worker_impl.h',
129         'engine/net/server_connection_manager.cc',
130         'engine/net/server_connection_manager.h',
131         'engine/net/url_translator.cc',
132         'engine/net/url_translator.h',
133         'engine/non_blocking_type_commit_contribution.cc',
134         'engine/non_blocking_type_commit_contribution.h',
135         'engine/nudge_handler.cc',
136         'engine/nudge_handler.h',
137         'engine/nudge_source.cc',
138         'engine/nudge_source.h',
139         'engine/process_updates_util.cc',
140         'engine/process_updates_util.h',
141         'engine/sync_cycle_event.cc',
142         'engine/sync_cycle_event.h',
143         'engine/sync_engine_event_listener.cc',
144         'engine/sync_engine_event_listener.h',
145         'engine/sync_scheduler.cc',
146         'engine/sync_scheduler.h',
147         'engine/sync_scheduler_impl.cc',
148         'engine/sync_scheduler_impl.h',
149         'engine/syncer.cc',
150         'engine/syncer.h',
151         'engine/syncer_proto_util.cc',
152         'engine/syncer_proto_util.h',
153         'engine/syncer_types.h',
154         'engine/syncer_util.cc',
155         'engine/syncer_util.h',
156         'engine/traffic_logger.cc',
157         'engine/traffic_logger.h',
158         'engine/update_applicator.cc',
159         'engine/update_applicator.h',
160         'engine/update_handler.cc',
161         'engine/update_handler.h',
162         'internal_api/attachments/attachment_downloader.cc',
163         'internal_api/attachments/attachment_downloader_impl.cc',
164         'internal_api/attachments/attachment_service.cc',
165         'internal_api/attachments/attachment_service_impl.cc',
166         'internal_api/attachments/attachment_service_proxy.cc',
167         'internal_api/attachments/attachment_service_proxy_for_test.cc',
168         'internal_api/attachments/attachment_uploader.cc',
169         'internal_api/attachments/attachment_uploader_impl.cc',
170         'internal_api/attachments/fake_attachment_downloader.cc',
171         'internal_api/attachments/fake_attachment_uploader.cc',
172         'internal_api/base_node.cc',
173         'internal_api/base_transaction.cc',
174         'internal_api/change_record.cc',
175         'internal_api/change_reorder_buffer.cc',
176         'internal_api/change_reorder_buffer.h',
177         'internal_api/debug_info_event_listener.cc',
178         'internal_api/debug_info_event_listener.h',
179         'internal_api/delete_journal.cc',
180         'internal_api/events/commit_request_event.cc',
181         'internal_api/events/commit_response_event.cc',
182         'internal_api/events/configure_get_updates_request_event.cc',
183         'internal_api/events/get_updates_response_event.cc',
184         'internal_api/events/normal_get_updates_request_event.cc',
185         'internal_api/events/poll_get_updates_request_event.cc',
186         'internal_api/events/protocol_event.cc',
187         'internal_api/http_bridge.cc',
188         'internal_api/http_bridge_network_resources.cc',
189         'internal_api/internal_components_factory_impl.cc',
190         'internal_api/js_mutation_event_observer.cc',
191         'internal_api/js_mutation_event_observer.h',
192         'internal_api/js_sync_encryption_handler_observer.cc',
193         'internal_api/js_sync_encryption_handler_observer.h',
194         'internal_api/js_sync_manager_observer.cc',
195         'internal_api/js_sync_manager_observer.h',
196         'internal_api/protocol_event_buffer.cc',
197         'internal_api/protocol_event_buffer.h',
198         'internal_api/attachments/public/attachment_downloader.h',
199         'internal_api/attachments/public/attachment_service.h',
200         'internal_api/attachments/public/attachment_service_impl.h',
201         'internal_api/attachments/public/attachment_service_proxy_for_test.h',
202         'internal_api/attachments/public/attachment_service_proxy.h',
203         'internal_api/attachments/public/attachment_uploader.h',
204         'internal_api/public/attachments/attachment_downloader_impl.h',
205         'internal_api/public/attachments/attachment_uploader_impl.h',
206         'internal_api/public/attachments/fake_attachment_downloader.h',
207         'internal_api/public/attachments/fake_attachment_uploader.h',
208         'internal_api/public/base/attachment_id_proto.cc',
209         'internal_api/public/base/attachment_id_proto.h',
210         'internal_api/public/base/cancelation_observer.cc',
211         'internal_api/public/base/cancelation_observer.h',
212         'internal_api/public/base/cancelation_signal.cc',
213         'internal_api/public/base/cancelation_signal.h',
214         'internal_api/public/base/enum_set.h',
215         'internal_api/public/base/enum_set.h',
216         'internal_api/public/base/invalidation_interface.cc',
217         'internal_api/public/base/invalidation_interface.h',
218         'internal_api/public/base/model_type.h',
219         'internal_api/public/base/node_ordinal.cc',
220         'internal_api/public/base/node_ordinal.h',
221         'internal_api/public/base/ordinal.h',
222         'internal_api/public/base/progress_marker_map.cc',
223         'internal_api/public/base/progress_marker_map.h',
224         'internal_api/public/base/unique_position.cc',
225         'internal_api/public/base/unique_position.h',
226         'internal_api/public/base_node.h',
227         'internal_api/public/base_transaction.h',
228         'internal_api/public/change_record.h',
229         'internal_api/public/configure_reason.h',
230         'internal_api/public/data_type_association_stats.cc',
231         'internal_api/public/data_type_association_stats.h',
232         'internal_api/public/data_type_debug_info_listener.cc',
233         'internal_api/public/data_type_debug_info_listener.h',
234         'internal_api/public/delete_journal.h',
235         'internal_api/public/engine/model_safe_worker.cc',
236         'internal_api/public/engine/model_safe_worker.h',
237         'internal_api/public/engine/passive_model_worker.cc',
238         'internal_api/public/engine/passive_model_worker.h',
239         'internal_api/public/engine/polling_constants.cc',
240         'internal_api/public/engine/polling_constants.h',
241         'internal_api/public/engine/sync_status.cc',
242         'internal_api/public/engine/sync_status.h',
243         'internal_api/public/events/commit_request_event.h',
244         'internal_api/public/events/commit_response_event.h',
245         'internal_api/public/events/configure_get_updates_request_event.h',
246         'internal_api/public/events/get_updates_response_event.h',
247         'internal_api/public/events/normal_get_updates_request_event.h',
248         'internal_api/public/events/poll_get_updates_request_event.h',
249         'internal_api/public/events/protocol_event.h',
250         'internal_api/public/http_bridge.h',
251         'internal_api/public/http_bridge_network_resources.h',
252         'internal_api/public/http_post_provider_factory.h',
253         'internal_api/public/http_post_provider_interface.h',
254         'internal_api/public/internal_components_factory.h',
255         'internal_api/public/internal_components_factory_impl.h',
256         'internal_api/public/network_resources.h',
257         'internal_api/public/non_blocking_sync_common.cc',
258         'internal_api/public/non_blocking_sync_common.h',
259         'internal_api/public/read_node.h',
260         'internal_api/public/read_transaction.h',
261         'internal_api/public/shutdown_reason.h',
262         'internal_api/public/sessions/commit_counters.cc',
263         'internal_api/public/sessions/commit_counters.h',
264         'internal_api/public/sessions/model_neutral_state.cc',
265         'internal_api/public/sessions/model_neutral_state.h',
266         'internal_api/public/sessions/status_counters.cc',
267         'internal_api/public/sessions/status_counters.h',
268         'internal_api/public/sessions/sync_session_snapshot.cc',
269         'internal_api/public/sessions/sync_session_snapshot.h',
270         'internal_api/public/sessions/type_debug_info_observer.cc',
271         'internal_api/public/sessions/type_debug_info_observer.h',
272         'internal_api/public/sessions/update_counters.cc',
273         'internal_api/public/sessions/update_counters.h',
274         'internal_api/public/sync_auth_provider.h',
275         'internal_api/public/sync_context.h',
276         'internal_api/public/sync_context_proxy.h',
277         'internal_api/public/sync_encryption_handler.cc',
278         'internal_api/public/sync_encryption_handler.h',
279         'internal_api/public/sync_manager.cc',
280         'internal_api/public/sync_manager.h',
281         'internal_api/public/sync_manager_factory.h',
282         'internal_api/public/user_share.h',
283         'internal_api/public/util/experiments.h',
284         'internal_api/public/util/immutable.h',
285         'internal_api/public/util/report_unrecoverable_error_function.h',
286         'internal_api/public/util/sync_db_util.h',
287         'internal_api/public/util/sync_string_conversions.cc',
288         'internal_api/public/util/sync_string_conversions.h',
289         'internal_api/public/util/syncer_error.cc',
290         'internal_api/public/util/syncer_error.h',
291         'internal_api/public/util/unrecoverable_error_handler.h',
292         'internal_api/public/util/unrecoverable_error_info.cc',
293         'internal_api/public/util/unrecoverable_error_info.h',
294         'internal_api/public/util/weak_handle.cc',
295         'internal_api/public/util/weak_handle.h',
296         'internal_api/public/write_node.h',
297         'internal_api/public/write_transaction.h',
298         'internal_api/read_node.cc',
299         'internal_api/read_transaction.cc',
300         'internal_api/sync_backup_manager.cc',
301         'internal_api/sync_backup_manager.h',
302         'internal_api/sync_context.cc',
303         'internal_api/sync_context_proxy.cc',
304         'internal_api/sync_context_proxy_impl.cc',
305         'internal_api/sync_context_proxy_impl.h',
306         'internal_api/sync_db_util.cc',
307         'internal_api/sync_encryption_handler_impl.cc',
308         'internal_api/sync_encryption_handler_impl.h',
309         'internal_api/sync_manager_factory.cc',
310         'internal_api/sync_manager_impl.cc',
311         'internal_api/sync_manager_impl.h',
312         'internal_api/sync_rollback_manager.cc',
313         'internal_api/sync_rollback_manager.h',
314         'internal_api/sync_rollback_manager_base.cc',
315         'internal_api/sync_rollback_manager_base.h',
316         'internal_api/syncapi_internal.cc',
317         'internal_api/syncapi_internal.h',
318         'internal_api/syncapi_server_connection_manager.cc',
319         'internal_api/syncapi_server_connection_manager.h',
320         'internal_api/user_share.cc',
321         'internal_api/write_node.cc',
322         'internal_api/write_transaction.cc',
323         'js/js_backend.h',
324         'js/js_controller.h',
325         'js/js_event_details.cc',
326         'js/js_event_details.h',
327         'js/js_event_handler.h',
328         'js/sync_js_controller.cc',
329         'js/sync_js_controller.h',
330         'protocol/proto_enum_conversions.cc',
331         'protocol/proto_enum_conversions.h',
332         'protocol/proto_value_conversions.cc',
333         'protocol/proto_value_conversions.h',
334         'protocol/sync_protocol_error.cc',
335         'protocol/sync_protocol_error.h',
336         'sessions/data_type_tracker.cc',
337         'sessions/data_type_tracker.h',
338         'sessions/debug_info_getter.h',
339         'sessions/directory_type_debug_info_emitter.cc',
340         'sessions/directory_type_debug_info_emitter.h',
341         'sessions/model_type_registry.cc',
342         'sessions/model_type_registry.h',
343         'sessions/nudge_tracker.cc',
344         'sessions/nudge_tracker.h',
345         'sessions/status_controller.cc',
346         'sessions/status_controller.h',
347         'sessions/sync_session.cc',
348         'sessions/sync_session.h',
349         'sessions/sync_session_context.cc',
350         'sessions/sync_session_context.h',
351         'syncable/blob.h',
352         'syncable/deferred_on_disk_directory_backing_store.cc',
353         'syncable/deferred_on_disk_directory_backing_store.h',
354         'syncable/dir_open_result.h',
355         'syncable/directory.cc',
356         'syncable/directory.h',
357         'syncable/directory_backing_store.cc',
358         'syncable/directory_backing_store.h',
359         'syncable/directory_change_delegate.h',
360         'syncable/entry.cc',
361         'syncable/entry.h',
362         'syncable/entry_kernel.cc',
363         'syncable/entry_kernel.h',
364         'syncable/in_memory_directory_backing_store.cc',
365         'syncable/in_memory_directory_backing_store.h',
366         'syncable/invalid_directory_backing_store.cc',
367         'syncable/invalid_directory_backing_store.h',
368         'syncable/metahandle_set.h',
369         'syncable/model_neutral_mutable_entry.cc',
370         'syncable/model_neutral_mutable_entry.h',
371         'syncable/model_type.cc',
372         'syncable/mutable_entry.cc',
373         'syncable/mutable_entry.h',
374         'syncable/nigori_handler.cc',
375         'syncable/nigori_handler.h',
376         'syncable/nigori_util.cc',
377         'syncable/nigori_util.h',
378         'syncable/on_disk_directory_backing_store.cc',
379         'syncable/on_disk_directory_backing_store.h',
380         'syncable/parent_child_index.cc',
381         'syncable/parent_child_index.h',
382         'syncable/scoped_kernel_lock.cc',
383         'syncable/scoped_kernel_lock.h',
384         'syncable/scoped_parent_child_index_updater.cc',
385         'syncable/scoped_parent_child_index_updater.h',
386         'syncable/syncable-inl.h',
387         'syncable/syncable_base_transaction.cc',
388         'syncable/syncable_base_transaction.h',
389         'syncable/syncable_base_write_transaction.cc',
390         'syncable/syncable_base_write_transaction.h',
391         'syncable/syncable_changes_version.h',
392         'syncable/syncable_columns.h',
393         'syncable/syncable_delete_journal.cc',
394         'syncable/syncable_delete_journal.h',
395         'syncable/syncable_enum_conversions.cc',
396         'syncable/syncable_enum_conversions.h',
397         'syncable/syncable_id.cc',
398         'syncable/syncable_id.h',
399         'syncable/syncable_model_neutral_write_transaction.cc',
400         'syncable/syncable_model_neutral_write_transaction.h',
401         'syncable/syncable_proto_util.cc',
402         'syncable/syncable_proto_util.h',
403         'syncable/syncable_read_transaction.cc',
404         'syncable/syncable_read_transaction.h',
405         'syncable/syncable_util.cc',
406         'syncable/syncable_util.h',
407         'syncable/syncable_write_transaction.cc',
408         'syncable/syncable_write_transaction.h',
409         'syncable/transaction_observer.h',
410         'syncable/write_transaction_info.cc',
411         'syncable/write_transaction_info.h',
412         'util/cryptographer.cc',
413         'util/cryptographer.h',
414         'util/data_type_histogram.h',
415         'util/encryptor.h',
416         'util/extensions_activity.cc',
417         'util/extensions_activity.h',
418         'util/get_session_name.cc',
419         'util/get_session_name.h',
420         'util/get_session_name_ios.h',
421         'util/get_session_name_ios.mm',
422         'util/get_session_name_linux.cc',
423         'util/get_session_name_linux.h',
424         'util/get_session_name_mac.h',
425         'util/get_session_name_mac.mm',
426         'util/get_session_name_win.cc',
427         'util/get_session_name_win.h',
428         'util/logging.cc',
429         'util/logging.h',
430         'util/nigori.cc',
431         'util/nigori.h',
432         'util/time.cc',
433         'util/time.h',
434       ],
436       'conditions': [
437         ['OS=="linux" and chromeos==1', {
438           # Required by get_session_name.cc on Chrome OS.
439           'dependencies': [
440             '../chromeos/chromeos.gyp:chromeos',
441             ],
442         }],
443       ],
444     },
445     {
446       # Contains sync protobuf definitions.  Do not depend on this directly.
447       # Depend on the 'sync' target to get the relevant C++ code, too.
448       #
449       # GN version: //sync/protocol
450       'target_name': 'sync_proto',
451       'type': '<(component)',
452       'include_dirs': [
453         '..',
454       ],
455       'defines': [
456         'SYNC_PROTO_IMPLEMENTATION',
457       ],
458       'sources': [
459         # NOTE: If you add a file to this list, also add it to
460         # sync/protocol/BUILD.gn
461         'protocol/app_notification_specifics.proto',
462         'protocol/app_setting_specifics.proto',
463         'protocol/app_specifics.proto',
464         'protocol/app_list_specifics.proto',
465         'protocol/article_specifics.proto',
466         'protocol/attachments.proto',
467         'protocol/autofill_specifics.proto',
468         'protocol/bookmark_specifics.proto',
469         'protocol/client_commands.proto',
470         'protocol/client_debug_info.proto',
471         'protocol/device_info_specifics.proto',
472         'protocol/dictionary_specifics.proto',
473         'protocol/encryption.proto',
474         'protocol/experiments_specifics.proto',
475         'protocol/extension_setting_specifics.proto',
476         'protocol/extension_specifics.proto',
477         'protocol/favicon_image_specifics.proto',
478         'protocol/favicon_tracking_specifics.proto',
479         'protocol/get_updates_caller_info.proto',
480         'protocol/history_delete_directive_specifics.proto',
481         'protocol/nigori_specifics.proto',
482         'protocol/managed_user_setting_specifics.proto',
483         'protocol/managed_user_shared_setting_specifics.proto',
484         'protocol/managed_user_specifics.proto',
485         'protocol/password_specifics.proto',
486         'protocol/preference_specifics.proto',
487         'protocol/priority_preference_specifics.proto',
488         'protocol/search_engine_specifics.proto',
489         'protocol/session_specifics.proto',
490         'protocol/sync.proto',
491         'protocol/sync_enums.proto',
492         'protocol/synced_notification_app_info_specifics.proto',
493         'protocol/synced_notification_data.proto',
494         'protocol/synced_notification_render.proto',
495         'protocol/synced_notification_specifics.proto',
496         'protocol/test.proto',
497         'protocol/theme_specifics.proto',
498         'protocol/typed_url_specifics.proto',
499         'protocol/unique_position.proto',
500       ],
501       'variables': {
502         'enable_wexit_time_desctructors': 1,
503         'proto_in_dir': './protocol',
504         'proto_out_dir': 'sync/protocol',
505         'cc_generator_options': 'dllexport_decl=SYNC_PROTO_EXPORT:',
506         'cc_include': 'sync/protocol/sync_proto_export.h',
507       },
508       'includes': [
509         '../build/protoc.gypi'
510       ],
511     },
512   ],