Update Crashpad to 1baff4ff92fe1a1ead6b88b5f01633a4f0b6b51c.
[chromium-blink-merge.git] / remoting / remoting_host.gypi
blob7571f7afa73dacacd4817e18f23e81e961732b7a
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_enable.gypi',
8   ],
10   'conditions': [
11     ['OS=="mac"', {
12       'includes': [
13         'remoting_host_mac.gypi',
14       ],
15     }],
16     ['OS=="win"', {
17       'includes': [
18         'remoting_host_win.gypi',
19       ],
20     }],
21     ['OS=="linux"', {
22       'includes': [
23         'remoting_host_linux.gypi',
24       ],
25     }],
27     ['enable_remoting_host==1', {
28       'targets': [
29         {
30           # GN version: //remoting/host
31           'target_name': 'remoting_host',
32           'type': 'static_library',
33           'variables': {
34             'enable_wexit_time_destructors': 1,
35             'host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
36             'prefpane_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_PREFPANE_BUNDLE_NAME@")',
37           },
38           'dependencies': [
39             'remoting_base',
40             'remoting_protocol',
41             'remoting_resources',
42             '../base/base.gyp:base_i18n',
43             '../components/components.gyp:policy',
44             '../components/components.gyp:policy_component_common',
45             '../crypto/crypto.gyp:crypto',
46             '../google_apis/google_apis.gyp:google_apis',
47             '../ipc/ipc.gyp:ipc',
48             '../ui/events/events.gyp:dom4_keycode_converter',
49           ],
50           'defines': [
51             'HOST_BUNDLE_NAME="<(host_bundle_name)"',
52             'PREFPANE_BUNDLE_NAME="<(prefpane_bundle_name)"',
53             'VERSION=<(version_full)',
54           ],
55           'sources': [
56             '<@(remoting_host_sources)',
57           ],
58           'conditions': [
59             ['OS=="linux"', {
60               'conditions': [
61                 ['use_x11==1', {
62                   'dependencies': [
63                     '../build/linux/system.gyp:x11',
64                     '../build/linux/system.gyp:xext',
65                     '../build/linux/system.gyp:xfixes',
66                     '../build/linux/system.gyp:xi',
67                     '../build/linux/system.gyp:xrandr',
68                     '../build/linux/system.gyp:xtst',
69                   ],
70                 }],
71                 ['chromeos==0 and use_ozone==0', {
72                   'dependencies': [
73                     # use GTK on Linux, even for Aura builds.
74                     '../build/linux/system.gyp:gtk',
75                   ],
76                 }]
77               ],
78             }],
79             ['chromeos==1', {
80               'dependencies' : [
81                 '../cc/cc.gyp:cc',
82                 '../ppapi/ppapi_internal.gyp:ppapi_host',
83                 '../skia/skia.gyp:skia',
84                 '../ui/aura/aura.gyp:aura',
85                 '../ui/compositor/compositor.gyp:compositor',
86                 '../ui/events/events.gyp:events',
87                 '../ui/events/platform/events_platform.gyp:events_platform',
88                 '../ui/views/views.gyp:views',
89               ],
90               'include_dirs': [
91                 '../third_party/skia/include/utils',
92               ],
93               'sources!' : [
94                 'host/clipboard_x11.cc',
95                 'host/continue_window_linux.cc',
96                 'host/disconnect_window_linux.cc',
97                 'host/linux/x_server_clipboard.cc',
98                 'host/linux/x_server_clipboard.h',
99                 'host/local_input_monitor_x11.cc',
100               ],
101               'conditions': [
102                 ['use_ash==1', {
103                   'dependencies': [
104                     '../ash/ash.gyp:ash',
105                   ],
106                 }],
107                 ['use_ozone==0', {
108                   'sources!': [
109                     'host/input_injector_chromeos.cc',
110                     'host/input_injector_chromeos.h',
111                   ],
112                 }, {  # use_ozone==1
113                   'dependencies' : [
114                     '../ui/ozone/ozone.gyp:ozone',
115                   ]
116                 }],
117               ],
118             }],
119             ['OS=="mac"', {
120               'dependencies': [
121                 '../third_party/google_toolbox_for_mac/google_toolbox_for_mac.gyp:google_toolbox_for_mac',
122               ],
123               'variables': {
124                 # Include internal_mac-inl.h only if it exists.
125                 'use_remoting_macosx_internal%':
126                   '<!(python -c "import os; print 1 if os.path.exists(\'tools/internal/internal_mac-inl.h\') else 0")'
127               },
128               'conditions': [
129                 ['use_remoting_macosx_internal==1', {
130                   'sources': [
131                     'internal/internal_mac-inl.h'
132                   ],
133                   'defines': [
134                     'USE_REMOTING_MACOSX_INTERNAL'
135                   ]
136                 }]
137               ],
138               'link_settings': {
139                 'libraries': [
140                   '$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
141                ],
142               },
143             }],
144             ['OS=="win"', {
145               'defines': [
146                 '_ATL_NO_EXCEPTIONS',
147                 'ISOLATION_AWARE_ENABLED=1',
148               ],
149               'dependencies': [
150                 '../sandbox/sandbox.gyp:sandbox',
151                 'remoting_host_messages',
152                 'remoting_lib_idl',
153               ],
154               'msvs_settings': {
155                 'VCCLCompilerTool': {
156                   # /MP conflicts with #import directive so we limit the number
157                   # of processes to spawn to 1.
158                   'AdditionalOptions': ['/MP1'],
159                 },
160               },
161               'variables': {
162                 'output_dir': '<(SHARED_INTERMEDIATE_DIR)/remoting/host',
163               },
164               'sources': [
165                 '<(output_dir)/remoting_host_messages.mc',
166               ],
167               'include_dirs': [
168                 '<(output_dir)',
169               ],
170               'direct_dependent_settings': {
171                 'include_dirs': [
172                   '<(output_dir)',
173                 ],
174               },
175               'rules': [{
176                 # Rule to run the message compiler.
177                 'rule_name': 'message_compiler',
178                 'extension': 'mc',
179                 'outputs': [
180                   '<(output_dir)/<(RULE_INPUT_ROOT).h',
181                   '<(output_dir)/<(RULE_INPUT_ROOT).rc',
182                 ],
183                 'action': [
184                   'mc.exe',
185                   '-h', '<(output_dir)',
186                   '-r', '<(output_dir)/.',
187                   '-u',
188                   '<(RULE_INPUT_PATH)',
189                 ],
190                 'process_outputs_as_sources': 1,
191                 'message': 'Running message compiler on <(RULE_INPUT_PATH)',
192               }],
193             }],
194             ['enable_webrtc==1', {
195               'dependencies': [
196                 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
197                 '../third_party/libjingle/libjingle.gyp:libpeerconnection',
198               ],
199               'sources': [
200                 '<@(remoting_cast_sources)',
201               ],
202             }],
203           ],
204         },  # end of target 'remoting_host'
206         {
207           # GN version: //remoting/host/native_messaging
208           'target_name': 'remoting_native_messaging_base',
209           'type': 'static_library',
210           'variables': { 'enable_wexit_time_destructors': 1, },
211           'dependencies': [
212             '../base/base.gyp:base',
213           ],
214           'sources': [
215             '<@(remoting_host_native_messaging_sources)',
216           ],
217         },  # end of target 'remoting_native_messaging_base'
219         {
220           # GN version: //remoting/host/setup
221           'target_name': 'remoting_host_setup_base',
222           'type': 'static_library',
223           'variables': { 'enable_wexit_time_destructors': 1, },
224           'dependencies': [
225             '../base/base.gyp:base',
226             '../google_apis/google_apis.gyp:google_apis',
227             'remoting_host',
228           ],
229           'defines': [
230             'VERSION=<(version_full)',
231           ],
232           'sources': [
233             '<@(remoting_host_setup_sources)',
234           ],
235           'conditions': [
236             ['OS=="win"', {
237               'dependencies': [
238                 '../google_update/google_update.gyp:google_update',
239                 'remoting_lib_idl',
240               ],
241               # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
242               'msvs_disabled_warnings': [4267, ],
243             }],
244           ],
245         },  # end of target 'remoting_host_setup_base'
247         # Generates native messaging manifest files.
248         {
249           'target_name': 'remoting_native_messaging_manifests',
250           'type': 'none',
251           'conditions': [
252             [ 'OS == "win"', {
253               'variables': {
254                 'me2me_host_path': 'remoting_native_messaging_host.exe',
255                 'it2me_host_path': 'remote_assistance_host.exe',
256               },
257             }],
258             [ 'OS == "mac"', {
259               'variables': {
260                 'me2me_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
261                 'native_messaging_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_NAME@")',
262                 'remote_assistance_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_NAME@")',
263                 'me2me_host_path':
264                     '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(native_messaging_host_bundle_name)/Contents/MacOS/native_messaging_host',
265                 'it2me_host_path':
266                     '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(remote_assistance_host_bundle_name)/Contents/MacOS/remote_assistance_host',
267               },
268             }],
269             [ 'OS != "mac" and OS != "win"', {
270               'variables': {
271                 'me2me_host_path':
272                     '/opt/google/chrome-remote-desktop/native-messaging-host',
273                 'it2me_host_path':
274                     '/opt/google/chrome-remote-desktop/remote-assistance-host',
275               },
276             }],
277           ],  # conditions
278           'sources': [
279             'host/it2me/com.google.chrome.remote_assistance.json.jinja2',
280             'host/setup/com.google.chrome.remote_desktop.json.jinja2',
281           ],
282           'rules': [{
283             'rule_name': 'generate_manifest',
284             'extension': 'jinja2',
285             'inputs': [
286               '<(remoting_localize_path)',
287               '<(branding_path)',
288             ],
289             'outputs': [
290               '<(PRODUCT_DIR)/remoting/<(RULE_INPUT_ROOT)',
291             ],
292             'action': [
293               'python', '<(remoting_localize_path)',
294               '--define', 'ME2ME_HOST_PATH=<(me2me_host_path)',
295               '--define', 'IT2ME_HOST_PATH=<(it2me_host_path)',
296               '--variables', '<(branding_path)',
297               '--template', '<(RULE_INPUT_PATH)',
298               '--locale_output', '<@(_outputs)',
299               'en',
300             ],
301           }],
302         },  # end of target 'remoting_native_messaging_manifests'
303         {
304           # GN target: //remoting/host:remoting_start_host
305           'target_name': 'remoting_start_host',
306           'type': 'executable',
307           'dependencies': [
308             'remoting_host_setup_base',
309           ],
310           'sources': [
311             'host/setup/host_starter.cc',
312             'host/setup/host_starter.h',
313             'host/setup/start_host.cc',
314           ],
315           'conditions': [
316             ['OS=="linux" and use_allocator!="none"', {
317               'dependencies': [
318                 '../base/allocator/allocator.gyp:allocator',
319               ],
320             }],
321           ],
322         },  # end of target 'remoting_start_host'
323         {
324           'target_name': 'remoting_infoplist_strings',
325           'type': 'none',
326           'dependencies': [
327             'remoting_resources',
328           ],
329           'sources': [
330             'host/remoting_me2me_host-InfoPlist.strings.jinja2',
331             'host/mac/me2me_preference_pane-InfoPlist.strings.jinja2',
332             'host/installer/mac/uninstaller/remoting_uninstaller-InfoPlist.strings.jinja2',
333             'host/setup/native_messaging_host-InfoPlist.strings.jinja2',
334             'host/it2me/remote_assistance_host-InfoPlist.strings.jinja2',
335           ],
336           'rules': [{
337             'rule_name': 'generate_strings',
338             'extension': 'jinja2',
339             'inputs': [
340               '<(remoting_localize_path)',
341             ],
342             'outputs': [
343               '<!@pymod_do_main(remoting_localize --locale_output '
344                   '"<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings" '
345                   '--print_only <(remoting_locales))',
346             ],
347             'action': [
348               'python', '<(remoting_localize_path)',
349               '--locale_dir', '<(webapp_locale_dir)',
350               '--template', '<(RULE_INPUT_PATH)',
351               '--locale_output',
352               '<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings',
353               '<@(remoting_locales)',
354             ]},
355           ],
356         },  # end of target 'remoting_infoplist_strings'
357         {
358           # GN version: //remoting/host/it2me:common
359           'target_name': 'remoting_it2me_host_static',
360           'type': 'static_library',
361           'variables': { 'enable_wexit_time_destructors': 1, },
362           'dependencies': [
363             '../base/base.gyp:base_i18n',
364             '../components/components.gyp:policy',
365             '../net/net.gyp:net',
366             'remoting_base',
367             'remoting_host',
368             'remoting_infoplist_strings',
369             'remoting_protocol',
370             'remoting_resources',
371           ],
372           'defines': [
373             'VERSION=<(version_full)',
374           ],
375           'sources': [
376             '<@(remoting_it2me_host_static_sources)',
377           ],
378         },  # end of target 'remoting_it2me_host_static'
379       ],  # end of 'targets'
380     }],  # 'enable_remoting_host==1'
382     ['enable_me2me_host==1', {
383       'targets': [
384         {
385           'target_name': 'remoting_me2me_host_static',
386           'type': 'static_library',
387           'variables': { 'enable_wexit_time_destructors': 1, },
388           'dependencies': [
389             '../base/base.gyp:base',
390             '../base/base.gyp:base_i18n',
391             '../components/components.gyp:policy',
392             '../components/components.gyp:policy_component_common',
393             '../net/net.gyp:net',
394             '../third_party/webrtc/modules/modules.gyp:desktop_capture',
395             'remoting_base',
396             'remoting_breakpad',
397             'remoting_host',
398             'remoting_protocol',
399           ],
400           'defines': [
401             'VERSION=<(version_full)',
402           ],
403           'sources': [
404             'host/curtain_mode.h',
405             'host/curtain_mode_linux.cc',
406             'host/curtain_mode_mac.cc',
407             'host/curtain_mode_win.cc',
408             'host/pam_authorization_factory_posix.cc',
409             'host/pam_authorization_factory_posix.h',
410             'host/posix/signal_handler.cc',
411             'host/posix/signal_handler.h',
412             'host/remoting_me2me_host.cc',
413           ],
414           'conditions': [
415             ['OS=="linux"', {
416               'link_settings': {
417                 'libraries': [
418                   '-lpam',
419                 ],
420               },
421             }],
422             ['OS=="mac"', {
423               'link_settings': {
424                 'libraries': [
425                   'libpam.a',
426                ],
427               },
428             }],
429           ],  # end of 'conditions'
430         },  # end of target 'remoting_me2me_host_static'
431       ]  # end of targets
432     }],  # end of enable_me2me_host==1
434     ['OS!="win" and enable_me2me_host==1', {
435       'targets': [
436         {
437           'target_name': 'remoting_me2me_host',
438           'type': 'executable',
439           'variables': { 'enable_wexit_time_destructors': 1, },
440           'dependencies': [
441             '../base/base.gyp:base',
442             '../base/base.gyp:base_i18n',
443             '<(icu_gyp_path):icudata',
444             '../net/net.gyp:net',
445             '../third_party/webrtc/modules/modules.gyp:desktop_capture',
446             'remoting_base',
447             'remoting_breakpad',
448             'remoting_host',
449             'remoting_infoplist_strings',
450             'remoting_me2me_host_static',
451             'remoting_protocol',
452           ],
453           'defines': [
454             'VERSION=<(version_full)',
455           ],
456           'sources': [
457             'host/host_main.cc',
458             'host/host_main.h',
459           ],
460           'conditions': [
461             ['OS=="mac"', {
462               'mac_bundle': 1,
463               'variables': {
464                  'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_ID@")',
465               },
466               'xcode_settings': {
467                 'INFOPLIST_FILE': 'host/remoting_me2me_host-Info.plist',
468                 'INFOPLIST_PREPROCESS': 'YES',
469                 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
470               },
471               'mac_bundle_resources': [
472                 '<(PRODUCT_DIR)/icudtl.dat',
473                 'host/disconnect_window.xib',
474                 'host/remoting_me2me_host.icns',
475                 'host/remoting_me2me_host-Info.plist',
476                 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
478                 # Localized strings for 'Info.plist'
479                 '<!@pymod_do_main(remoting_localize --locale_output '
480                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/remoting_me2me_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
481                     '--print_only <(remoting_locales))',
482               ],
483               'mac_bundle_resources!': [
484                 'host/remoting_me2me_host-Info.plist',
485               ],
486               'conditions': [
487                 ['mac_breakpad==1', {
488                   'variables': {
489                     # A real .dSYM is needed for dump_syms to operate on.
490                     'mac_real_dsym': 1,
491                   },
492                   'copies': [
493                     {
494                       'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
495                       'files': [
496                         '<(PRODUCT_DIR)/crash_inspector',
497                         '<(PRODUCT_DIR)/crash_report_sender.app'
498                       ],
499                     },
500                   ],
501                   'dependencies': [
502                     '../breakpad/breakpad.gyp:dump_syms',
503                   ],
504                   'postbuilds': [
505                     {
506                       'postbuild_name': 'Dump Symbols',
507                       'variables': {
508                         'dump_product_syms_path':
509                             'scripts/mac/dump_product_syms',
510                       },
511                       'action': [
512                         '<(dump_product_syms_path)',
513                         '<(version_full)',
514                       ],
515                     },  # end of postbuild 'dump_symbols'
516                   ],  # end of 'postbuilds'
517                 }],  # mac_breakpad==1
518               ],  # conditions
519             }],  # OS=mac
520             ['OS=="linux" and use_allocator!="none"', {
521               'dependencies': [
522                 '../base/allocator/allocator.gyp:allocator',
523               ],
524             }],  # OS=linux
525           ],  # end of 'conditions'
526         },  # end of target 'remoting_me2me_host'
527         {
528           'target_name': 'remoting_me2me_native_messaging_host',
529           'type': 'executable',
530           'product_name': 'native_messaging_host',
531           'variables': { 'enable_wexit_time_destructors': 1, },
532           'dependencies': [
533             '../base/base.gyp:base',
534             'remoting_breakpad',
535             'remoting_host',
536             'remoting_host_setup_base',
537             'remoting_infoplist_strings',
538             'remoting_native_messaging_base',
539           ],
540           'defines': [
541             'VERSION=<(version_full)',
542           ],
543           'sources': [
544             'host/setup/me2me_native_messaging_host_entry_point.cc',
545             'host/setup/me2me_native_messaging_host_main.cc',
546             'host/setup/me2me_native_messaging_host_main.h',
547           ],
548           'conditions': [
549             ['OS=="linux" and use_allocator!="none"', {
550               'dependencies': [
551                 '../base/allocator/allocator.gyp:allocator',
552               ],
553             }],
554             ['OS=="mac"', {
555               'mac_bundle': 1,
556               'variables': {
557                  'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_ID@")',
558               },
559               'xcode_settings': {
560                 'INFOPLIST_FILE': 'host/setup/native_messaging_host-Info.plist',
561                 'INFOPLIST_PREPROCESS': 'YES',
562                 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
563               },
564               'mac_bundle_resources': [
565                 'host/setup/native_messaging_host-Info.plist',
566                 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
568                 # Localized strings for 'Info.plist'
569                 '<!@pymod_do_main(remoting_localize --locale_output '
570                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/native_messaging_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
571                     '--print_only <(remoting_locales))',
572               ],
573               'mac_bundle_resources!': [
574                 'host/setup/native_messaging_host-Info.plist',
575               ],
576               'conditions': [
577                 ['mac_breakpad==1', {
578                   'variables': {
579                     # A real .dSYM is needed for dump_syms to operate on.
580                     'mac_real_dsym': 1,
581                   },
582                   'copies': [
583                     {
584                       'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
585                       'files': [
586                         '<(PRODUCT_DIR)/crash_inspector',
587                         '<(PRODUCT_DIR)/crash_report_sender.app'
588                       ],
589                     },
590                   ],
591                   'dependencies': [
592                     '../breakpad/breakpad.gyp:dump_syms',
593                   ],
594                   'postbuilds': [
595                     {
596                       'postbuild_name': 'Dump Symbols',
597                       'variables': {
598                         'dump_product_syms_path':
599                             'scripts/mac/dump_product_syms',
600                       },
601                       'action': [
602                         '<(dump_product_syms_path)',
603                         '<(version_full)',
604                       ],
605                     },  # end of postbuild 'dump_symbols'
606                   ],  # end of 'postbuilds'
607                 }],  # mac_breakpad==1
608               ],  # conditions
609             }],  # OS=mac
610           ],
611         },  # end of target 'remoting_me2me_native_messaging_host'
612       ], # targets
613     }], # end of OS!="win" and enable_me2me_host==1
615     ['OS!="win" and enable_remoting_host==1', {
616       'conditions': [
617         ['chromeos==0', {
618           'targets': [
619             {
620               'target_name': 'remoting_it2me_native_messaging_host',
621               'type': 'executable',
622               'product_name': 'remote_assistance_host',
623               'variables': { 'enable_wexit_time_destructors': 1, },
624               'dependencies': [
625                 '../base/base.gyp:base',
626                 'remoting_base',
627                 'remoting_breakpad',
628                 'remoting_host',
629                 'remoting_it2me_host_static',
630                 'remoting_native_messaging_base',
631                 'remoting_protocol',
632               ],
633               'defines': [
634                 'VERSION=<(version_full)',
635               ],
636               'sources': [
637                 'host/it2me/it2me_native_messaging_host_entry_point.cc',
638                 'host/it2me/it2me_native_messaging_host_main.cc',
639                 'host/it2me/it2me_native_messaging_host_main.h',
640               ],
641               'conditions': [
642                 ['OS=="linux" and chromeos==0 and use_ozone==0', {
643                   'dependencies': [
644                     # Always use GTK on Linux, even for Aura builds.
645                     '../build/linux/system.gyp:gtk',
646                   ],
647                 }],
648                 ['OS=="linux" and use_allocator!="none"', {
649                   'dependencies': [
650                     '../base/allocator/allocator.gyp:allocator',
651                   ],
652                 }],
653                 ['OS=="mac"', {
654                   'mac_bundle': 1,
655                   'variables': {
656                     'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_ID@")',
657                   },
658                   'xcode_settings': {
659                     'INFOPLIST_FILE': 'host/it2me/remote_assistance_host-Info.plist',
660                     'INFOPLIST_PREPROCESS': 'YES',
661                     'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
662                   },
663                   'mac_bundle_resources': [
664                     '<(PRODUCT_DIR)/icudtl.dat',
665                     'host/disconnect_window.xib',
666                     'host/it2me/remote_assistance_host-Info.plist',
667                     '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
669                     # Localized strings for 'Info.plist'
670                     '<!@pymod_do_main(remoting_localize --locale_output '
671                     '"<(SHARED_INTERMEDIATE_DIR)/remoting/remote_assistance_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
672                     '--print_only <(remoting_locales))',
673                   ],
674                   'mac_bundle_resources!': [
675                     'host/it2me/remote_assistance_host-Info.plist',
676                   ],
677                   'conditions': [
678                     ['mac_breakpad==1', {
679                       'variables': {
680                         # A real .dSYM is needed for dump_syms to operate on.
681                         'mac_real_dsym': 1,
682                       },
683                       'copies': [
684                         {
685                           'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
686                           'files': [
687                             '<(PRODUCT_DIR)/crash_inspector',
688                             '<(PRODUCT_DIR)/crash_report_sender.app'
689                           ],
690                         },
691                       ],
692                       'dependencies': [
693                         '../breakpad/breakpad.gyp:dump_syms',
694                       ],
695                       'postbuilds': [
696                         {
697                           'postbuild_name': 'Dump Symbols',
698                           'variables': {
699                             'dump_product_syms_path':
700                             'scripts/mac/dump_product_syms',
701                           },
702                           'action': [
703                             '<(dump_product_syms_path)',
704                             '<(version_full)',
705                           ],
706                         },  # end of postbuild 'dump_symbols'
707                       ],  # end of 'postbuilds'
708                     }],  # mac_breakpad==1
709                   ],  # conditions
710                 }],  # OS=mac
711               ],  # end of conditions
712             },  # end of target 'remoting_it2me_native_messaging_host'
713           ],  # targets
714         }, {  # chromeos==0
715           'targets': [
716             {
717               # Dummy target for chromeos==1
718               'target_name': 'remoting_it2me_native_messaging_host',
719               'type': 'executable',
720             },
721           ],  # targets
722         }],  # end of chromeos==0
723       ],  # end of conditions
724     }],  # end of OS!="win" and enable_remoting_host==1
725   ],  # end of 'conditions'