[android] Generated password saved infobar.
[chromium-blink-merge.git] / remoting / remoting.gyp
blobc693083d91329b13bccabe3ee1b8eaed3e78c2fe
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   'variables': {
7     'chromium_code': 1,
9     # Set this to run the jscompile checks after building the webapp.
10     'run_jscompile%': 0,
12     # Set this to enable cast mode on the android client.
13     'enable_cast%': 0,
15     'variables': {
16       'conditions': [
17         # Enable the multi-process host on Windows by default.
18         ['OS=="win"', {
19           'remoting_multi_process%': 1,
20         }, {
21           'remoting_multi_process%': 0,
22         }],
23       ],
24     },
26     'remoting_multi_process%': '<(remoting_multi_process)',
27     'remoting_rdp_session%': 1,
29     'remoting_localize_path': 'tools/build/remoting_localize.py',
31     'branding_path': '../remoting/branding_<(branding)',
33     'webapp_locale_dir': '<(SHARED_INTERMEDIATE_DIR)/remoting/webapp/_locales',
35     'conditions': [
36       ['OS=="mac"', {
37         'mac_bundle_id': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_BUNDLE_ID@")',
38         'mac_creator': '<!(python <(version_py_path) -f <(branding_path) -t "@MAC_CREATOR@")',
39       }],
40       ['OS=="win"', {
41         # Each CLSID is a hash of the current version string salted with an
42         # arbitrary GUID. This ensures that the newly installed COM classes will
43         # be used during/after upgrade even if there are old instances running
44         # already.
45         # The IDs are not random to avoid rebuilding host when it's not
46         # necessary.
47         'daemon_controller_clsid':
48             '<!(python -c "import uuid; print uuid.uuid5(uuid.UUID(\'655bd819-c08c-4b04-80c2-f160739ff6ef\'), \'<(version_full)\')")',
49         'rdp_desktop_session_clsid':
50             '<!(python -c "import uuid; print uuid.uuid5(uuid.UUID(\'6a7699f0-ee43-43e7-aa30-a6738f9bd470\'), \'<(version_full)\')")',
51       }],
52     ],
53     'remoting_locales': [
54       # Note: list duplicated in GN build. See //remoting/resources/BUILD.gn
55       'ar', 'bg', 'ca', 'cs', 'da', 'de', 'el', 'en', 'en-GB', 'es',
56       'es-419', 'et', 'fi', 'fil', 'fr', 'he', 'hi', 'hr', 'hu', 'id',
57       'it', 'ja', 'ko', 'lt', 'lv', 'nb', 'nl', 'pl', 'pt-BR', 'pt-PT',
58       'ro', 'ru', 'sk', 'sl', 'sr', 'sv', 'th', 'tr', 'uk', 'vi',
59       'zh-CN', 'zh-TW',
60     ],
61     'remoting_host_locale_files': [
62       # Build the list of .pak files generated from remoting_strings.grd.
63       '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x '
64           '<(PRODUCT_DIR) <(remoting_locales))',
65     ],
66     'remoting_webapp_locale_files': [
67       # Build the list of .json files generated from remoting_strings.grd.
68       '<!@pymod_do_main(remoting_localize --locale_output '
69           '"<(webapp_locale_dir)/@{json_suffix}/messages.json" '
70           '--print_only <(remoting_locales))',
71     ],
72   },
74   'includes': [
75     '../chrome/js_unittest_vars.gypi',
76     'remoting_android.gypi',
77     'remoting_client.gypi',
78     'remoting_host.gypi',
79     'remoting_srcs.gypi',
80     'remoting_test.gypi',
81     'remoting_version.gypi',
82     'remoting_webapp_files.gypi',
83   ],
85   'target_defaults': {
86     'defines': [
87       'BINARY_CORE=1',
88       'BINARY_DESKTOP=2',
89       'BINARY_HOST_ME2ME=3',
90       'BINARY_NATIVE_MESSAGING_HOST=4',
91       'BINARY_REMOTE_ASSISTANCE_HOST=5',
92     ],
93     'include_dirs': [
94       '..',  # Root of Chrome checkout
95     ],
96     'variables': {
97       'win_debug_RuntimeChecks': '0',
98     },
99     'conditions': [
100       ['OS=="mac" and mac_breakpad==1', {
101         'defines': [
102           'REMOTING_ENABLE_BREAKPAD'
103         ],
104       }],
105       ['OS=="win" and buildtype == "Official"', {
106         'defines': [
107           'REMOTING_ENABLE_BREAKPAD'
108         ],
109       }],
110       ['OS=="win" and remoting_multi_process != 0 and \
111           remoting_rdp_session != 0', {
112         'defines': [
113           'REMOTING_RDP_SESSION',
114         ],
115       }],
116       ['remoting_multi_process != 0', {
117         'defines': [
118           'REMOTING_MULTI_PROCESS',
119         ],
120       }],
121     ],
122   },
124   'targets': [
125     {
126       'target_name': 'remoting_breakpad',
127       'type': 'static_library',
128       'variables': { 'enable_wexit_time_destructors': 1, },
129       'dependencies': [
130         '../base/base.gyp:base',
131       ],
132       'sources': [
133         'base/breakpad.h',
134         'base/breakpad_linux.cc',
135         'base/breakpad_mac.mm',
136         'base/breakpad_win.cc',
137       ],
138       'conditions': [
139         ['OS=="mac"', {
140           'dependencies': [
141             '../breakpad/breakpad.gyp:breakpad',
142           ],
143         }],
144         ['OS=="win"', {
145           'dependencies': [
146             '../breakpad/breakpad.gyp:breakpad_handler',
147           ],
148         }],
149       ],
150     },  # end of target 'remoting_breakpad'
152     {
153       # GN version: //remoting/resources
154       'target_name': 'remoting_resources',
155       'type': 'none',
156       'dependencies': [
157         'remoting_webapp_html',
158       ],
159       'variables': {
160         'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)',
161         'sources': [
162           '<(SHARED_INTERMEDIATE_DIR)/main.html',
163           'base/resources_unittest.cc',
164           'host/continue_window_mac.mm',
165           'host/disconnect_window_mac.mm',
166           'host/installer/mac/uninstaller/remoting_uninstaller-InfoPlist.strings.jinja2',
167           'host/mac/me2me_preference_pane-InfoPlist.strings.jinja2',
168           'host/win/core.rc.jinja2',
169           'host/win/host_messages.mc.jinja2',
170           'host/win/version.rc.jinja2',
171           'resources/play_store_resources.cc',
172           'webapp/crd/manifest.json.jinja2',
173           '<@(remoting_webapp_all_js_files)',
174         ],
175       },
176       'actions': [
177         {
178           # GN version: //remoting/resources:verify_resources
179           'action_name': 'verify_resources',
180           'inputs': [
181             'resources/remoting_strings.grd',
182             'tools/verify_resources.py',
183             '<@(sources)'
184           ],
185           'outputs': [
186             '<(PRODUCT_DIR)/remoting_resources_verified.stamp',
187           ],
188           'action': [
189             'python',
190             'tools/verify_resources.py',
191             '-t', '<(PRODUCT_DIR)/remoting_resources_verified.stamp',
192             '-r', 'resources/remoting_strings.grd',
193             '<@(sources)',
194          ],
195         },
196         {
197           # GN version: //remoting/resources:strings
198           'action_name': 'remoting_strings',
199           'variables': {
200             'grit_grd_file': 'resources/remoting_strings.grd',
201           },
202           'includes': [ '../build/grit_action.gypi' ],
203         },
204         {
205           # GN version: //remoting/resources:copy_locales
206           'action_name': 'copy_locales',
207           'variables': {
208             'copy_output_dir%': '<(PRODUCT_DIR)',
209           },
210           'inputs': [
211             'tools/build/remoting_copy_locales.py',
212             '<!@pymod_do_main(remoting_copy_locales -i -p <(OS) -g <(grit_out_dir) <(remoting_locales))'
213           ],
214           'outputs': [
215             '<!@pymod_do_main(remoting_copy_locales -o -p <(OS) -x <(copy_output_dir) <(remoting_locales))'
216           ],
217           'action': [
218             'python', 'tools/build/remoting_copy_locales.py',
219             '-p', '<(OS)',
220             '-g', '<(grit_out_dir)',
221             '-x', '<(copy_output_dir)/.',
222             '<@(remoting_locales)',
223           ],
224         }
225       ],
226       'includes': [ '../build/grit_target.gypi' ],
227     },  # end of target 'remoting_resources'
229     {
230       # GN version: //remoting/base
231       'target_name': 'remoting_base',
232       'type': 'static_library',
233       'variables': { 'enable_wexit_time_destructors': 1, },
234       'dependencies': [
235         '../base/base.gyp:base',
236         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
237         '../media/media.gyp:media',
238         '../media/media.gyp:shared_memory_support',
239         '../net/net.gyp:net',
240         '../third_party/libvpx/libvpx.gyp:libvpx',
241         '../third_party/libyuv/libyuv.gyp:libyuv',
242         '../third_party/opus/opus.gyp:opus',
243         '../third_party/protobuf/protobuf.gyp:protobuf_lite',
244         '../third_party/webrtc/modules/modules.gyp:desktop_capture',
245         '../ui/base/ui_base.gyp:ui_base',
246         '../ui/gfx/gfx.gyp:gfx',
247         '../ui/gfx/gfx.gyp:gfx_geometry',
248         'proto/chromotocol.gyp:chromotocol_proto_lib',
249         'remoting_resources',
250       ],
251       'export_dependent_settings': [
252         '../base/base.gyp:base',
253         '../net/net.gyp:net',
254         '../third_party/protobuf/protobuf.gyp:protobuf_lite',
255         'proto/chromotocol.gyp:chromotocol_proto_lib',
256       ],
257       # This target needs a hard dependency because dependent targets
258       # depend on chromotocol_proto_lib for headers.
259       'hard_dependency': 1,
260       'sources': [
261         '<@(remoting_base_sources)',
262       ],
263     },  # end of target 'remoting_base'
265     {
266       # GN version: //remoting/protocol
267       'target_name': 'remoting_protocol',
268       'type': 'static_library',
269       'variables': { 'enable_wexit_time_destructors': 1, },
270       'dependencies': [
271         '../base/base.gyp:base',
272         '../crypto/crypto.gyp:crypto',
273         '../jingle/jingle.gyp:jingle_glue',
274         '../jingle/jingle.gyp:notifier',
275         '../net/net.gyp:net',
276         '../third_party/libjingle/libjingle.gyp:libjingle',
277         'remoting_base',
278       ],
279       'export_dependent_settings': [
280         '../third_party/libjingle/libjingle.gyp:libjingle',
281       ],
282       'sources': [
283         '<@(remoting_protocol_sources)',
284       ],
285     },  # end of target 'remoting_protocol'
286   ],  # end of targets