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.
7 'remoting_enable.gypi',
13 'remoting_host_mac.gypi',
18 'remoting_host_win.gypi',
23 'remoting_host_linux.gypi',
27 ['enable_remoting_host==1', {
30 # GN version: //remoting/host
31 'target_name': 'remoting_host',
32 'type': 'static_library',
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@")',
40 'remoting_host_credits',
43 '../base/base.gyp:base_i18n',
44 '../components/components.gyp:policy',
45 '../components/components.gyp:policy_component_common',
46 '../crypto/crypto.gyp:crypto',
47 '../google_apis/google_apis.gyp:google_apis',
49 '../ui/events/events.gyp:dom_keycode_converter',
52 'HOST_BUNDLE_NAME="<(host_bundle_name)"',
53 'PREFPANE_BUNDLE_NAME="<(prefpane_bundle_name)"',
54 'VERSION=<(version_full)',
57 '<@(remoting_host_sources)',
64 '../build/linux/system.gyp:x11',
65 '../build/linux/system.gyp:xext',
66 '../build/linux/system.gyp:xfixes',
67 '../build/linux/system.gyp:xi',
68 '../build/linux/system.gyp:xrandr',
69 '../build/linux/system.gyp:xtst',
72 ['chromeos==0 and use_ozone==0', {
74 # use GTK on Linux, even for Aura builds.
75 '../build/linux/system.gyp:gtk',
83 '../gpu/gpu.gyp:command_buffer_common',
84 '../ppapi/ppapi_internal.gyp:ppapi_host',
85 '../skia/skia.gyp:skia',
86 '../ui/aura/aura.gyp:aura',
87 '../ui/compositor/compositor.gyp:compositor',
88 '../ui/events/events.gyp:events',
89 '../ui/events/platform/events_platform.gyp:events_platform',
90 '../ui/views/views.gyp:views',
93 '../third_party/skia/include/utils',
96 'host/clipboard_x11.cc',
97 'host/continue_window_linux.cc',
98 'host/disconnect_window_linux.cc',
99 'host/linux/x_server_clipboard.cc',
100 'host/linux/x_server_clipboard.h',
101 'host/local_input_monitor_x11.cc',
106 '../ash/ash.gyp:ash',
111 'host/input_injector_chromeos.cc',
112 'host/input_injector_chromeos.h',
116 '../ui/ozone/ozone.gyp:ozone',
123 '../third_party/google_toolbox_for_mac/google_toolbox_for_mac.gyp:google_toolbox_for_mac',
127 '$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
133 '_ATL_NO_EXCEPTIONS',
134 'ISOLATION_AWARE_ENABLED=1',
137 '../sandbox/sandbox.gyp:sandbox',
138 'remoting_host_messages',
142 'VCCLCompilerTool': {
143 # /MP conflicts with #import directive so we limit the number
144 # of processes to spawn to 1.
145 'AdditionalOptions': ['/MP1'],
149 'output_dir': '<(SHARED_INTERMEDIATE_DIR)/remoting/host',
152 '<(output_dir)/remoting_host_messages.mc',
157 'direct_dependent_settings': {
163 # Rule to run the message compiler.
164 'rule_name': 'message_compiler',
167 '<(output_dir)/<(RULE_INPUT_ROOT).h',
168 '<(output_dir)/<(RULE_INPUT_ROOT).rc',
172 '-h', '<(output_dir)',
173 '-r', '<(output_dir)/.',
175 '<(RULE_INPUT_PATH)',
177 'process_outputs_as_sources': 1,
178 'message': 'Running message compiler on <(RULE_INPUT_PATH)',
181 ['enable_webrtc==1', {
183 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
184 '../third_party/libjingle/libjingle.gyp:libpeerconnection',
187 '<@(remoting_cast_sources)',
191 }, # end of target 'remoting_host'
194 # GN version: //remoting/host:credits
195 'target_name': 'remoting_host_credits',
199 'action_name': 'Build remoting host credits',
201 '../tools/licenses.py',
202 'host/installer/credits.tmpl',
203 'host/installer/credits_entry.tmpl',
206 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
208 'hard_dependency': 1,
210 '../tools/licenses.py',
212 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
213 '--file-template', 'host/installer/credits.tmpl',
214 '--entry-template', 'host/installer/credits_entry.tmpl',
221 # GN version: //remoting/host/native_messaging
222 'target_name': 'remoting_native_messaging_base',
223 'type': 'static_library',
224 'variables': { 'enable_wexit_time_destructors': 1, },
226 '../base/base.gyp:base',
229 '<@(remoting_host_native_messaging_sources)',
231 }, # end of target 'remoting_native_messaging_base'
234 # GN version: //remoting/host/setup
235 'target_name': 'remoting_host_setup_base',
236 'type': 'static_library',
237 'variables': { 'enable_wexit_time_destructors': 1, },
239 '../base/base.gyp:base',
240 '../google_apis/google_apis.gyp:google_apis',
244 'VERSION=<(version_full)',
247 '<@(remoting_host_setup_sources)',
254 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
255 'msvs_disabled_warnings': [4267, ],
258 }, # end of target 'remoting_host_setup_base'
260 # Generates native messaging manifest files.
262 'target_name': 'remoting_native_messaging_manifests',
267 'me2me_host_path': 'remoting_native_messaging_host.exe',
268 'it2me_host_path': 'remote_assistance_host.exe',
273 'me2me_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
274 'native_messaging_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_NAME@")',
275 'remote_assistance_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_NAME@")',
277 '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(native_messaging_host_bundle_name)/Contents/MacOS/native_messaging_host',
279 '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(remote_assistance_host_bundle_name)/Contents/MacOS/remote_assistance_host',
282 [ 'OS != "mac" and OS != "win"', {
285 '/opt/google/chrome-remote-desktop/native-messaging-host',
287 '/opt/google/chrome-remote-desktop/remote-assistance-host',
292 'host/it2me/com.google.chrome.remote_assistance.json.jinja2',
293 'host/setup/com.google.chrome.remote_desktop.json.jinja2',
296 'rule_name': 'generate_manifest',
297 'extension': 'jinja2',
299 '<(remoting_localize_path)',
303 '<(PRODUCT_DIR)/remoting/<(RULE_INPUT_ROOT)',
306 'python', '<(remoting_localize_path)',
307 '--define', 'ME2ME_HOST_PATH=<(me2me_host_path)',
308 '--define', 'IT2ME_HOST_PATH=<(it2me_host_path)',
309 '--variables', '<(branding_path)',
310 '--template', '<(RULE_INPUT_PATH)',
311 '--locale_output', '<@(_outputs)',
315 }, # end of target 'remoting_native_messaging_manifests'
317 # GN target: //remoting/host:remoting_start_host
318 'target_name': 'remoting_start_host',
319 'type': 'executable',
321 'remoting_host_setup_base',
324 'host/setup/host_starter.cc',
325 'host/setup/host_starter.h',
326 'host/setup/start_host.cc',
329 ['OS=="linux" and use_allocator!="none"', {
331 '../base/allocator/allocator.gyp:allocator',
335 }, # end of target 'remoting_start_host'
337 'target_name': 'remoting_infoplist_strings',
340 'remoting_resources',
343 'host/remoting_me2me_host-InfoPlist.strings.jinja2',
344 'host/mac/me2me_preference_pane-InfoPlist.strings.jinja2',
345 'host/installer/mac/uninstaller/remoting_uninstaller-InfoPlist.strings.jinja2',
346 'host/setup/native_messaging_host-InfoPlist.strings.jinja2',
347 'host/it2me/remote_assistance_host-InfoPlist.strings.jinja2',
350 'rule_name': 'generate_strings',
351 'extension': 'jinja2',
353 '<(remoting_localize_path)',
356 '<!@pymod_do_main(remoting_localize --locale_output '
357 '"<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings" '
358 '--print_only <(remoting_locales))',
361 'python', '<(remoting_localize_path)',
362 '--locale_dir', '<(webapp_locale_dir)',
363 '--template', '<(RULE_INPUT_PATH)',
365 '<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings',
366 '<@(remoting_locales)',
369 }, # end of target 'remoting_infoplist_strings'
371 # GN version: //remoting/host/it2me:common
372 'target_name': 'remoting_it2me_host_static',
373 'type': 'static_library',
374 'variables': { 'enable_wexit_time_destructors': 1, },
376 '../base/base.gyp:base_i18n',
377 '../components/components.gyp:policy',
378 '../net/net.gyp:net',
381 'remoting_infoplist_strings',
383 'remoting_resources',
386 'VERSION=<(version_full)',
389 '<@(remoting_it2me_host_static_sources)',
391 }, # end of target 'remoting_it2me_host_static'
392 ], # end of 'targets'
393 }], # 'enable_remoting_host==1'
395 ['enable_me2me_host==1', {
398 'target_name': 'remoting_me2me_host_static',
399 'type': 'static_library',
400 'variables': { 'enable_wexit_time_destructors': 1, },
402 '../base/base.gyp:base',
403 '../base/base.gyp:base_i18n',
404 '../components/components.gyp:policy',
405 '../components/components.gyp:policy_component_common',
406 '../net/net.gyp:net',
407 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
414 'VERSION=<(version_full)',
417 'host/curtain_mode.h',
418 'host/curtain_mode_linux.cc',
419 'host/curtain_mode_mac.cc',
420 'host/curtain_mode_win.cc',
421 'host/pam_authorization_factory_posix.cc',
422 'host/pam_authorization_factory_posix.h',
423 'host/posix/signal_handler.cc',
424 'host/posix/signal_handler.h',
425 'host/remoting_me2me_host.cc',
442 ['OS=="mac" and buildtype=="Official"', {
444 'internal/internal_mac-inl.h'
447 'USE_REMOTING_MACOSX_INTERNAL'
450 ], # end of 'conditions'
451 }, # end of target 'remoting_me2me_host_static'
453 }], # end of enable_me2me_host==1
455 ['OS!="win" and enable_me2me_host==1', {
458 'target_name': 'remoting_me2me_host',
459 'type': 'executable',
460 'variables': { 'enable_wexit_time_destructors': 1, },
462 '../base/base.gyp:base',
463 '../base/base.gyp:base_i18n',
464 '<(icu_gyp_path):icudata',
465 '../net/net.gyp:net',
466 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
470 'remoting_infoplist_strings',
471 'remoting_me2me_host_static',
475 'VERSION=<(version_full)',
485 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_ID@")',
488 'INFOPLIST_FILE': 'host/remoting_me2me_host-Info.plist',
489 'INFOPLIST_PREPROCESS': 'YES',
490 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
492 'mac_bundle_resources': [
493 '<(PRODUCT_DIR)/icudtl.dat',
494 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
495 'host/disconnect_window.xib',
496 'host/remoting_me2me_host.icns',
497 'host/remoting_me2me_host-Info.plist',
498 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
500 # Localized strings for 'Info.plist'
501 '<!@pymod_do_main(remoting_localize --locale_output '
502 '"<(SHARED_INTERMEDIATE_DIR)/remoting/remoting_me2me_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
503 '--print_only <(remoting_locales))',
505 'mac_bundle_resources!': [
506 'host/remoting_me2me_host-Info.plist',
509 ['mac_breakpad==1', {
511 # A real .dSYM is needed for dump_syms to operate on.
516 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
518 '<(PRODUCT_DIR)/crash_inspector',
519 '<(PRODUCT_DIR)/crash_report_sender.app'
524 '../breakpad/breakpad.gyp:dump_syms',
528 'postbuild_name': 'Dump Symbols',
530 'dump_product_syms_path':
531 'scripts/mac/dump_product_syms',
534 '<(dump_product_syms_path)',
537 }, # end of postbuild 'dump_symbols'
538 ], # end of 'postbuilds'
539 }], # mac_breakpad==1
542 ['OS=="linux" and use_allocator!="none"', {
544 '../base/allocator/allocator.gyp:allocator',
547 ], # end of 'conditions'
548 }, # end of target 'remoting_me2me_host'
550 'target_name': 'remoting_me2me_native_messaging_host',
551 'type': 'executable',
552 'product_name': 'native_messaging_host',
553 'variables': { 'enable_wexit_time_destructors': 1, },
555 '../base/base.gyp:base',
558 'remoting_host_setup_base',
559 'remoting_infoplist_strings',
560 'remoting_native_messaging_base',
563 'VERSION=<(version_full)',
566 'host/setup/me2me_native_messaging_host_entry_point.cc',
567 'host/setup/me2me_native_messaging_host_main.cc',
568 'host/setup/me2me_native_messaging_host_main.h',
571 ['OS=="linux" and use_allocator!="none"', {
573 '../base/allocator/allocator.gyp:allocator',
579 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_ID@")',
582 'INFOPLIST_FILE': 'host/setup/native_messaging_host-Info.plist',
583 'INFOPLIST_PREPROCESS': 'YES',
584 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
586 'mac_bundle_resources': [
587 'host/setup/native_messaging_host-Info.plist',
588 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
590 # Localized strings for 'Info.plist'
591 '<!@pymod_do_main(remoting_localize --locale_output '
592 '"<(SHARED_INTERMEDIATE_DIR)/remoting/native_messaging_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
593 '--print_only <(remoting_locales))',
595 'mac_bundle_resources!': [
596 'host/setup/native_messaging_host-Info.plist',
599 ['mac_breakpad==1', {
601 # A real .dSYM is needed for dump_syms to operate on.
606 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
608 '<(PRODUCT_DIR)/crash_inspector',
609 '<(PRODUCT_DIR)/crash_report_sender.app'
614 '../breakpad/breakpad.gyp:dump_syms',
618 'postbuild_name': 'Dump Symbols',
620 'dump_product_syms_path':
621 'scripts/mac/dump_product_syms',
624 '<(dump_product_syms_path)',
627 }, # end of postbuild 'dump_symbols'
628 ], # end of 'postbuilds'
629 }], # mac_breakpad==1
633 }, # end of target 'remoting_me2me_native_messaging_host'
635 }], # end of OS!="win" and enable_me2me_host==1
637 ['OS!="win" and enable_remoting_host==1', {
642 'target_name': 'remoting_it2me_native_messaging_host',
643 'type': 'executable',
644 'product_name': 'remote_assistance_host',
645 'variables': { 'enable_wexit_time_destructors': 1, },
647 '../base/base.gyp:base',
651 'remoting_it2me_host_static',
652 'remoting_native_messaging_base',
656 'VERSION=<(version_full)',
659 'host/it2me/it2me_native_messaging_host_entry_point.cc',
660 'host/it2me/it2me_native_messaging_host_main.cc',
661 'host/it2me/it2me_native_messaging_host_main.h',
664 ['OS=="linux" and chromeos==0 and use_ozone==0', {
666 # Always use GTK on Linux, even for Aura builds.
667 '../build/linux/system.gyp:gtk',
670 ['OS=="linux" and use_allocator!="none"', {
672 '../base/allocator/allocator.gyp:allocator',
678 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_ID@")',
681 'INFOPLIST_FILE': 'host/it2me/remote_assistance_host-Info.plist',
682 'INFOPLIST_PREPROCESS': 'YES',
683 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
685 'mac_bundle_resources': [
686 '<(PRODUCT_DIR)/icudtl.dat',
687 'host/disconnect_window.xib',
688 'host/it2me/remote_assistance_host-Info.plist',
689 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
691 # Localized strings for 'Info.plist'
692 '<!@pymod_do_main(remoting_localize --locale_output '
693 '"<(SHARED_INTERMEDIATE_DIR)/remoting/remote_assistance_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
694 '--print_only <(remoting_locales))',
696 'mac_bundle_resources!': [
697 'host/it2me/remote_assistance_host-Info.plist',
700 ['mac_breakpad==1', {
702 # A real .dSYM is needed for dump_syms to operate on.
707 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
709 '<(PRODUCT_DIR)/crash_inspector',
710 '<(PRODUCT_DIR)/crash_report_sender.app'
715 '../breakpad/breakpad.gyp:dump_syms',
719 'postbuild_name': 'Dump Symbols',
721 'dump_product_syms_path':
722 'scripts/mac/dump_product_syms',
725 '<(dump_product_syms_path)',
728 }, # end of postbuild 'dump_symbols'
729 ], # end of 'postbuilds'
730 }], # mac_breakpad==1
733 ], # end of conditions
734 }, # end of target 'remoting_it2me_native_messaging_host'
739 # Dummy target for chromeos==1
740 'target_name': 'remoting_it2me_native_messaging_host',
741 'type': 'executable',
744 }], # end of chromeos==0
745 ], # end of conditions
746 }], # end of OS!="win" and enable_remoting_host==1
747 ], # end of 'conditions'