OLD | NEW |
1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 { | 5 { |
6 'includes': [ | 6 'includes': [ |
7 # Included to get 'mac_bundle_id' and other variables. | 7 # Included to get 'mac_bundle_id' and other variables. |
8 '../build/chrome_settings.gypi', | 8 '../build/chrome_settings.gypi', |
9 ], | 9 ], |
10 'variables': { | 10 'variables': { |
11 'chromium_code': 1, | 11 'chromium_code': 1, |
12 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/chrome', | 12 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/chrome', |
13 'policy_out_dir': '<(SHARED_INTERMEDIATE_DIR)/policy', | 13 'policy_out_dir': '<(SHARED_INTERMEDIATE_DIR)/policy', |
14 'protoc_out_dir': '<(SHARED_INTERMEDIATE_DIR)/protoc_out', | 14 'protoc_out_dir': '<(SHARED_INTERMEDIATE_DIR)/protoc_out', |
| 15 'android_resources_out_dir': '<(policy_out_dir)/android_resources', |
15 'generate_policy_source_script_path': | 16 'generate_policy_source_script_path': |
16 'policy/tools/generate_policy_source.py', | 17 'policy/tools/generate_policy_source.py', |
17 'policy_constant_header_path': | 18 'policy_constant_header_path': |
18 '<(policy_out_dir)/policy/policy_constants.h', | 19 '<(policy_out_dir)/policy/policy_constants.h', |
19 'policy_constant_source_path': | 20 'policy_constant_source_path': |
20 '<(policy_out_dir)/policy/policy_constants.cc', | 21 '<(policy_out_dir)/policy/policy_constants.cc', |
21 'protobuf_decoder_path': | 22 'protobuf_decoder_path': |
22 '<(policy_out_dir)/policy/cloud_policy_generated.cc', | 23 '<(policy_out_dir)/policy/cloud_policy_generated.cc', |
23 'app_restrictions_path': | 24 'app_restrictions_path': |
24 '<(policy_out_dir)/app_restrictions.xml', | 25 '<(android_resources_out_dir)/xml-v21/app_restrictions.xml', |
| 26 'app_resources_path': |
| 27 '<(android_resources_out_dir)/values-v21/restriction_values.xml', |
25 # This is the "full" protobuf, which defines one protobuf message per | 28 # This is the "full" protobuf, which defines one protobuf message per |
26 # policy. It is also the format currently used by the server. | 29 # policy. It is also the format currently used by the server. |
27 'chrome_settings_proto_path': | 30 'chrome_settings_proto_path': |
28 '<(policy_out_dir)/policy/chrome_settings.proto', | 31 '<(policy_out_dir)/policy/chrome_settings.proto', |
29 # This protobuf is equivalent to chrome_settings.proto but shares messages | 32 # This protobuf is equivalent to chrome_settings.proto but shares messages |
30 # for policies of the same type, so that less classes have to be generated | 33 # for policies of the same type, so that less classes have to be generated |
31 # and compiled. | 34 # and compiled. |
32 'cloud_policy_proto_path': | 35 'cloud_policy_proto_path': |
33 '<(policy_out_dir)/policy/cloud_policy.proto', | 36 '<(policy_out_dir)/policy/cloud_policy.proto', |
34 }, | 37 }, |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 'policy/resources/policy_templates.json', | 108 'policy/resources/policy_templates.json', |
106 '<(generate_policy_source_script_path)', | 109 '<(generate_policy_source_script_path)', |
107 ], | 110 ], |
108 'outputs': [ | 111 'outputs': [ |
109 '<(policy_constant_header_path)', | 112 '<(policy_constant_header_path)', |
110 '<(policy_constant_source_path)', | 113 '<(policy_constant_source_path)', |
111 '<(protobuf_decoder_path)', | 114 '<(protobuf_decoder_path)', |
112 '<(chrome_settings_proto_path)', | 115 '<(chrome_settings_proto_path)', |
113 '<(cloud_policy_proto_path)', | 116 '<(cloud_policy_proto_path)', |
114 '<(app_restrictions_path)', | 117 '<(app_restrictions_path)', |
| 118 '<(app_resources_path)', |
115 ], | 119 ], |
116 'action_name': 'generate_policy_source', | 120 'action_name': 'generate_policy_source', |
117 'action': [ | 121 'action': [ |
118 'python', | 122 'python', |
119 '<@(generate_policy_source_script_path)', | 123 '<@(generate_policy_source_script_path)', |
120 '--policy-constants-header=<(policy_constant_header_path)', | 124 '--policy-constants-header=<(policy_constant_header_path)', |
121 '--policy-constants-source=<(policy_constant_source_path)', | 125 '--policy-constants-source=<(policy_constant_source_path)', |
122 '--chrome-settings-protobuf=<(chrome_settings_proto_path)', | 126 '--chrome-settings-protobuf=<(chrome_settings_proto_path)', |
123 '--cloud-policy-protobuf=<(cloud_policy_proto_path)', | 127 '--cloud-policy-protobuf=<(cloud_policy_proto_path)', |
124 '--cloud-policy-decoder=<(protobuf_decoder_path)', | 128 '--cloud-policy-decoder=<(protobuf_decoder_path)', |
125 '--app-restrictions-definition=<(app_restrictions_path)', | 129 '--app-restrictions-definition=<(app_restrictions_path)', |
| 130 '--app-restrictions-resources=<(app_resources_path)', |
126 '<(OS)', | 131 '<(OS)', |
127 '<(chromeos)', | 132 '<(chromeos)', |
128 'policy/resources/policy_templates.json', | 133 'policy/resources/policy_templates.json', |
129 ], | 134 ], |
130 'message': 'Generating policy source', | 135 'message': 'Generating policy source', |
131 'conditions': [ | 136 'conditions': [ |
132 ['OS!="android"', { | 137 ['OS!="android"', { |
133 'outputs!': [ | 138 'outputs!': [ |
134 '<(app_restrictions_path)', | 139 '<(app_restrictions_path)', |
| 140 '<(app_resources_path)', |
135 ], | 141 ], |
136 }], | 142 }], |
137 ], | 143 ], |
138 }, | 144 }, |
139 ], | 145 ], |
140 'direct_dependent_settings': { | 146 'direct_dependent_settings': { |
141 'include_dirs': [ | 147 'include_dirs': [ |
142 '<(policy_out_dir)', | 148 '<(policy_out_dir)', |
143 '<(protoc_out_dir)', | 149 '<(protoc_out_dir)', |
144 ], | 150 ], |
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
357 'cloud_policy_code_generate', | 363 'cloud_policy_code_generate', |
358 ], | 364 ], |
359 'configurations': { | 365 'configurations': { |
360 'Common_Base': { | 366 'Common_Base': { |
361 'msvs_target_platform': 'x64', | 367 'msvs_target_platform': 'x64', |
362 }, | 368 }, |
363 }, | 369 }, |
364 }, | 370 }, |
365 ], | 371 ], |
366 }], | 372 }], |
367 ['OS!="ios"', { | 373 ['OS=="win" or OS=="mac" or OS=="linux"', { |
368 'targets': [ | 374 'targets': [ |
369 { | 375 { |
370 # policy_templates has different inputs and outputs, so it can't use | 376 # policy_templates has different inputs and outputs, so it can't use |
371 # the rules of chrome_strings | 377 # the rules of chrome_strings |
372 'target_name': 'policy_templates', | 378 'target_name': 'policy_templates', |
373 'type': 'none', | 379 'type': 'none', |
374 'variables': { | 380 'variables': { |
375 'grit_grd_file': 'policy/resources/policy_templates.grd', | 381 'grit_grd_file': 'policy/resources/policy_templates.grd', |
376 'grit_info_cmd': [ | 382 'grit_info_cmd': [ |
377 'python', | 383 'python', |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
465 'message': | 471 'message': |
466 'Copy the Localizable.strings files to the manifest bundle', | 472 'Copy the Localizable.strings files to the manifest bundle', |
467 'process_outputs_as_mac_bundle_resources': 1, | 473 'process_outputs_as_mac_bundle_resources': 1, |
468 }, | 474 }, |
469 ], | 475 ], |
470 }, | 476 }, |
471 ], | 477 ], |
472 }], | 478 }], |
473 ], | 479 ], |
474 } | 480 } |
OLD | NEW |