| OLD | NEW |
| 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2011 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 'conditions': [ | 6 'conditions': [ |
| 7 ['OS=="win" or OS=="mac" or OS=="linux"', { | 7 ['OS=="win" or OS=="mac" or OS=="linux"', { |
| 8 'targets': [ | 8 'targets': [ |
| 9 { | 9 { |
| 10 # policy_templates has different inputs and outputs, so it can't use | 10 # policy_templates has different inputs and outputs, so it can't use |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 'inputs': ['../../VERSION'], | 37 'inputs': ['../../VERSION'], |
| 38 'outputs': ['<(version_path)'], | 38 'outputs': ['<(version_path)'], |
| 39 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], | 39 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], |
| 40 }, | 40 }, |
| 41 { | 41 { |
| 42 # Add all the templates generated at the previous step into | 42 # Add all the templates generated at the previous step into |
| 43 # a zip archive. | 43 # a zip archive. |
| 44 'action_name': 'pack_templates', | 44 'action_name': 'pack_templates', |
| 45 'variables': { | 45 'variables': { |
| 46 'zip_script': | 46 'zip_script': |
| 47 'tools/build/win/make_zip_with_relative_entries.py' | 47 'tools/build/win/make_policy_zip.py' |
| 48 }, | 48 }, |
| 49 'inputs': [ | 49 'inputs': [ |
| 50 '<(version_path)', | 50 '<(version_path)', |
| 51 '<@(template_files)', | 51 '<@(template_files)', |
| 52 '<(zip_script)' | 52 '<(zip_script)' |
| 53 ], | 53 ], |
| 54 'outputs': [ | 54 'outputs': [ |
| 55 '<(PRODUCT_DIR)/policy_templates.zip' | 55 '<(PRODUCT_DIR)/policy_templates.zip' |
| 56 ], | 56 ], |
| 57 'action': [ | 57 'action': [ |
| 58 'python', | 58 'python', |
| 59 '<(zip_script)', | 59 '<(zip_script)', |
| 60 '--output', |
| 60 '<@(_outputs)', | 61 '<@(_outputs)', |
| 61 '<(grit_out_dir)/app/policy', | 62 '--basedir', '<(grit_out_dir)/app/policy', |
| 62 '<@(template_files)', | 63 # The list of files in the destination zip is derived from |
| 63 '<(version_path)' | 64 # the list of output nodes in the following grd file. |
| 65 # This whole trickery is necessary because we cannot pass |
| 66 # the entire list of file names as command line arguments, |
| 67 # because they would exceed the length limit on Windows. |
| 68 '--grd_input', |
| 69 '<(grit_grd_file)', |
| 70 '--grd_strip_path_prefix', |
| 71 'app/policy', |
| 72 '--extra_input', |
| 73 'VERSION', |
| 74 # Module to be used to process grd_input'. |
| 75 '--grit_info', |
| 76 '<(DEPTH)/tools/grit/grit_info.py', |
| 77 '<@(grit_defines)', |
| 64 ], | 78 ], |
| 65 'message': 'Packing generated templates into <(_outputs)', | 79 'message': 'Packing generated templates into <(_outputs)', |
| 66 } | 80 } |
| 67 ] | 81 ] |
| 68 }], | 82 }], |
| 69 ], # conditions | 83 ], # conditions |
| 70 }, | 84 }, |
| 71 ], # 'targets' | 85 ], # 'targets' |
| 72 }], # OS=="win" or OS=="mac" or OS=="linux" | 86 }], # OS=="win" or OS=="mac" or OS=="linux" |
| 73 ['OS=="mac"', { | 87 ['OS=="mac"', { |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 'process_outputs_as_mac_bundle_resources': 1, | 128 'process_outputs_as_mac_bundle_resources': 1, |
| 115 }, | 129 }, |
| 116 { | 130 { |
| 117 'action_name': | 131 'action_name': |
| 118 'Copy Localizable.strings files to manifest bundle', | 132 'Copy Localizable.strings files to manifest bundle', |
| 119 'variables': { | 133 'variables': { |
| 120 'input_path': '<(grit_out_dir)/app/policy/mac/strings', | 134 'input_path': '<(grit_out_dir)/app/policy/mac/strings', |
| 121 # Directory to collect the Localizable.strings files before | 135 # Directory to collect the Localizable.strings files before |
| 122 # they are copied to the bundle. | 136 # they are copied to the bundle. |
| 123 'output_path': '<(INTERMEDIATE_DIR)/app_manifest', | 137 'output_path': '<(INTERMEDIATE_DIR)/app_manifest', |
| 124 # TODO(gfeher): replace this with <(locales) when we have real | |
| 125 # translations | |
| 126 'available_locales': 'en', | |
| 127 }, | 138 }, |
| 128 'inputs': [ | 139 'inputs': [ |
| 129 # TODO: remove this helper when we have loops in GYP | 140 # TODO: remove this helper when we have loops in GYP |
| 130 '>!@(<(apply_locales_cmd) -d \'<(input_path)/ZZLOCALE.lproj/Loca
lizable.strings\' <(available_locales))', | 141 '>!@(<(apply_locales_cmd) -d \'<(input_path)/ZZLOCALE.lproj/Loca
lizable.strings\' <(locales))', |
| 131 ], | 142 ], |
| 132 'outputs': [ | 143 'outputs': [ |
| 133 # TODO: remove this helper when we have loops in GYP | 144 # TODO: remove this helper when we have loops in GYP |
| 134 '>!@(<(apply_locales_cmd) -d \'<(output_path)/ZZLOCALE.lproj/Loc
alizable.strings\' <(available_locales))', | 145 '>!@(<(apply_locales_cmd) -d \'<(output_path)/ZZLOCALE.lproj/Loc
alizable.strings\' <(locales))', |
| 135 ], | 146 ], |
| 136 'action': [ | 147 'action': [ |
| 137 'cp', '-R', | 148 'cp', '-R', |
| 138 '<(input_path)/', | 149 '<(input_path)/', |
| 139 '<(output_path)', | 150 '<(output_path)', |
| 140 ], | 151 ], |
| 141 'message': | 152 'message': |
| 142 'Copy the Localizable.strings files to the manifest bundle', | 153 'Copy the Localizable.strings files to the manifest bundle', |
| 143 'process_outputs_as_mac_bundle_resources': 1, | 154 'process_outputs_as_mac_bundle_resources': 1, |
| 144 }, | 155 }, |
| 145 ], | 156 ], |
| 146 }, | 157 }, |
| 147 ] | 158 ] |
| 148 }] | 159 }] |
| 149 ], # 'conditions' | 160 ], # 'conditions' |
| 150 } | 161 } |
| 151 | 162 |
| 152 # Local Variables: | 163 # Local Variables: |
| 153 # tab-width:2 | 164 # tab-width:2 |
| 154 # indent-tabs-mode:nil | 165 # indent-tabs-mode:nil |
| 155 # End: | 166 # End: |
| 156 # vim: set expandtab tabstop=2 shiftwidth=2: | 167 # vim: set expandtab tabstop=2 shiftwidth=2: |
| OLD | NEW |