Sends NetworkChangeNotifier connection type changes to Blink, to support NetInfo v3.
[chromium-blink-merge.git] / remoting / remoting_android.gypi
blobfdfc4e021ba68479cbfeb4bae5d9fc19a69d79af
1 # Copyright 2014 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   'conditions': [
7     ['OS=="android"', {
8       'targets': [
9         {
10           'target_name': 'remoting_jni_headers',
11           'type': 'none',
12           'sources': [
13             'android/java/src/org/chromium/chromoting/jni/JniInterface.java',
14           ],
15           'variables': {
16             'jni_gen_package': 'remoting',
17           },
18           'includes': [ '../build/jni_generator.gypi' ],
19         },  # end of target 'remoting_jni_headers'
20         {
21           'target_name': 'remoting_client_jni',
22           'type': 'shared_library',
23           'dependencies': [
24             'remoting_base',
25             'remoting_client',
26             'remoting_jni_headers',
27             'remoting_protocol',
28             '../google_apis/google_apis.gyp:google_apis',
29           ],
30           'sources': [
31             'client/jni/android_keymap.cc',
32             'client/jni/android_keymap.h',
33             'client/jni/chromoting_jni_instance.cc',
34             'client/jni/chromoting_jni_instance.h',
35             'client/jni/chromoting_jni_onload.cc',
36             'client/jni/chromoting_jni_runtime.cc',
37             'client/jni/chromoting_jni_runtime.h',
38             'client/jni/jni_frame_consumer.cc',
39             'client/jni/jni_frame_consumer.h',
40           ],
41         },  # end of target 'remoting_client_jni'
42         {
43           'target_name': 'remoting_android_resources',
44           'type': 'none',
45           'copies': [
46             {
47               'destination': '<(SHARED_INTERMEDIATE_DIR)/remoting/android/res/drawable',
48               'files': [
49                 'resources/chromoting128.png',
50                 'resources/icon_host.png',
51               ],
52             },
53           ],
54         },  # end of target 'remoting_android_resources'
55         {
56           'target_name': 'remoting_apk_manifest',
57           'type': 'none',
58           'sources': [
59             'android/java/AndroidManifest.xml.jinja2',
60           ],
61           'rules': [{
62             'rule_name': 'generate_manifest',
63             'extension': 'jinja2',
64             'inputs': [
65               '<(remoting_localize_path)',
66               '<(branding_path)',
67             ],
68             'outputs': [
69               '<(SHARED_INTERMEDIATE_DIR)/remoting/android/<(RULE_INPUT_ROOT)',
70             ],
71             'action': [
72               'python', '<(remoting_localize_path)',
73               '--variables', '<(branding_path)',
74               '--template', '<(RULE_INPUT_PATH)',
75               '--locale_output', '<@(_outputs)',
76               'en',
77             ],
78           }],
79         },  # end of target 'remoting_apk_manifest'
80         {
81           'target_name': 'remoting_android_client_java',
82           'type': 'none',
83           'variables': {
84             'java_in_dir': 'android/java',
85             'has_java_resources': 1,
86             'R_package': 'org.chromium.chromoting',
87             'R_package_relpath': 'org/chromium/chromoting',
88             'res_extra_dirs': [ '<(SHARED_INTERMEDIATE_DIR)/remoting/android/res' ],
89             'res_extra_files': [
90               '<!@pymod_do_main(grit_info <@(grit_defines) --outputs "<(SHARED_INTERMEDIATE_DIR)" resources/remoting_strings.grd)',
91               '<(SHARED_INTERMEDIATE_DIR)/remoting/android/res/drawable/chromoting128.png',
92               '<(SHARED_INTERMEDIATE_DIR)/remoting/android/res/drawable/icon_host.png',
93             ],
94           },
95           'dependencies': [
96             '../base/base.gyp:base_java',
97             '../ui/android/ui_android.gyp:ui_java',
98             'remoting_android_resources',
99           ],
100           'includes': [ '../build/java.gypi' ],
101         },
102         {
103           'target_name': 'remoting_apk',
104           'type': 'none',
105           'dependencies': [
106             'remoting_apk_manifest',
107             'remoting_client_jni',
108             'remoting_android_client_java',
109           ],
110           'variables': {
111             'apk_name': '<!(python <(version_py_path) -f <(branding_path) -t "@APK_FILE_NAME@")',
112             'android_app_version_name': '<(version_full)',
113             'android_app_version_code': '<!(python tools/android_version.py <(android_app_version_name))',
114             'android_manifest_path': '<(SHARED_INTERMEDIATE_DIR)/remoting/android/AndroidManifest.xml',
115             'java_in_dir': 'android/apk',
116             'native_lib_target': 'libremoting_client_jni',
117           },
118           'includes': [ '../build/java_apk.gypi' ],
119         },  # end of target 'remoting_apk'
120         {
121           'target_name': 'remoting_test_apk',
122           'type': 'none',
123           'dependencies': [
124             '../base/base.gyp:base_java_test_support',
125             'remoting_android_client_java',
126           ],
127           'variables': {
128             'apk_name': 'ChromotingTest',
129             'java_in_dir': 'android/javatests',
130             'is_test_apk': 1,
131           },
132           'includes': [ '../build/java_apk.gypi' ],
133         },  # end of target 'remoting_test_apk'
134       ],  # end of 'targets'
135     }],  # 'OS=="android"'
137     ['OS=="android"', {
138       'targets': [
139         {
140           'target_name': 'remoting_unittests_apk',
141           'type': 'none',
142           'dependencies': [
143             'remoting_unittests',
144           ],
145           'variables': {
146             'test_suite_name': 'remoting_unittests',
147           },
148           'includes': [ '../build/apk_test.gypi' ],
149         },
150       ],
151     }],  # 'OS=="android"
152   ],  # end of 'conditions'