Implement disable-app-list-dismiss-on-blur for ChromeOS.
[chromium-blink-merge.git] / remoting / remoting_host.gypi
blob60e0c381c12c48fa220a229693d976e6cbf1483e
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.
6   'includes': [
7     'remoting_host_linux.gypi',
8     'remoting_host_mac.gypi',
9     'remoting_host_win.gypi',
10   ],
12   'variables': {
13     'conditions': [
14       # Remoting host is supported only on Windows, OSX and Linux (with X11).
15       ['OS=="win" or OS=="mac" or (OS=="linux" and use_x11==1)', {
16         'enable_me2me_host': 1,
17         'enable_it2me_host': 1,
18         'enable_remoting_host': 1,
19       }, {
20         'enable_me2me_host': 0,
21         'enable_it2me_host': 0,
22         'enable_remoting_host': 0,
23       }],
24       ['chromeos==1 and use_x11==1', {
25         'enable_me2me_host': 0,
26         'enable_it2me_host': 1,
27       }],
28     ],
29   },
31   'conditions': [
32     ['enable_remoting_host==1', {
33       'targets': [
34         {
35           'target_name': 'remoting_host',
36           'type': 'static_library',
37           'variables': {
38             'enable_wexit_time_destructors': 1,
39             'host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
40             'prefpane_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_PREFPANE_BUNDLE_NAME@")',
41           },
42           'dependencies': [
43             'remoting_base',
44             'remoting_protocol',
45             'remoting_resources',
46             '../base/base.gyp:base_i18n',
47             '../crypto/crypto.gyp:crypto',
48             '../google_apis/google_apis.gyp:google_apis',
49             '../ipc/ipc.gyp:ipc',
50             '../ui/events/events.gyp:dom4_keycode_converter',
51           ],
52           'defines': [
53             'HOST_BUNDLE_NAME="<(host_bundle_name)"',
54             'PREFPANE_BUNDLE_NAME="<(prefpane_bundle_name)"',
55             'VERSION=<(version_full)',
56           ],
57           'sources': [
58             'host/audio_capturer.cc',
59             'host/audio_capturer.h',
60             'host/audio_capturer_linux.cc',
61             'host/audio_capturer_linux.h',
62             'host/audio_capturer_mac.cc',
63             'host/audio_capturer_win.cc',
64             'host/audio_capturer_win.h',
65             'host/audio_scheduler.cc',
66             'host/audio_scheduler.h',
67             'host/audio_silence_detector.cc',
68             'host/audio_silence_detector.h',
69             'host/basic_desktop_environment.cc',
70             'host/basic_desktop_environment.h',
71             'host/branding.cc',
72             'host/branding.h',
73             'host/capture_scheduler.cc',
74             'host/capture_scheduler.h',
75             'host/chromeos/aura_desktop_capturer.cc',
76             'host/chromeos/aura_desktop_capturer.h',
77             'host/chromeos/message_box.cc',
78             'host/chromeos/message_box.h',
79             'host/chromium_port_allocator_factory.cc',
80             'host/chromium_port_allocator_factory.h',
81             'host/chromoting_host.cc',
82             'host/chromoting_host.h',
83             'host/chromoting_host_context.cc',
84             'host/chromoting_host_context.h',
85             'host/chromoting_messages.cc',
86             'host/chromoting_messages.h',
87             'host/chromoting_param_traits.cc',
88             'host/chromoting_param_traits.h',
89             'host/client_session.cc',
90             'host/client_session.h',
91             'host/client_session_control.h',
92             'host/clipboard.h',
93             'host/clipboard_aura.cc',
94             'host/clipboard_aura.h',
95             'host/clipboard_mac.mm',
96             'host/clipboard_win.cc',
97             'host/clipboard_x11.cc',
98             'host/config_file_watcher.cc',
99             'host/config_file_watcher.h',
100             'host/config_watcher.h',
101             'host/constants_mac.cc',
102             'host/constants_mac.h',
103             'host/continue_window.cc',
104             'host/continue_window.h',
105             'host/continue_window_chromeos.cc',
106             'host/continue_window_linux.cc',
107             'host/continue_window_mac.mm',
108             'host/continue_window_win.cc',
109             'host/daemon_process.cc',
110             'host/daemon_process.h',
111             'host/daemon_process_win.cc',
112             'host/desktop_environment.h',
113             'host/desktop_process.cc',
114             'host/desktop_process.h',
115             'host/desktop_resizer.h',
116             'host/desktop_resizer_linux.cc',
117             'host/desktop_session.cc',
118             'host/desktop_session.h',
119             'host/desktop_session_agent.cc',
120             'host/desktop_session_agent.h',
121             'host/desktop_session_win.cc',
122             'host/desktop_session_win.h',
123             'host/desktop_resizer_mac.cc',
124             'host/desktop_resizer_win.cc',
125             'host/desktop_session_connector.h',
126             'host/desktop_session_proxy.cc',
127             'host/desktop_session_proxy.h',
128             'host/desktop_shape_tracker.h',
129             'host/desktop_shape_tracker_mac.cc',
130             'host/desktop_shape_tracker_win.cc',
131             'host/desktop_shape_tracker_x11.cc',
132             'host/disconnect_window_chromeos.cc',
133             'host/disconnect_window_linux.cc',
134             'host/disconnect_window_mac.h',
135             'host/disconnect_window_mac.mm',
136             'host/disconnect_window_win.cc',
137             'host/dns_blackhole_checker.cc',
138             'host/dns_blackhole_checker.h',
139             'host/gnubby_auth_handler.h',
140             'host/gnubby_auth_handler_posix.cc',
141             'host/gnubby_auth_handler_posix.h',
142             'host/gnubby_auth_handler_win.cc',
143             'host/gnubby_socket.cc',
144             'host/gnubby_socket.h',
145             'host/heartbeat_sender.cc',
146             'host/heartbeat_sender.h',
147             'host/host_change_notification_listener.cc',
148             'host/host_change_notification_listener.h',
149             'host/host_config.cc',
150             'host/host_config.h',
151             'host/host_event_logger.h',
152             'host/host_event_logger_posix.cc',
153             'host/host_event_logger_win.cc',
154             'host/host_exit_codes.cc',
155             'host/host_exit_codes.h',
156             'host/host_export.h',
157             'host/host_extension.h',
158             'host/host_extension_session.cc',
159             'host/host_extension_session.h',
160             'host/host_extension_session_manager.cc',
161             'host/host_extension_session_manager.h',
162             'host/host_secret.cc',
163             'host/host_secret.h',
164             'host/host_status_logger.cc',
165             'host/host_status_logger.h',
166             'host/host_status_monitor.h',
167             'host/host_status_observer.h',
168             'host/host_status_sender.cc',
169             'host/host_status_sender.h',
170             'host/host_window.h',
171             'host/host_window_proxy.cc',
172             'host/host_window_proxy.h',
173             'host/in_memory_host_config.cc',
174             'host/in_memory_host_config.h',
175             'host/input_injector.h',
176             'host/input_injector_linux.cc',
177             'host/input_injector_mac.cc',
178             'host/input_injector_win.cc',
179             'host/ipc_audio_capturer.cc',
180             'host/ipc_audio_capturer.h',
181             'host/ipc_constants.cc',
182             'host/ipc_constants.h',
183             'host/ipc_desktop_environment.cc',
184             'host/ipc_desktop_environment.h',
185             'host/ipc_host_event_logger.cc',
186             'host/ipc_host_event_logger.h',
187             'host/ipc_input_injector.cc',
188             'host/ipc_input_injector.h',
189             'host/ipc_mouse_cursor_monitor.cc',
190             'host/ipc_mouse_cursor_monitor.h',
191             'host/ipc_screen_controls.cc',
192             'host/ipc_screen_controls.h',
193             'host/ipc_util.h',
194             'host/ipc_util_posix.cc',
195             'host/ipc_util_win.cc',
196             'host/ipc_video_frame_capturer.cc',
197             'host/ipc_video_frame_capturer.h',
198             'host/it2me_desktop_environment.cc',
199             'host/it2me_desktop_environment.h',
200             'host/json_host_config.cc',
201             'host/json_host_config.h',
202             'host/linux/audio_pipe_reader.cc',
203             'host/linux/audio_pipe_reader.h',
204             'host/linux/unicode_to_keysym.cc',
205             'host/linux/unicode_to_keysym.h',
206             'host/linux/x11_util.cc',
207             'host/linux/x11_util.h',
208             'host/linux/x_server_clipboard.cc',
209             'host/linux/x_server_clipboard.h',
210             'host/local_input_monitor.h',
211             'host/local_input_monitor_linux.cc',
212             'host/local_input_monitor_mac.mm',
213             'host/local_input_monitor_win.cc',
214             'host/logging.h',
215             'host/logging_posix.cc',
216             'host/logging_win.cc',
217             'host/me2me_desktop_environment.cc',
218             'host/me2me_desktop_environment.h',
219             'host/mouse_clamping_filter.cc',
220             'host/mouse_clamping_filter.h',
221             'host/oauth_token_getter.cc',
222             'host/oauth_token_getter.h',
223             'host/pairing_registry_delegate.cc',
224             'host/pairing_registry_delegate.h',
225             'host/pairing_registry_delegate_linux.cc',
226             'host/pairing_registry_delegate_linux.h',
227             'host/pairing_registry_delegate_mac.cc',
228             'host/pairing_registry_delegate_win.cc',
229             'host/pairing_registry_delegate_win.h',
230             'host/pam_authorization_factory_posix.cc',
231             'host/pam_authorization_factory_posix.h',
232             'host/pin_hash.cc',
233             'host/pin_hash.h',
234             'host/policy_hack/policy_watcher.cc',
235             'host/policy_hack/policy_watcher.h',
236             'host/policy_hack/policy_watcher_chromeos.cc',
237             'host/policy_hack/policy_watcher_linux.cc',
238             'host/policy_hack/policy_watcher_mac.mm',
239             'host/policy_hack/policy_watcher_win.cc',
240             'host/register_support_host_request.cc',
241             'host/register_support_host_request.h',
242             'host/remote_input_filter.cc',
243             'host/remote_input_filter.h',
244             'host/remoting_me2me_host.cc',
245             'host/resizing_host_observer.cc',
246             'host/resizing_host_observer.h',
247             'host/sas_injector.h',
248             'host/sas_injector_win.cc',
249             'host/screen_controls.h',
250             'host/screen_resolution.cc',
251             'host/screen_resolution.h',
252             'host/server_log_entry_host.cc',
253             'host/server_log_entry_host.h',
254             'host/session_manager_factory.cc',
255             'host/session_manager_factory.h',
256             'host/shaped_desktop_capturer.cc',
257             'host/shaped_desktop_capturer.h',
258             'host/signaling_connector.cc',
259             'host/signaling_connector.h',
260             'host/single_window_desktop_environment.cc',
261             'host/single_window_desktop_environment.h',
262             'host/single_window_input_injector.h',
263             'host/single_window_input_injector_linux.cc',
264             'host/single_window_input_injector_mac.cc',
265             'host/single_window_input_injector_win.cc',
266             'host/token_validator_base.cc',
267             'host/token_validator_base.h',
268             'host/token_validator_factory_impl.cc',
269             'host/token_validator_factory_impl.h',
270             'host/usage_stats_consent.h',
271             'host/usage_stats_consent_mac.cc',
272             'host/usage_stats_consent_win.cc',
273             'host/username.cc',
274             'host/username.h',
275             'host/video_frame_recorder.cc',
276             'host/video_frame_recorder.h',
277             'host/video_frame_recorder_host_extension.cc',
278             'host/video_frame_recorder_host_extension.h',
279             'host/video_scheduler.cc',
280             'host/video_scheduler.h',
281             'host/win/com_imported_mstscax.tlh',
282             'host/win/com_security.cc',
283             'host/win/com_security.h',
284             'host/win/launch_process_with_token.cc',
285             'host/win/launch_process_with_token.h',
286             'host/win/omaha.cc',
287             'host/win/omaha.h',
288             'host/win/rdp_client.cc',
289             'host/win/rdp_client.h',
290             'host/win/rdp_client_window.cc',
291             'host/win/rdp_client_window.h',
292             'host/win/security_descriptor.cc',
293             'host/win/security_descriptor.h',
294             'host/win/session_desktop_environment.cc',
295             'host/win/session_desktop_environment.h',
296             'host/win/session_input_injector.cc',
297             'host/win/session_input_injector.h',
298             'host/win/window_station_and_desktop.cc',
299             'host/win/window_station_and_desktop.h',
300             'host/win/wts_terminal_monitor.cc',
301             'host/win/wts_terminal_monitor.h',
302             'host/win/wts_terminal_observer.h',
303           ],
304           'conditions': [
305             ['OS=="linux"', {
306               'dependencies': [
307                 '../build/linux/system.gyp:x11',
308                 '../build/linux/system.gyp:xext',
309                 '../build/linux/system.gyp:xfixes',
310                 '../build/linux/system.gyp:xi',
311                 '../build/linux/system.gyp:xrandr',
312                 '../build/linux/system.gyp:xtst',
313               ],
314               'link_settings': {
315                 'libraries': [
316                   '-lpam',
317                 ],
318               },
319             }],
320             ['OS=="linux" and chromeos==0 and use_ozone==0', {
321               'dependencies' : [
322                 # Always use GTK on Linux, even for Aura builds.
323                 '../build/linux/system.gyp:gtk',
324               ],
325             }],
326             ['chromeos==1', {
327               'dependencies' : [
328                 '../cc/cc.gyp:cc',
329                 '../components/components.gyp:policy_component_common',
330                 '../content/content.gyp:content',
331                 '../ppapi/ppapi_internal.gyp:ppapi_host',
332                 '../skia/skia.gyp:skia',
333                 '../ui/aura/aura.gyp:aura',
334                 '../ui/compositor/compositor.gyp:compositor',
335                 '../ui/events/events.gyp:events',
336                 '../ui/views/views.gyp:views',
337               ],
338               'include_dirs': [
339                 '../third_party/skia/include/utils',
340               ],
341               'sources!' : [
342                 'host/clipboard_x11.cc',
343                 'host/continue_window_linux.cc',
344                 'host/disconnect_window.cc',
345                 'host/disconnect_window_linux.cc',
346                 'host/policy_hack/policy_watcher_linux.cc',
347                 'host/remoting_me2me_host.cc',
348               ]
349             }, {  # chromeos==0
350                'sources!' : [
351                  'host/chromeos/aura_desktop_capturer.cc',
352                  'host/chromeos/aura_desktop_capturer.h',
353                  'host/chromeos/message_box.cc',
354                  'host/chromeos/message_box.h',
355                  'host/clipboard_aura.cc',
356                  'host/clipboard_aura.h',
357                  'host/continue_window_chromeos.cc',
358                  'host/disconnect_window_chromeos.cc',
359                  'host/policy_hack/policy_watcher_chromeos.cc',
360                ],
361             }],
362             ['OS=="mac"', {
363               'dependencies': [
364                 '../third_party/google_toolbox_for_mac/google_toolbox_for_mac.gyp:google_toolbox_for_mac',
365               ],
366               'link_settings': {
367                 'libraries': [
368                   '$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
369                   'libpam.a',
370                ],
371               },
372             }],
373             ['OS=="win"', {
374               'defines': [
375                 '_ATL_NO_EXCEPTIONS',
376                 'ISOLATION_AWARE_ENABLED=1',
377               ],
378               'dependencies': [
379                 '../sandbox/sandbox.gyp:sandbox',
380                 'remoting_host_messages',
381                 'remoting_lib_idl',
382               ],
383               'msvs_settings': {
384                 'VCCLCompilerTool': {
385                   # /MP conflicts with #import directive so we limit the number
386                   # of processes to spawn to 1.
387                   'AdditionalOptions': ['/MP1'],
388                 },
389               },
390               'variables': {
391                 'output_dir': '<(SHARED_INTERMEDIATE_DIR)/remoting/host',
392               },
393               'sources': [
394                 '<(output_dir)/remoting_host_messages.mc',
395               ],
396               'include_dirs': [
397                 '<(output_dir)',
398               ],
399               'direct_dependent_settings': {
400                 'include_dirs': [
401                   '<(output_dir)',
402                 ],
403               },
404               'rules': [{
405                 # Rule to run the message compiler.
406                 'rule_name': 'message_compiler',
407                 'extension': 'mc',
408                 'outputs': [
409                   '<(output_dir)/<(RULE_INPUT_ROOT).h',
410                   '<(output_dir)/<(RULE_INPUT_ROOT).rc',
411                 ],
412                 'action': [
413                   'mc.exe',
414                   '-h', '<(output_dir)',
415                   '-r', '<(output_dir)/.',
416                   '-u',
417                   '<(RULE_INPUT_PATH)',
418                 ],
419                 'process_outputs_as_sources': 1,
420                 'message': 'Running message compiler on <(RULE_INPUT_PATH)',
421               }],
422             }],
423             ['use_ash==1', {
424               'dependencies': [
425                  '../ash/ash.gyp:ash',
426               ],
427             }],
428             ['enable_webrtc==1', {
429               'dependencies': [
430                 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
431                 '../third_party/libjingle/libjingle.gyp:libpeerconnection',
432               ],
433               'sources': [
434                 'host/cast_extension.cc',
435                 'host/cast_extension.h',
436                 'host/cast_extension_session.cc',
437                 'host/cast_extension_session.h',
438                 'host/cast_video_capturer_adapter.cc',
439                 'host/cast_video_capturer_adapter.h',
440               ],
441             }],
442           ],
443         },  # end of target 'remoting_host'
445         {
446           'target_name': 'remoting_native_messaging_base',
447           'type': 'static_library',
448           'variables': { 'enable_wexit_time_destructors': 1, },
449           'dependencies': [
450             '../base/base.gyp:base',
451           ],
452           'sources': [
453             'host/native_messaging/pipe_messaging_channel.cc',
454             'host/native_messaging/pipe_messaging_channel.h',
455             'host/native_messaging/native_messaging_pipe.cc',
456             'host/native_messaging/native_messaging_pipe.h',
457             'host/native_messaging/native_messaging_reader.cc',
458             'host/native_messaging/native_messaging_reader.h',
459             'host/native_messaging/native_messaging_writer.cc',
460             'host/native_messaging/native_messaging_writer.h',
461           ],
462         },  # end of target 'remoting_native_messaging_base'
464         {
465           'target_name': 'remoting_host_setup_base',
466           'type': 'static_library',
467           'variables': { 'enable_wexit_time_destructors': 1, },
468           'dependencies': [
469             '../base/base.gyp:base',
470             '../google_apis/google_apis.gyp:google_apis',
471             'remoting_host',
472           ],
473           'defines': [
474             'VERSION=<(version_full)',
475           ],
476           'sources': [
477             'host/setup/daemon_controller.cc',
478             'host/setup/daemon_controller.h',
479             'host/setup/daemon_controller_delegate_linux.cc',
480             'host/setup/daemon_controller_delegate_linux.h',
481             'host/setup/daemon_controller_delegate_mac.h',
482             'host/setup/daemon_controller_delegate_mac.mm',
483             'host/setup/daemon_controller_delegate_win.cc',
484             'host/setup/daemon_controller_delegate_win.h',
485             'host/setup/daemon_installer_win.cc',
486             'host/setup/daemon_installer_win.h',
487             'host/setup/me2me_native_messaging_host.cc',
488             'host/setup/me2me_native_messaging_host.h',
489             'host/setup/oauth_client.cc',
490             'host/setup/oauth_client.h',
491             'host/setup/oauth_helper.cc',
492             'host/setup/oauth_helper.h',
493             'host/setup/pin_validator.cc',
494             'host/setup/pin_validator.h',
495             'host/setup/service_client.cc',
496             'host/setup/service_client.h',
497             'host/setup/test_util.cc',
498             'host/setup/test_util.h',
499             'host/setup/win/auth_code_getter.cc',
500             'host/setup/win/auth_code_getter.h',
501           ],
502           'conditions': [
503             ['OS=="win"', {
504               'dependencies': [
505                 '../google_update/google_update.gyp:google_update',
506                 'remoting_lib_idl',
507               ],
508               # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
509               'msvs_disabled_warnings': [4267, ],
510             }],
511           ],
512         },  # end of target 'remoting_host_setup_base'
514         # Generates native messaging manifest files.
515         {
516           'target_name': 'remoting_native_messaging_manifests',
517           'type': 'none',
518           'conditions': [
519             [ 'OS == "win"', {
520               'variables': {
521                 'me2me_host_path': 'remoting_native_messaging_host.exe',
522                 'it2me_host_path': 'remote_assistance_host.exe',
523               },
524             }],
525             [ 'OS == "mac"', {
526               'variables': {
527                 'me2me_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
528                 'native_messaging_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_NAME@")',
529                 'remote_assistance_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_NAME@")',
530                 'me2me_host_path':
531                     '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(native_messaging_host_bundle_name)/Contents/MacOS/native_messaging_host',
532                 'it2me_host_path':
533                     '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(remote_assistance_host_bundle_name)/Contents/MacOS/remote_assistance_host',
534               },
535             }],
536             [ 'OS != "mac" and OS != "win"', {
537               'variables': {
538                 'me2me_host_path':
539                     '/opt/google/chrome-remote-desktop/native-messaging-host',
540                 'it2me_host_path':
541                     '/opt/google/chrome-remote-desktop/remote-assistance-host',
542               },
543             }],
544           ],  # conditions
545           'sources': [
546             'host/it2me/com.google.chrome.remote_assistance.json.jinja2',
547             'host/setup/com.google.chrome.remote_desktop.json.jinja2',
548           ],
549           'rules': [{
550             'rule_name': 'generate_manifest',
551             'extension': 'jinja2',
552             'inputs': [
553               '<(remoting_localize_path)',
554               '<(branding_path)',
555             ],
556             'outputs': [
557               '<(PRODUCT_DIR)/remoting/<(RULE_INPUT_ROOT)',
558             ],
559             'action': [
560               'python', '<(remoting_localize_path)',
561               '--define', 'ME2ME_HOST_PATH=<(me2me_host_path)',
562               '--define', 'IT2ME_HOST_PATH=<(it2me_host_path)',
563               '--variables', '<(branding_path)',
564               '--template', '<(RULE_INPUT_PATH)',
565               '--locale_output', '<@(_outputs)',
566               'en',
567             ],
568           }],
569         },  # end of target 'remoting_native_messaging_manifests'
570         {
571           'target_name': 'remoting_start_host',
572           'type': 'executable',
573           'dependencies': [
574             'remoting_host_setup_base',
575           ],
576           'sources': [
577             'host/setup/host_starter.cc',
578             'host/setup/host_starter.h',
579             'host/setup/start_host.cc',
580           ],
581           'conditions': [
582             ['OS=="linux" and use_allocator!="none"', {
583               'dependencies': [
584                 '../base/allocator/allocator.gyp:allocator',
585               ],
586             }],
587           ],
588         },  # end of target 'remoting_start_host'
589         {
590           'target_name': 'remoting_infoplist_strings',
591           'type': 'none',
592           'dependencies': [
593             'remoting_resources',
594           ],
595           'sources': [
596             'host/remoting_me2me_host-InfoPlist.strings.jinja2',
597             'host/mac/me2me_preference_pane-InfoPlist.strings.jinja2',
598             'host/installer/mac/uninstaller/remoting_uninstaller-InfoPlist.strings.jinja2',
599             'host/setup/native_messaging_host-InfoPlist.strings.jinja2',
600             'host/it2me/remote_assistance_host-InfoPlist.strings.jinja2',
601           ],
602           'rules': [{
603             'rule_name': 'generate_strings',
604             'extension': 'jinja2',
605             'inputs': [
606               '<(remoting_localize_path)',
607             ],
608             'outputs': [
609               '<!@pymod_do_main(remoting_localize --locale_output '
610                   '"<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings" '
611                   '--print_only <(remoting_locales))',
612             ],
613             'action': [
614               'python', '<(remoting_localize_path)',
615               '--locale_dir', '<(webapp_locale_dir)',
616               '--template', '<(RULE_INPUT_PATH)',
617               '--locale_output',
618               '<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings',
619               '<@(remoting_locales)',
620             ]},
621           ],
622         },  # end of target 'remoting_infoplist_strings'
623       ],  # end of 'targets'
624     }],  # 'enable_remoting_host==1'
626     ['enable_me2me_host==1', {
627       'targets': [
628         {
629           'target_name': 'remoting_me2me_host_static',
630           'type': 'static_library',
631           'variables': { 'enable_wexit_time_destructors': 1, },
632           'dependencies': [
633             '../base/base.gyp:base',
634             '../base/base.gyp:base_i18n',
635             '../net/net.gyp:net',
636             '../third_party/webrtc/modules/modules.gyp:desktop_capture',
637             'remoting_base',
638             'remoting_breakpad',
639             'remoting_host',
640             'remoting_protocol',
641           ],
642           'defines': [
643             'VERSION=<(version_full)',
644           ],
645           'sources': [
646             'host/curtain_mode.h',
647             'host/curtain_mode_linux.cc',
648             'host/curtain_mode_mac.cc',
649             'host/curtain_mode_win.cc',
650             'host/posix/signal_handler.cc',
651             'host/posix/signal_handler.h',
652           ],
653           'conditions': [
654             ['os_posix != 1', {
655               'sources/': [
656                 ['exclude', '^host/posix/'],
657               ],
658             }],
659           ],  # end of 'conditions'
660         },  # end of target 'remoting_me2me_host_static'
661       ] # end of targets
662     }], # end of enable_me2me_host==1
664     ['enable_it2me_host==1', {
665       'targets': [
666         {
667           'target_name': 'remoting_it2me_host_static',
668           'type': 'static_library',
669           'variables': { 'enable_wexit_time_destructors': 1, },
670           'dependencies': [
671             '../base/base.gyp:base_i18n',
672             '../net/net.gyp:net',
673             'remoting_base',
674             'remoting_host',
675             'remoting_infoplist_strings',
676             'remoting_protocol',
677             'remoting_resources',
678           ],
679           'defines': [
680             'VERSION=<(version_full)',
681           ],
682           'sources': [
683             'host/it2me/it2me_host.cc',
684             'host/it2me/it2me_host.h',
685             'host/it2me/it2me_native_messaging_host.cc',
686             'host/it2me/it2me_native_messaging_host.h',
687           ],
688         },  # end of target 'remoting_it2me_host_static'
689       ] # end of targets
690     }], # end of 'enable_it2me_host==1'
692     ['OS!="win" and enable_me2me_host==1', {
693       'targets': [
694         {
695           'target_name': 'remoting_me2me_host',
696           'type': 'executable',
697           'variables': { 'enable_wexit_time_destructors': 1, },
698           'dependencies': [
699             '../base/base.gyp:base',
700             '../base/base.gyp:base_i18n',
701             '<(icu_gyp_path):icudata',
702             '../net/net.gyp:net',
703             '../third_party/webrtc/modules/modules.gyp:desktop_capture',
704             'remoting_base',
705             'remoting_breakpad',
706             'remoting_host',
707             'remoting_infoplist_strings',
708             'remoting_me2me_host_static',
709             'remoting_protocol',
710           ],
711           'defines': [
712             'VERSION=<(version_full)',
713           ],
714           'sources': [
715             'host/host_main.cc',
716             'host/host_main.h',
717           ],
718           'conditions': [
719             ['OS=="mac"', {
720               'mac_bundle': 1,
721               'variables': {
722                  'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_ID@")',
723               },
724               'xcode_settings': {
725                 'INFOPLIST_FILE': 'host/remoting_me2me_host-Info.plist',
726                 'INFOPLIST_PREPROCESS': 'YES',
727                 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
728               },
729               'mac_bundle_resources': [
730                 '<(PRODUCT_DIR)/icudtl.dat',
731                 'host/disconnect_window.xib',
732                 'host/remoting_me2me_host.icns',
733                 'host/remoting_me2me_host-Info.plist',
734                 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
736                 # Localized strings for 'Info.plist'
737                 '<!@pymod_do_main(remoting_localize --locale_output '
738                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/remoting_me2me_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
739                     '--print_only <(remoting_locales))',
740               ],
741               'mac_bundle_resources!': [
742                 'host/remoting_me2me_host-Info.plist',
743               ],
744               'conditions': [
745                 ['mac_breakpad==1', {
746                   'variables': {
747                     # A real .dSYM is needed for dump_syms to operate on.
748                     'mac_real_dsym': 1,
749                   },
750                   'copies': [
751                     {
752                       'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
753                       'files': [
754                         '<(PRODUCT_DIR)/crash_inspector',
755                         '<(PRODUCT_DIR)/crash_report_sender.app'
756                       ],
757                     },
758                   ],
759                   'dependencies': [
760                     '../breakpad/breakpad.gyp:dump_syms',
761                   ],
762                   'postbuilds': [
763                     {
764                       'postbuild_name': 'Dump Symbols',
765                       'variables': {
766                         'dump_product_syms_path':
767                             'scripts/mac/dump_product_syms',
768                       },
769                       'action': [
770                         '<(dump_product_syms_path)',
771                         '<(version_full)',
772                       ],
773                     },  # end of postbuild 'dump_symbols'
774                   ],  # end of 'postbuilds'
775                 }],  # mac_breakpad==1
776               ],  # conditions
777             }],  # OS=mac
778             ['OS=="linux" and use_allocator!="none"', {
779               'dependencies': [
780                 '../base/allocator/allocator.gyp:allocator',
781               ],
782             }],  # OS=linux
783           ],  # end of 'conditions'
784         },  # end of target 'remoting_me2me_host'
785         {
786           'target_name': 'remoting_me2me_native_messaging_host',
787           'type': 'executable',
788           'product_name': 'native_messaging_host',
789           'variables': { 'enable_wexit_time_destructors': 1, },
790           'dependencies': [
791             '../base/base.gyp:base',
792             'remoting_breakpad',
793             'remoting_host',
794             'remoting_host_setup_base',
795             'remoting_infoplist_strings',
796             'remoting_native_messaging_base',
797           ],
798           'defines': [
799             'VERSION=<(version_full)',
800           ],
801           'sources': [
802             'host/setup/me2me_native_messaging_host_entry_point.cc',
803             'host/setup/me2me_native_messaging_host_main.cc',
804             'host/setup/me2me_native_messaging_host_main.h',
805           ],
806           'conditions': [
807             ['OS=="linux" and use_allocator!="none"', {
808               'dependencies': [
809                 '../base/allocator/allocator.gyp:allocator',
810               ],
811             }],
812             ['OS=="mac"', {
813               'mac_bundle': 1,
814               'variables': {
815                  'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_ID@")',
816               },
817               'xcode_settings': {
818                 'INFOPLIST_FILE': 'host/setup/native_messaging_host-Info.plist',
819                 'INFOPLIST_PREPROCESS': 'YES',
820                 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
821               },
822               'mac_bundle_resources': [
823                 'host/setup/native_messaging_host-Info.plist',
824                 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
826                 # Localized strings for 'Info.plist'
827                 '<!@pymod_do_main(remoting_localize --locale_output '
828                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/native_messaging_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
829                     '--print_only <(remoting_locales))',
830               ],
831               'mac_bundle_resources!': [
832                 'host/setup/native_messaging_host-Info.plist',
833               ],
834               'conditions': [
835                 ['mac_breakpad==1', {
836                   'variables': {
837                     # A real .dSYM is needed for dump_syms to operate on.
838                     'mac_real_dsym': 1,
839                   },
840                   'copies': [
841                     {
842                       'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
843                       'files': [
844                         '<(PRODUCT_DIR)/crash_inspector',
845                         '<(PRODUCT_DIR)/crash_report_sender.app'
846                       ],
847                     },
848                   ],
849                   'dependencies': [
850                     '../breakpad/breakpad.gyp:dump_syms',
851                   ],
852                   'postbuilds': [
853                     {
854                       'postbuild_name': 'Dump Symbols',
855                       'variables': {
856                         'dump_product_syms_path':
857                             'scripts/mac/dump_product_syms',
858                       },
859                       'action': [
860                         '<(dump_product_syms_path)',
861                         '<(version_full)',
862                       ],
863                     },  # end of postbuild 'dump_symbols'
864                   ],  # end of 'postbuilds'
865                 }],  # mac_breakpad==1
866               ],  # conditions
867             }],  # OS=mac
868           ],
869         },  # end of target 'remoting_me2me_native_messaging_host'
870       ], # targets
871     }], # end of OS!="win" and enable_me2me_host==1
873     ['OS!="win" and enable_it2me_host==1 and chromeos==0', {
874       'targets': [
875         {
876           'target_name': 'remoting_it2me_native_messaging_host',
877           'type': 'executable',
878           'product_name': 'remote_assistance_host',
879           'variables': { 'enable_wexit_time_destructors': 1, },
880           'dependencies': [
881             '../base/base.gyp:base',
882             'remoting_base',
883             'remoting_breakpad',
884             'remoting_host',
885             'remoting_it2me_host_static',
886             'remoting_native_messaging_base',
887             'remoting_protocol',
888           ],
889           'defines': [
890             'VERSION=<(version_full)',
891           ],
892           'sources': [
893             'host/it2me/it2me_native_messaging_host_entry_point.cc',
894             'host/it2me/it2me_native_messaging_host_main.cc',
895             'host/it2me/it2me_native_messaging_host_main.h',
896           ],
897           'conditions': [
898             ['OS=="linux" and chromeos==0 and use_ozone==0', {
899               'dependencies': [
900                 # Always use GTK on Linux, even for Aura builds.
901                 '../build/linux/system.gyp:gtk',
902               ],
903             }],
904             ['OS=="linux" and use_allocator!="none"', {
905               'dependencies': [
906                 '../base/allocator/allocator.gyp:allocator',
907               ],
908             }],
909             ['OS=="mac"', {
910               'mac_bundle': 1,
911               'variables': {
912                  'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_ID@")',
913               },
914               'xcode_settings': {
915                 'INFOPLIST_FILE': 'host/it2me/remote_assistance_host-Info.plist',
916                 'INFOPLIST_PREPROCESS': 'YES',
917                 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
918               },
919               'mac_bundle_resources': [
920                 '<(PRODUCT_DIR)/icudtl.dat',
921                 'host/disconnect_window.xib',
922                 'host/it2me/remote_assistance_host-Info.plist',
923                 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
925                 # Localized strings for 'Info.plist'
926                 '<!@pymod_do_main(remoting_localize --locale_output '
927                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/remote_assistance_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
928                     '--print_only <(remoting_locales))',
929               ],
930               'mac_bundle_resources!': [
931                 'host/it2me/remote_assistance_host-Info.plist',
932               ],
933               'conditions': [
934                 ['mac_breakpad==1', {
935                   'variables': {
936                     # A real .dSYM is needed for dump_syms to operate on.
937                     'mac_real_dsym': 1,
938                   },
939                   'copies': [
940                     {
941                       'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
942                       'files': [
943                         '<(PRODUCT_DIR)/crash_inspector',
944                         '<(PRODUCT_DIR)/crash_report_sender.app'
945                       ],
946                     },
947                   ],
948                   'dependencies': [
949                     '../breakpad/breakpad.gyp:dump_syms',
950                   ],
951                   'postbuilds': [
952                     {
953                       'postbuild_name': 'Dump Symbols',
954                       'variables': {
955                         'dump_product_syms_path':
956                             'scripts/mac/dump_product_syms',
957                       },
958                       'action': [
959                         '<(dump_product_syms_path)',
960                         '<(version_full)',
961                       ],
962                     },  # end of postbuild 'dump_symbols'
963                   ],  # end of 'postbuilds'
964                 }],  # mac_breakpad==1
965               ],  # conditions
966             }],  # OS=mac
967           ],
968         },  # end of target 'remoting_it2me_native_messaging_host'
969       ],  # end of 'targets'
970     }],  # # end of OS!="win" and enable_it2me_host==1
972   ],  # end of 'conditions'