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:gtk2',
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)',
190 ['remoting_use_gcd==1', {
196 }, # end of target 'remoting_host'
199 # GN version: //remoting/host:credits
200 'target_name': 'remoting_host_credits',
204 'action_name': 'Build remoting host credits',
206 '../tools/licenses.py',
207 'host/installer/credits.tmpl',
208 'host/installer/credits_entry.tmpl',
211 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
213 'hard_dependency': 1,
215 '../tools/licenses.py',
217 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
218 '--file-template', 'host/installer/credits.tmpl',
219 '--entry-template', 'host/installer/credits_entry.tmpl',
226 # GN version: //remoting/host/native_messaging
227 'target_name': 'remoting_native_messaging_base',
228 'type': 'static_library',
229 'variables': { 'enable_wexit_time_destructors': 1, },
231 '../base/base.gyp:base',
234 '<@(remoting_host_native_messaging_sources)',
236 }, # end of target 'remoting_native_messaging_base'
239 # GN version: //remoting/host/setup
240 'target_name': 'remoting_host_setup_base',
241 'type': 'static_library',
242 'variables': { 'enable_wexit_time_destructors': 1, },
244 '../base/base.gyp:base',
245 '../google_apis/google_apis.gyp:google_apis',
249 'VERSION=<(version_full)',
252 '<@(remoting_host_setup_sources)',
259 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
260 'msvs_disabled_warnings': [4267, ],
263 }, # end of target 'remoting_host_setup_base'
265 # Generates native messaging manifest files.
267 'target_name': 'remoting_native_messaging_manifests',
272 'me2me_host_path': 'remoting_native_messaging_host.exe',
273 'it2me_host_path': 'remote_assistance_host.exe',
278 'me2me_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_NAME@")',
279 'native_messaging_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_NAME@")',
280 'remote_assistance_host_bundle_name': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_NAME@")',
282 '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(native_messaging_host_bundle_name)/Contents/MacOS/native_messaging_host',
284 '/Library/PrivilegedHelperTools/<(me2me_host_bundle_name)/Contents/MacOS/<(remote_assistance_host_bundle_name)/Contents/MacOS/remote_assistance_host',
287 [ 'OS != "mac" and OS != "win"', {
290 '/opt/google/chrome-remote-desktop/native-messaging-host',
292 '/opt/google/chrome-remote-desktop/remote-assistance-host',
297 'host/it2me/com.google.chrome.remote_assistance.json.jinja2',
298 'host/setup/com.google.chrome.remote_desktop.json.jinja2',
301 'rule_name': 'generate_manifest',
302 'extension': 'jinja2',
304 '<(remoting_localize_path)',
308 '<(PRODUCT_DIR)/remoting/<(RULE_INPUT_ROOT)',
311 'python', '<(remoting_localize_path)',
312 '--define', 'ME2ME_HOST_PATH=<(me2me_host_path)',
313 '--define', 'IT2ME_HOST_PATH=<(it2me_host_path)',
314 '--variables', '<(branding_path)',
315 '--template', '<(RULE_INPUT_PATH)',
316 '--locale_output', '<@(_outputs)',
320 }, # end of target 'remoting_native_messaging_manifests'
322 # GN target: //remoting/host:remoting_start_host
323 'target_name': 'remoting_start_host',
324 'type': 'executable',
326 'remoting_host_setup_base',
329 'host/setup/host_starter.cc',
330 'host/setup/host_starter.h',
331 'host/setup/start_host.cc',
334 ['OS=="linux" and use_allocator!="none"', {
336 '../base/allocator/allocator.gyp:allocator',
340 }, # end of target 'remoting_start_host'
342 'target_name': 'remoting_infoplist_strings',
345 'remoting_resources',
348 'host/remoting_me2me_host-InfoPlist.strings.jinja2',
349 'host/mac/me2me_preference_pane-InfoPlist.strings.jinja2',
350 'host/installer/mac/uninstaller/remoting_uninstaller-InfoPlist.strings.jinja2',
351 'host/setup/native_messaging_host-InfoPlist.strings.jinja2',
352 'host/it2me/remote_assistance_host-InfoPlist.strings.jinja2',
355 'rule_name': 'generate_strings',
356 'extension': 'jinja2',
358 '<(remoting_localize_path)',
361 '<!@pymod_do_main(remoting_localize --locale_output '
362 '"<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings" '
363 '--print_only <(remoting_locales))',
366 'python', '<(remoting_localize_path)',
367 '--locale_dir', '<(webapp_locale_dir)',
368 '--template', '<(RULE_INPUT_PATH)',
370 '<(SHARED_INTERMEDIATE_DIR)/remoting/<(RULE_INPUT_ROOT)/@{json_suffix}.lproj/InfoPlist.strings',
371 '<@(remoting_locales)',
374 }, # end of target 'remoting_infoplist_strings'
376 # GN version: //remoting/host/it2me:common
377 'target_name': 'remoting_it2me_host_static',
378 'type': 'static_library',
379 'variables': { 'enable_wexit_time_destructors': 1, },
381 '../base/base.gyp:base_i18n',
382 '../components/components.gyp:policy',
383 '../net/net.gyp:net',
386 'remoting_infoplist_strings',
388 'remoting_resources',
391 'VERSION=<(version_full)',
394 '<@(remoting_it2me_host_static_sources)',
396 }, # end of target 'remoting_it2me_host_static'
397 ], # end of 'targets'
398 }], # 'enable_remoting_host==1'
400 ['enable_me2me_host==1', {
403 'target_name': 'remoting_me2me_host_static',
404 'type': 'static_library',
405 'variables': { 'enable_wexit_time_destructors': 1, },
407 '../base/base.gyp:base',
408 '../base/base.gyp:base_i18n',
409 '../components/components.gyp:policy',
410 '../components/components.gyp:policy_component_common',
411 '../net/net.gyp:net',
412 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
419 'VERSION=<(version_full)',
422 'host/curtain_mode.h',
423 'host/curtain_mode_linux.cc',
424 'host/curtain_mode_mac.cc',
425 'host/curtain_mode_win.cc',
426 'host/pam_authorization_factory_posix.cc',
427 'host/pam_authorization_factory_posix.h',
428 'host/posix/signal_handler.cc',
429 'host/posix/signal_handler.h',
430 'host/remoting_me2me_host.cc',
447 ['OS=="mac" and buildtype=="Official"', {
449 'internal/internal_mac-inl.h'
452 'USE_REMOTING_MACOSX_INTERNAL'
455 ['remoting_use_gcd==1', {
460 ], # end of 'conditions'
461 }, # end of target 'remoting_me2me_host_static'
463 }], # end of enable_me2me_host==1
465 ['OS!="win" and enable_me2me_host==1', {
468 'target_name': 'remoting_me2me_host',
469 'type': 'executable',
470 'variables': { 'enable_wexit_time_destructors': 1, },
472 '../base/base.gyp:base',
473 '../base/base.gyp:base_i18n',
474 '<(icu_gyp_path):icudata',
475 '../net/net.gyp:net',
476 '../third_party/webrtc/modules/modules.gyp:desktop_capture',
480 'remoting_infoplist_strings',
481 'remoting_me2me_host_static',
485 'VERSION=<(version_full)',
495 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_HOST_BUNDLE_ID@")',
498 'INFOPLIST_FILE': 'host/remoting_me2me_host-Info.plist',
499 'INFOPLIST_PREPROCESS': 'YES',
500 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
502 'mac_bundle_resources': [
503 '<(PRODUCT_DIR)/icudtl.dat',
504 '<(SHARED_INTERMEDIATE_DIR)/remoting/CREDITS.txt',
505 'host/disconnect_window.xib',
506 'host/remoting_me2me_host.icns',
507 'host/remoting_me2me_host-Info.plist',
508 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
510 # Localized strings for 'Info.plist'
511 '<!@pymod_do_main(remoting_localize --locale_output '
512 '"<(SHARED_INTERMEDIATE_DIR)/remoting/remoting_me2me_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
513 '--print_only <(remoting_locales))',
515 'mac_bundle_resources!': [
516 'host/remoting_me2me_host-Info.plist',
519 ['mac_breakpad==1', {
521 # A real .dSYM is needed for dump_syms to operate on.
526 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
528 '<(PRODUCT_DIR)/crash_inspector',
529 '<(PRODUCT_DIR)/crash_report_sender.app'
534 '../breakpad/breakpad.gyp:dump_syms',
538 'postbuild_name': 'Dump Symbols',
540 'dump_product_syms_path':
541 'scripts/mac/dump_product_syms',
544 '<(dump_product_syms_path)',
547 }, # end of postbuild 'dump_symbols'
548 ], # end of 'postbuilds'
549 }], # mac_breakpad==1
552 ['OS=="linux" and use_allocator!="none"', {
554 '../base/allocator/allocator.gyp:allocator',
557 ], # end of 'conditions'
558 }, # end of target 'remoting_me2me_host'
560 'target_name': 'remoting_me2me_native_messaging_host',
561 'type': 'executable',
562 'product_name': 'native_messaging_host',
563 'variables': { 'enable_wexit_time_destructors': 1, },
565 '../base/base.gyp:base',
568 'remoting_host_setup_base',
569 'remoting_infoplist_strings',
570 'remoting_native_messaging_base',
573 'VERSION=<(version_full)',
576 'host/setup/me2me_native_messaging_host_entry_point.cc',
577 'host/setup/me2me_native_messaging_host_main.cc',
578 'host/setup/me2me_native_messaging_host_main.h',
581 ['OS=="linux" and use_allocator!="none"', {
583 '../base/allocator/allocator.gyp:allocator',
589 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_NATIVE_MESSAGING_HOST_BUNDLE_ID@")',
592 'INFOPLIST_FILE': 'host/setup/native_messaging_host-Info.plist',
593 'INFOPLIST_PREPROCESS': 'YES',
594 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
596 'mac_bundle_resources': [
597 'host/setup/native_messaging_host-Info.plist',
598 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
600 # Localized strings for 'Info.plist'
601 '<!@pymod_do_main(remoting_localize --locale_output '
602 '"<(SHARED_INTERMEDIATE_DIR)/remoting/native_messaging_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
603 '--print_only <(remoting_locales))',
605 'mac_bundle_resources!': [
606 'host/setup/native_messaging_host-Info.plist',
609 ['mac_breakpad==1', {
611 # A real .dSYM is needed for dump_syms to operate on.
616 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
618 '<(PRODUCT_DIR)/crash_inspector',
619 '<(PRODUCT_DIR)/crash_report_sender.app'
624 '../breakpad/breakpad.gyp:dump_syms',
628 'postbuild_name': 'Dump Symbols',
630 'dump_product_syms_path':
631 'scripts/mac/dump_product_syms',
634 '<(dump_product_syms_path)',
637 }, # end of postbuild 'dump_symbols'
638 ], # end of 'postbuilds'
639 }], # mac_breakpad==1
643 }, # end of target 'remoting_me2me_native_messaging_host'
645 }], # end of OS!="win" and enable_me2me_host==1
647 ['OS!="win" and enable_remoting_host==1', {
652 'target_name': 'remoting_it2me_native_messaging_host',
653 'type': 'executable',
654 'product_name': 'remote_assistance_host',
655 'variables': { 'enable_wexit_time_destructors': 1, },
657 '../base/base.gyp:base',
661 'remoting_it2me_host_static',
662 'remoting_native_messaging_base',
666 'VERSION=<(version_full)',
669 'host/it2me/it2me_native_messaging_host_entry_point.cc',
670 'host/it2me/it2me_native_messaging_host_main.cc',
671 'host/it2me/it2me_native_messaging_host_main.h',
674 ['OS=="linux" and chromeos==0 and use_ozone==0', {
676 # Always use GTK on Linux, even for Aura builds.
677 '../build/linux/system.gyp:gtk2',
680 ['OS=="linux" and use_allocator!="none"', {
682 '../base/allocator/allocator.gyp:allocator',
688 'host_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_REMOTE_ASSISTANCE_HOST_BUNDLE_ID@")',
691 'INFOPLIST_FILE': 'host/it2me/remote_assistance_host-Info.plist',
692 'INFOPLIST_PREPROCESS': 'YES',
693 'INFOPLIST_PREPROCESSOR_DEFINITIONS': 'VERSION_FULL="<(version_full)" VERSION_SHORT="<(version_short)" BUNDLE_ID="<(host_bundle_id)"',
695 'mac_bundle_resources': [
696 '<(PRODUCT_DIR)/icudtl.dat',
697 'host/disconnect_window.xib',
698 'host/it2me/remote_assistance_host-Info.plist',
699 '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(PRODUCT_DIR) <(remoting_locales))',
701 # Localized strings for 'Info.plist'
702 '<!@pymod_do_main(remoting_localize --locale_output '
703 '"<(SHARED_INTERMEDIATE_DIR)/remoting/remote_assistance_host-InfoPlist.strings/@{json_suffix}.lproj/InfoPlist.strings" '
704 '--print_only <(remoting_locales))',
706 'mac_bundle_resources!': [
707 'host/it2me/remote_assistance_host-Info.plist',
710 ['mac_breakpad==1', {
712 # A real .dSYM is needed for dump_syms to operate on.
717 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
719 '<(PRODUCT_DIR)/crash_inspector',
720 '<(PRODUCT_DIR)/crash_report_sender.app'
725 '../breakpad/breakpad.gyp:dump_syms',
729 'postbuild_name': 'Dump Symbols',
731 'dump_product_syms_path':
732 'scripts/mac/dump_product_syms',
735 '<(dump_product_syms_path)',
738 }, # end of postbuild 'dump_symbols'
739 ], # end of 'postbuilds'
740 }], # mac_breakpad==1
743 ], # end of conditions
744 }, # end of target 'remoting_it2me_native_messaging_host'
749 # Dummy target for chromeos==1
750 'target_name': 'remoting_it2me_native_messaging_host',
751 'type': 'executable',
754 }], # end of chromeos==0
755 ], # end of conditions
756 }], # end of OS!="win" and enable_remoting_host==1
757 ], # end of 'conditions'