Have pretty_print.py find histograms.xml.
[chromium-blink-merge.git] / chrome / chrome_common.gypi
blobc2811679ec7cb62cd1f615cc7c1b906c988a66a7
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.
6   'targets': [
7     {
8       'target_name': 'common',
9       'type': 'static_library',
10       'variables': {
11         'chrome_common_target': 1,
12         'enable_wexit_time_destructors': 1,
13       },
14       'include_dirs': [
15           '..',
16           '<(SHARED_INTERMEDIATE_DIR)',  # Needed by chrome_content_client.cc.
17         ],
18       'direct_dependent_settings': {
19         'include_dirs': [
20           '..',
21         ],
22       },
23       'dependencies': [
24         # TODO(gregoryd): chrome_resources and chrome_strings could be
25         #  shared with the 64-bit target, but it does not work due to a gyp
26         # issue.
27         'common_net',
28         'common_version',
29         'installer_util',
30         'metrics_proto',
31         '<(DEPTH)/base/base.gyp:base',
32         '<(DEPTH)/base/base.gyp:base_i18n',
33         '<(DEPTH)/base/base.gyp:base_prefs',
34         '<(DEPTH)/base/base.gyp:base_static',
35         '<(DEPTH)/chrome/chrome_resources.gyp:chrome_resources',
36         '<(DEPTH)/chrome/chrome_resources.gyp:chrome_strings',
37         '<(DEPTH)/chrome/chrome_resources.gyp:theme_resources',
38         '<(DEPTH)/chrome/common_constants.gyp:common_constants',
39         '<(DEPTH)/components/components.gyp:json_schema',
40         '<(DEPTH)/components/components.gyp:policy_component',
41         '<(DEPTH)/components/components.gyp:variations',
42         '<(DEPTH)/content/content.gyp:content_common',
43         '<(DEPTH)/net/net.gyp:net',
44         '<(DEPTH)/skia/skia.gyp:skia',
45         '<(DEPTH)/third_party/icu/icu.gyp:icui18n',
46         '<(DEPTH)/third_party/icu/icu.gyp:icuuc',
47         '<(DEPTH)/third_party/libxml/libxml.gyp:libxml',
48         '<(DEPTH)/third_party/sqlite/sqlite.gyp:sqlite',
49         '<(DEPTH)/third_party/zlib/google/zip.gyp:zip',
50         '<(DEPTH)/ui/resources/ui_resources.gyp:ui_resources',
51         '<(DEPTH)/url/url.gyp:url_lib',
52         '<(DEPTH)/webkit/common/user_agent/webkit_user_agent.gyp:user_agent',
53       ],
54       'sources': [
55         '../apps/app_shim/app_shim_launch.h',
56         '../apps/app_shim/app_shim_messages.h',
57         'common/all_messages.h',
58         'common/attrition_experiments.h',
59         'common/auto_start_linux.cc',
60         'common/auto_start_linux.h',
61         'common/autocomplete_match_type.cc',
62         'common/autocomplete_match_type.h',
63         'common/automation_constants.cc',
64         'common/automation_constants.h',
65         'common/automation_messages.cc',
66         'common/automation_messages.h',
67         'common/automation_messages_internal.h',
68         'common/badge_util.cc',
69         'common/badge_util.h',
70         'common/cancelable_task_tracker.cc',
71         'common/cancelable_task_tracker.h',
72         'common/child_process_logging.h',
73         'common/child_process_logging_win.cc',
74         'common/chrome_content_client.cc',
75         'common/chrome_content_client.h',
76         'common/chrome_content_client_constants.cc',
77         'common/chrome_content_client_ios.mm',
78         'common/chrome_result_codes.h',
79         'common/chrome_utility_messages.h',
80         'common/chrome_version_info.cc',
81         'common/chrome_version_info_android.cc',
82         'common/chrome_version_info_chromeos.cc',
83         'common/chrome_version_info_posix.cc',
84         'common/chrome_version_info_mac.mm',
85         'common/chrome_version_info_win.cc',
86         'common/chrome_version_info.h',
87         'common/cloud_print/cloud_print_class_mac.h',
88         'common/cloud_print/cloud_print_class_mac.mm',
89         'common/cloud_print/cloud_print_constants.cc',
90         'common/cloud_print/cloud_print_constants.h',
91         'common/cloud_print/cloud_print_helpers.cc',
92         'common/cloud_print/cloud_print_helpers.h',
93         'common/cloud_print/cloud_print_proxy_info.cc',
94         'common/cloud_print/cloud_print_proxy_info.h',
95         'common/common_message_generator.cc',
96         'common/common_message_generator.h',
97         'common/common_param_traits.cc',
98         'common/common_param_traits.h',
99         'common/common_param_traits_macros.h',
100         'common/content_restriction.h',
101         'common/content_settings.cc',
102         'common/content_settings.h',
103         'common/content_settings_helper.cc',
104         'common/content_settings_helper.h',
105         'common/content_settings_pattern.cc',
106         'common/content_settings_pattern.h',
107         'common/content_settings_pattern_parser.cc',
108         'common/content_settings_pattern_parser.h',
109         'common/content_settings_types.h',
110         'common/crash_keys.cc',
111         'common/crash_keys.h',
112         'common/custom_handlers/protocol_handler.cc',
113         'common/custom_handlers/protocol_handler.h',
114         'common/descriptors_android.h',
115         'common/encrypted_media_messages_android.h',
116         'common/extensions/api/commands/commands_handler.cc',
117         'common/extensions/api/commands/commands_handler.h',
118         'common/extensions/api/extension_action/action_info.cc',
119         'common/extensions/api/extension_action/action_info.h',
120         'common/extensions/api/extension_action/browser_action_handler.cc',
121         'common/extensions/api/extension_action/browser_action_handler.h',
122         'common/extensions/api/extension_action/page_action_handler.cc',
123         'common/extensions/api/extension_action/page_action_handler.h',
124         'common/extensions/api/extension_action/script_badge_handler.cc',
125         'common/extensions/api/extension_action/script_badge_handler.h',
126         'common/extensions/api/file_browser_handlers/file_browser_handler.cc',
127         'common/extensions/api/file_browser_handlers/file_browser_handler.h',
128         'common/extensions/api/file_handlers/file_handlers_parser.cc',
129         'common/extensions/api/file_handlers/file_handlers_parser.h',
130         'common/extensions/api/i18n/default_locale_handler.cc',
131         'common/extensions/api/i18n/default_locale_handler.h',
132         'common/extensions/api/identity/oauth2_manifest_handler.cc',
133         'common/extensions/api/identity/oauth2_manifest_handler.h',
134         'common/extensions/api/input_ime/input_components_handler.cc',
135         'common/extensions/api/input_ime/input_components_handler.h',
136         'common/extensions/api/managed_mode_private/managed_mode_handler.cc',
137         'common/extensions/api/managed_mode_private/managed_mode_handler.h',
138         'common/extensions/api/media_galleries_private/media_galleries_handler.h',
139         'common/extensions/api/media_galleries_private/media_galleries_handler.cc',
140         'common/extensions/api/messaging/message.h',
141         'common/extensions/api/omnibox/omnibox_handler.cc',
142         'common/extensions/api/omnibox/omnibox_handler.h',
143         'common/extensions/api/plugins/plugins_handler.cc',
144         'common/extensions/api/plugins/plugins_handler.h',
145         'common/extensions/api/sockets/sockets_manifest_handler.cc',
146         'common/extensions/api/sockets/sockets_manifest_handler.h',
147         'common/extensions/api/sockets/sockets_manifest_data.cc',
148         'common/extensions/api/sockets/sockets_manifest_data.h',
149         'common/extensions/api/sockets/sockets_manifest_permission.cc',
150         'common/extensions/api/sockets/sockets_manifest_permission.h',
151         'common/extensions/api/speech/tts_engine_manifest_handler.cc',
152         'common/extensions/api/speech/tts_engine_manifest_handler.h',
153         'common/extensions/api/spellcheck/spellcheck_handler.cc',
154         'common/extensions/api/spellcheck/spellcheck_handler.h',
155         'common/extensions/api/storage/storage_schema_manifest_handler.cc',
156         'common/extensions/api/storage/storage_schema_manifest_handler.h',
157         'common/extensions/api/system_indicator/system_indicator_handler.cc',
158         'common/extensions/api/system_indicator/system_indicator_handler.h',
159         'common/extensions/api/url_handlers/url_handlers_parser.cc',
160         'common/extensions/api/url_handlers/url_handlers_parser.h',
161         'common/extensions/chrome_extensions_client.cc',
162         'common/extensions/chrome_extensions_client.h',
163         'common/extensions/chrome_manifest_handlers.cc',
164         'common/extensions/chrome_manifest_handlers.h',
165         'common/extensions/command.cc',
166         'common/extensions/command.h',
167         'common/extensions/dom_action_types.h',
168         'common/extensions/extension_constants.cc',
169         'common/extensions/extension_constants.h',
170         'common/extensions/extension_file_util.cc',
171         'common/extensions/extension_file_util.h',
172         'common/extensions/extension_icon_set.cc',
173         'common/extensions/extension_icon_set.h',
174         'common/extensions/extension_l10n_util.cc',
175         'common/extensions/extension_l10n_util.h',
176         'common/extensions/extension_messages.cc',
177         'common/extensions/extension_messages.h',
178         'common/extensions/extension_process_policy.cc',
179         'common/extensions/extension_process_policy.h',
180         'common/extensions/features/api_feature.cc',
181         'common/extensions/features/api_feature.h',
182         'common/extensions/features/base_feature_provider.cc',
183         'common/extensions/features/base_feature_provider.h',
184         'common/extensions/features/complex_feature.cc',
185         'common/extensions/features/complex_feature.h',
186         'common/extensions/features/feature_channel.cc',
187         'common/extensions/features/feature_channel.h',
188         'common/extensions/features/manifest_feature.cc',
189         'common/extensions/features/manifest_feature.h',
190         'common/extensions/features/permission_feature.cc',
191         'common/extensions/features/permission_feature.h',
192         'common/extensions/features/simple_feature.cc',
193         'common/extensions/features/simple_feature.h',
194         'common/extensions/manifest_handler_helpers.cc',
195         'common/extensions/manifest_handler_helpers.h',
196         'common/extensions/manifest_handlers/app_isolation_info.cc',
197         'common/extensions/manifest_handlers/app_isolation_info.h',
198         'common/extensions/manifest_handlers/app_launch_info.cc',
199         'common/extensions/manifest_handlers/app_launch_info.h',
200         'common/extensions/manifest_handlers/content_scripts_handler.cc',
201         'common/extensions/manifest_handlers/content_scripts_handler.h',
202         'common/extensions/manifest_handlers/externally_connectable.cc',
203         'common/extensions/manifest_handlers/externally_connectable.h',
204         'common/extensions/manifest_handlers/icons_handler.cc',
205         'common/extensions/manifest_handlers/icons_handler.h',
206         'common/extensions/manifest_handlers/minimum_chrome_version_checker.cc',
207         'common/extensions/manifest_handlers/minimum_chrome_version_checker.h',
208         'common/extensions/manifest_handlers/nacl_modules_handler.cc',
209         'common/extensions/manifest_handlers/nacl_modules_handler.h',
210         'common/extensions/manifest_handlers/settings_overrides_handler.cc',
211         'common/extensions/manifest_handlers/settings_overrides_handler.h',
212         'common/extensions/manifest_handlers/theme_handler.cc',
213         'common/extensions/manifest_handlers/theme_handler.h',
214         'common/extensions/manifest_url_handler.cc',
215         'common/extensions/manifest_url_handler.h',
216         'common/extensions/message_bundle.cc',
217         'common/extensions/message_bundle.h',
218         'common/extensions/mime_types_handler.cc',
219         'common/extensions/mime_types_handler.h',
220         'common/extensions/permissions/bluetooth_permission.cc',
221         'common/extensions/permissions/bluetooth_permission.h',
222         'common/extensions/permissions/bluetooth_permission_data.cc',
223         'common/extensions/permissions/bluetooth_permission_data.h',
224         'common/extensions/permissions/chrome_api_permissions.cc',
225         'common/extensions/permissions/chrome_api_permissions.h',
226         'common/extensions/permissions/chrome_permission_message_provider.cc',
227         'common/extensions/permissions/chrome_permission_message_provider.h',
228         'common/extensions/permissions/media_galleries_permission.cc',
229         'common/extensions/permissions/media_galleries_permission.h',
230         'common/extensions/permissions/media_galleries_permission_data.cc',
231         'common/extensions/permissions/media_galleries_permission_data.h',
232         'common/extensions/permissions/permission_message_util.cc',
233         'common/extensions/permissions/permission_message_util.h',
234         'common/extensions/permissions/set_disjunction_permission.h',
235         'common/extensions/permissions/settings_override_permission.cc',
236         'common/extensions/permissions/settings_override_permission.h',
237         'common/extensions/permissions/socket_permission.cc',
238         'common/extensions/permissions/socket_permission.h',
239         'common/extensions/permissions/socket_permission_data.cc',
240         'common/extensions/permissions/socket_permission_data.h',
241         'common/extensions/permissions/socket_permission_entry.cc',
242         'common/extensions/permissions/socket_permission_entry.h',
243         'common/extensions/permissions/usb_device_permission.cc',
244         'common/extensions/permissions/usb_device_permission.h',
245         'common/extensions/permissions/usb_device_permission_data.cc',
246         'common/extensions/permissions/usb_device_permission_data.h',
247         'common/extensions/sync_helper.cc',
248         'common/extensions/sync_helper.h',
249         'common/extensions/update_manifest.cc',
250         'common/extensions/update_manifest.h',
251         'common/extensions/value_counter.cc',
252         'common/extensions/value_counter.h',
253         'common/extensions/web_accessible_resources_handler.cc',
254         'common/extensions/web_accessible_resources_handler.h',
255         'common/extensions/webview_handler.cc',
256         'common/extensions/webview_handler.h',
257         'common/favicon/favicon_types.cc',
258         'common/favicon/favicon_types.h',
259         'common/favicon/favicon_url_parser.cc',
260         'common/favicon/favicon_url_parser.h',
261         'common/profile_management_switches.cc',
262         'common/profile_management_switches.h',
263         'common/icon_with_badge_image_source.cc',
264         'common/icon_with_badge_image_source.h',
265         'common/importer/firefox_importer_utils.cc',
266         'common/importer/firefox_importer_utils.h',
267         'common/importer/firefox_importer_utils_linux.cc',
268         'common/importer/firefox_importer_utils_mac.mm',
269         'common/importer/firefox_importer_utils_win.cc',
270         'common/importer/ie_importer_test_registry_overrider_win.cc',
271         'common/importer/ie_importer_test_registry_overrider_win.h',
272         'common/importer/ie_importer_utils_win.cc',
273         'common/importer/ie_importer_utils_win.h',
274         'common/importer/imported_bookmark_entry.cc',
275         'common/importer/imported_bookmark_entry.h',
276         'common/importer/imported_favicon_usage.cc',
277         'common/importer/imported_favicon_usage.h',
278         'common/importer/importer_bridge.cc',
279         'common/importer/importer_bridge.h',
280         'common/importer/importer_data_types.cc',
281         'common/importer/importer_data_types.h',
282         'common/importer/importer_type.h',
283         'common/importer/importer_url_row.cc',
284         'common/importer/importer_url_row.h',
285         'common/importer/profile_import_process_messages.cc',
286         'common/importer/profile_import_process_messages.h',
287         'common/importer/safari_importer_utils.h',
288         'common/importer/safari_importer_utils.mm',
289         'common/instant_restricted_id_cache.h',
290         'common/instant_types.cc',
291         'common/instant_types.h',
292         'common/localized_error.cc',
293         'common/localized_error.h',
294         'common/local_discovery/service_discovery_client.cc',
295         'common/local_discovery/service_discovery_client.h',
296         'common/logging_chrome.cc',
297         'common/logging_chrome.h',
298         'common/mac/app_mode_common.h',
299         'common/mac/app_mode_common.mm',
300         'common/mac/cfbundle_blocker.h',
301         'common/mac/cfbundle_blocker.mm',
302         'common/mac/launchd.h',
303         'common/mac/launchd.mm',
304         'common/mac/objc_method_swizzle.h',
305         'common/mac/objc_method_swizzle.mm',
306         'common/mac/objc_zombie.h',
307         'common/mac/objc_zombie.mm',
308         'common/media/webrtc_logging_messages.h',
309         'common/metrics/caching_permuted_entropy_provider.cc',
310         'common/metrics/caching_permuted_entropy_provider.h',
311         'common/metrics/metrics_log_base.cc',
312         'common/metrics/metrics_log_base.h',
313         'common/metrics/metrics_log_manager.cc',
314         'common/metrics/metrics_log_manager.h',
315         'common/metrics/metrics_service_base.cc',
316         'common/metrics/metrics_service_base.h',
317         'common/metrics/variations/experiment_labels.cc',
318         'common/metrics/variations/experiment_labels.h',
319         'common/metrics/variations/uniformity_field_trials.cc',
320         'common/metrics/variations/uniformity_field_trials.h',
321         'common/metrics/variations/variations_util.cc',
322         'common/metrics/variations/variations_util.h',
323         'common/multi_process_lock.h',
324         'common/multi_process_lock_linux.cc',
325         'common/multi_process_lock_mac.cc',
326         'common/multi_process_lock_win.cc',
327         'common/omaha_query_params/omaha_query_params.cc',
328         'common/omaha_query_params/omaha_query_params.h',
329         'common/omnibox_focus_state.h',
330         'common/partial_circular_buffer.cc',
331         'common/partial_circular_buffer.h',
332         'common/pepper_flash.cc',
333         'common/pepper_flash.h',
334         'common/pepper_permission_util.cc',
335         'common/pepper_permission_util.h',
336         'common/pref_names_util.cc',
337         'common/pref_names_util.h',
338         'common/print_messages.cc',
339         'common/print_messages.h',
340         'common/profiling.cc',
341         'common/profiling.h',
342         'common/ref_counted_util.h',
343         'common/render_messages.cc',
344         'common/render_messages.h',
345         'common/safe_browsing/download_protection_util.cc',
346         'common/safe_browsing/download_protection_util.h',
347         'common/safe_browsing/safebrowsing_messages.h',
348         'common/safe_browsing/zip_analyzer.cc',
349         'common/safe_browsing/zip_analyzer.h',
350         'common/search_provider.h',
351         'common/search_types.h',
352         'common/search_urls.cc',
353         'common/search_urls.h',
354         'common/service_messages.h',
355         'common/service_process_util.cc',
356         'common/service_process_util.h',
357         'common/service_process_util_linux.cc',
358         'common/service_process_util_mac.mm',
359         'common/service_process_util_posix.cc',
360         'common/service_process_util_posix.h',
361         'common/service_process_util_win.cc',
362         'common/spellcheck_common.cc',
363         'common/spellcheck_common.h',
364         'common/spellcheck_marker.h',
365         'common/spellcheck_messages.h',
366         'common/spellcheck_result.h',
367         'common/switch_utils.cc',
368         'common/switch_utils.h',
369         'common/thumbnail_score.cc',
370         'common/thumbnail_score.h',
371         'common/translate/language_detection_details.cc',
372         'common/translate/language_detection_details.h',
373         'common/translate/translate_errors.h',
374         'common/tts_messages.h',
375         'common/tts_utterance_request.cc',
376         'common/tts_utterance_request.h',
377         'common/url_constants.cc',
378         'common/url_constants.h',
379         'common/web_application_info.cc',
380         'common/web_application_info.h',
381         'common/worker_thread_ticker.cc',
382         'common/worker_thread_ticker.h',
383       ],
384       'conditions': [
385         ['enable_extensions==1', {
386           'dependencies': [
387             '../device/bluetooth/bluetooth.gyp:device_bluetooth',
388             '../device/usb/usb.gyp:device_usb',
389           ],
390         }, {  # enable_extensions == 0
391           'sources/': [
392             ['exclude', '^common/extensions/api/'],
393             ['include', 'common/extensions/api/extension_action/action_info.cc'],
394             ['include', 'common/extensions/api/extension_action/action_info.h'],
395             ['include', 'common/extensions/api/i18n/default_locale_handler.cc'],
396             ['include', 'common/extensions/api/i18n/default_locale_handler.h'],
397             ['include', 'common/extensions/api/identity/oauth2_manifest_handler.cc'],
398             ['include', 'common/extensions/api/identity/oauth2_manifest_handler.h'],
399             ['include', 'common/extensions/api/managed_mode_private/managed_mode_handler.cc'],
400             ['include', 'common/extensions/api/managed_mode_private/managed_mode_handler.h'],
401             ['include', 'common/extensions/api/plugins/plugins_handler.cc'],
402             ['include', 'common/extensions/api/plugins/plugins_handler.h'],
403             ['include', 'common/extensions/api/storage/storage_schema_manifest_handler.cc'],
404             ['include', 'common/extensions/api/storage/storage_schema_manifest_handler.h'],
405           ],
406         }],
407         ['OS=="win" or OS=="mac"', {
408           'sources': [
409             'common/media_galleries/itunes_library.cc',
410             'common/media_galleries/itunes_library.h',
411             'common/media_galleries/picasa_types.cc',
412             'common/media_galleries/picasa_types.h',
413             'common/media_galleries/pmp_constants.h',
414           ],
415         }],
416         ['OS=="mac"', {
417           'sources': [
418             'common/media_galleries/iphoto_library.cc',
419             'common/media_galleries/iphoto_library.h',
420           ],
421         }],
422         ['OS != "ios"', {
423           'dependencies': [
424             '<(DEPTH)/chrome/common/extensions/api/api.gyp:api',
425             '<(DEPTH)/components/components.gyp:autofill_core_common',
426             '<(DEPTH)/components/components.gyp:autofill_content_common',
427             '<(DEPTH)/components/nacl.gyp:nacl_common',
428             '<(DEPTH)/components/components.gyp:visitedlink_common',
429             '<(DEPTH)/extensions/extensions.gyp:extensions_common',
430             '<(DEPTH)/ipc/ipc.gyp:ipc',
431             '<(DEPTH)/third_party/adobe/flash/flash_player.gyp:flapper_version_h',
432             '<(DEPTH)/third_party/re2/re2.gyp:re2',
433             '<(DEPTH)/third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
434           ],
435         }, {  # OS == ios
436           'sources/': [
437             ['exclude', '^common/child_process_'],
438             ['exclude', '^common/chrome_content_client\\.cc$'],
439             ['exclude', '^common/chrome_version_info_posix\\.cc$'],
440             ['exclude', '^common/common_message_generator\\.cc$'],
441             ['exclude', '^common/common_param_traits'],
442             ['exclude', '^common/custom_handlers/'],
443             ['exclude', '^common/extensions/'],
444             ['exclude', '^common/logging_chrome\\.'],
445             ['exclude', '^common/multi_process_'],
446             ['exclude', '^common/nacl_'],
447             ['exclude', '^common/pepper_flash\\.'],
448             ['exclude', '^common/profiling\\.'],
449             ['exclude', '^common/service_process_util_'],
450             ['exclude', '^common/spellcheck_'],
451             ['exclude', '^common/validation_message_'],
452             ['exclude', '^common/web_apps\\.'],
453             # TODO(ios): Include files here as they are made to work; once
454             # everything is online, remove everything below here and just
455             # use the exclusions above.
456             ['exclude', '\\.(cc|mm)$'],
457             ['include', '_ios\\.(cc|mm)$'],
458             ['include', '(^|/)ios/'],
459             ['include', '^common/chrome_version_info\\.cc$'],
460             ['include', '^common/translate'],
461             ['include', '^common/zip'],
462           ],
463           'include_dirs': [
464             '<(DEPTH)/breakpad/src',
465           ],
466         }],
467         ['enable_printing!=0', {
468           'dependencies': [
469             '<(DEPTH)/printing/printing.gyp:printing',
470           ],
471         }],
472         ['OS!="ios" and chrome_multiple_dll!=1', {
473           'dependencies': [
474             '<(DEPTH)/webkit/glue/webkit_glue.gyp:glue',
475           ],
476         }],
477         ['OS=="android"', {
478           'sources/': [
479             ['exclude', '^common/chrome_version_info_posix.cc'],
480             ['exclude', '^common/service_'],
481           ],
482           'sources!': [
483             'common/badge_util.cc',
484             'common/extensions/api/extension_action/browser_action_handler.cc',
485             'common/extensions/api/extension_action/page_action_handler.cc',
486             'common/extensions/api/spellcheck/spellcheck_handler.cc',
487             'common/extensions/manifest_handlers/minimum_chrome_version_checker.cc',
488             'common/extensions/manifest_handlers/nacl_modules_handler.cc',
489             'common/icon_with_badge_image_source.cc',
490             'common/importer/imported_bookmark_entry.cc',
491             'common/importer/importer_bridge.cc',
492             'common/importer/importer_data_types.cc',
493             'common/importer/importer_url_row.cc',
494             'common/net/url_util.cc',
495             'common/spellcheck_common.cc',
496           ],
497         }],
498         ['OS=="win"', {
499           'include_dirs': [
500             '<(DEPTH)/breakpad/src',
501             '<(DEPTH)/third_party/wtl/include',
502           ],
503         }],
504         ['enable_mdns == 1', {
505             'sources': [
506               'common/local_discovery/local_discovery_messages.h',
507             ]
508         }],
509         ['toolkit_uses_gtk == 1', {
510           'dependencies': [
511             '../build/linux/system.gyp:gtk',
512           ],
513           'export_dependent_settings': [
514             '../third_party/sqlite/sqlite.gyp:sqlite',
515           ],
516           'link_settings': {
517             'libraries': [
518               '-lX11',
519               '-lXrender',
520               '-lXss',
521               '-lXext',
522             ],
523           },
524         }],
525         ['chromeos==1', {
526           'sources!': [
527             'common/chrome_version_info_linux.cc',
528           ],
529         }],
530         ['OS=="mac"', {
531           'dependencies': [
532             '../third_party/google_toolbox_for_mac/google_toolbox_for_mac.gyp:google_toolbox_for_mac',
533             '../third_party/mach_override/mach_override.gyp:mach_override',
534           ],
535           'include_dirs': [
536             '<(DEPTH)/breakpad/src',
537           ],
538           'sources!': [
539             'common/child_process_logging_posix.cc',
540             'common/chrome_version_info_posix.cc',
541           ],
542         }],
543         ['remoting==1', {
544           'dependencies': [
545             '../remoting/remoting.gyp:remoting_client_plugin',
546           ],
547         }],
548         ['enable_automation==0', {
549           'sources/': [
550             ['exclude', '^common/automation_']
551           ]
552         }],
553         ['enable_plugins==0', {
554           'source!' : [
555             'common/pepper_permission_util.cc',
556           ],
557         }],
558         ['use_system_nspr==1', {
559           'dependencies': [
560             '<(DEPTH)/base/third_party/nspr/nspr.gyp:nspr',
561           ],
562         }],
563         ['enable_webrtc==0', {
564           'sources!': [
565             'common/media/webrtc_logging_messages.h',
566           ]
567         }],
568         ['enable_printing==0', {
569           'sources!': [
570             'common/print_messages.cc',
571             'common/print_messages.h',
572           ]
573         }],
574         ['configuration_policy==1', {
575           'dependencies': [
576             '<(DEPTH)/components/components.gyp:policy',
577           ],
578         }],
579       ],
580       'target_conditions': [
581         ['OS == "ios"', {
582           'sources/': [
583             # Pull in specific Mac files for iOS (which have been filtered out
584             # by file name rules).
585             ['include', '^common/chrome_version_info_mac\\.mm$'],
586           ],
587         }],
588       ],
589       'export_dependent_settings': [
590         '../base/base.gyp:base',
591         'metrics_proto',
592       ],
593     },
594     {
595       'target_name': 'common_version',
596       'type': 'none',
597       'conditions': [
598         ['os_posix == 1 and OS != "mac" and OS != "ios"', {
599           'direct_dependent_settings': {
600             'include_dirs': [
601               '<(SHARED_INTERMEDIATE_DIR)',
602             ],
603           },
604           # Because posix_version generates a header, we must set the
605           # hard_dependency flag.
606           'hard_dependency': 1,
607           'actions': [
608             {
609               'action_name': 'posix_version',
610               'variables': {
611                 'lastchange_path':
612                   '<(DEPTH)/build/util/LASTCHANGE',
613                 'version_py_path': 'tools/build/version.py',
614                 'version_path': 'VERSION',
615                 'template_input_path': 'common/chrome_version_info_posix.h.version',
616               },
617               'conditions': [
618                 [ 'branding == "Chrome"', {
619                   'variables': {
620                      'branding_path':
621                        'app/theme/google_chrome/BRANDING',
622                   },
623                 }, { # else branding!="Chrome"
624                   'variables': {
625                      'branding_path':
626                        'app/theme/chromium/BRANDING',
627                   },
628                 }],
629               ],
630               'inputs': [
631                 '<(template_input_path)',
632                 '<(version_path)',
633                 '<(branding_path)',
634                 '<(lastchange_path)',
635               ],
636               'outputs': [
637                 '<(SHARED_INTERMEDIATE_DIR)/chrome/common/chrome_version_info_posix.h',
638               ],
639               'action': [
640                 'python',
641                 '<(version_py_path)',
642                 '-f', '<(version_path)',
643                 '-f', '<(branding_path)',
644                 '-f', '<(lastchange_path)',
645                 '<(template_input_path)',
646                 '<@(_outputs)',
647               ],
648               'message': 'Generating version information',
649             },
650           ],
651         }],
652       ],
653     },
654     {
655       'target_name': 'common_net',
656       'type': 'static_library',
657       'sources': [
658         'common/net/net_error_info.cc',
659         'common/net/net_error_info.h',
660         'common/net/net_resource_provider.cc',
661         'common/net/net_resource_provider.h',
662         'common/net/predictor_common.h',
663         'common/net/url_fixer_upper.cc',
664         'common/net/url_fixer_upper.h',
665         'common/net/url_util.cc',
666         'common/net/url_util.h',
667         'common/net/x509_certificate_model.cc',
668         'common/net/x509_certificate_model_nss.cc',
669         'common/net/x509_certificate_model_openssl.cc',
670         'common/net/x509_certificate_model.h',
671       ],
672       'dependencies': [
673         '<(DEPTH)/base/base.gyp:base',
674         '<(DEPTH)/chrome/chrome_resources.gyp:chrome_resources',
675         '<(DEPTH)/chrome/chrome_resources.gyp:chrome_strings',
676         '<(DEPTH)/crypto/crypto.gyp:crypto',
677         '<(DEPTH)/net/net.gyp:net_resources',
678         '<(DEPTH)/net/net.gyp:net',
679         '<(DEPTH)/third_party/icu/icu.gyp:icui18n',
680         '<(DEPTH)/third_party/icu/icu.gyp:icuuc',
681       ],
682       'conditions': [
683         ['OS != "ios"', {
684           'dependencies': [
685             '<(DEPTH)/gpu/gpu.gyp:gpu_ipc',
686           ],
687         }, {  # OS == ios
688           'sources!': [
689             'common/net/net_resource_provider.cc',
690             'common/net/x509_certificate_model.cc',
691           ],
692         }],
693         ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', {
694             'dependencies': [
695               '../build/linux/system.gyp:ssl',
696             ],
697           },
698         ],
699         ['os_posix != 1 or OS == "mac" or OS == "ios"', {
700             'sources!': [
701               'common/net/x509_certificate_model_nss.cc',
702               'common/net/x509_certificate_model_openssl.cc',
703             ],
704           },
705         ],
706         ['OS == "android"', {
707             'dependencies': [
708               '../third_party/openssl/openssl.gyp:openssl',
709             ],
710           },
711         ],
712         ['use_openssl==1', {
713             'sources!': [
714               'common/net/x509_certificate_model_nss.cc',
715             ],
716           },
717           {  # else !use_openssl: remove the unneeded files
718             'sources!': [
719               'common/net/x509_certificate_model_openssl.cc',
720             ],
721           },
722         ],
723         ['OS=="win"', {
724             # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
725             'msvs_disabled_warnings': [4267, ],
726           },
727         ],
728       ],
729     },
730     {
731       # Protobuf compiler / generator for the safebrowsing client
732       # model proto and the client-side detection (csd) request
733       # protocol buffer.
734       'target_name': 'safe_browsing_proto',
735       'type': 'static_library',
736       'sources': [
737         'common/safe_browsing/client_model.proto',
738         'common/safe_browsing/crx_info.proto',
739         'common/safe_browsing/csd.proto'
740       ],
741       'variables': {
742         'proto_in_dir': 'common/safe_browsing',
743         'proto_out_dir': 'chrome/common/safe_browsing',
744       },
745       'includes': [ '../build/protoc.gypi' ],
746     },
747     {
748       # Protobuf compiler / generator for UMA (User Metrics Analysis).
749       'target_name': 'metrics_proto',
750       'type': 'static_library',
751       'sources': [
752         'common/metrics/proto/chrome_experiments.proto',
753         'common/metrics/proto/chrome_user_metrics_extension.proto',
754         'common/metrics/proto/histogram_event.proto',
755         'common/metrics/proto/omnibox_event.proto',
756         'common/metrics/proto/perf_data.proto',
757         'common/metrics/proto/permuted_entropy_cache.proto',
758         'common/metrics/proto/profiler_event.proto',
759         'common/metrics/proto/system_profile.proto',
760         'common/metrics/proto/user_action_event.proto',
761       ],
762       'variables': {
763         'proto_in_dir': 'common/metrics/proto',
764         'proto_out_dir': 'chrome/common/metrics/proto',
765       },
766       'includes': [ '../build/protoc.gypi' ],
767     },
768   ],