Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 ['chromeos==1', { | 7 ['chromeos==1', { |
| 8 'variables': { | 8 'variables': { |
| 9 # Whether to compress the 4 main ChromeVox scripts. | 9 # Whether to compress the 4 main ChromeVox scripts. |
| 10 'chromevox_compress_js%': '1', | 10 'chromevox_compress_js%': '1', |
| 11 'background_script_loader_file': 'chromevox/background/loader.js', | 11 'chromevox1_background_script_loader_file': 'chromevox/background/loader .js', |
| 12 'content_script_loader_file': 'chromevox/injected/loader.js', | 12 'chromevox1_content_script_loader_file': 'chromevox/injected/loader.js', |
| 13 'options_script_loader_file': 'chromevox/background/options_loader.js', | 13 'chromevox1_options_script_loader_file': 'chromevox/background/options_l oader.js', |
| 14 'kbexplorer_loader_file': 'chromevox/background/kbexplorer_loader.js', | 14 'chromevox1_kbexplorer_loader_file': 'chromevox/background/kbexplorer_lo ader.js', |
| 15 'chromevox2_background_script_loader_file': 'cvox2/background/loader.js' , | |
|
David Tseng
2014/10/14 23:10:11
nit: sort
| |
| 16 | |
| 15 }, | 17 }, |
| 16 'includes': [ | 18 'includes': [ |
| 17 'chromevox_tests.gypi', | 19 'chromevox_tests.gypi', |
| 18 'common.gypi', | 20 'common.gypi', |
| 19 ], | 21 ], |
| 20 'targets': [ | 22 'targets': [ |
| 21 { | 23 { |
| 22 'target_name': 'chromevox', | 24 'target_name': 'chromevox', |
| 23 'type': 'none', | 25 'type': 'none', |
| 24 'dependencies': [ | 26 'dependencies': [ |
| 25 'chromevox_resources', | 27 'chromevox_resources', |
| 26 'chromevox_manifest', | 28 'chromevox1_manifest', |
| 27 'chromevox_guest_manifest', | 29 'chromevox1_guest_manifest', |
| 28 'chromevox2', | 30 'chromevox2_manifest', |
| 31 'chromevox2_guest_manifest', | |
| 29 ], | 32 ], |
| 30 }, | 33 }, |
| 31 { | 34 { |
| 32 'target_name': 'chromevox_resources', | 35 'target_name': 'chromevox_resources', |
| 33 'type': 'none', | 36 'type': 'none', |
| 34 'dependencies': [ | 37 'dependencies': [ |
| 35 'chromevox_assets', | 38 'chromevox_assets', |
| 36 'chromevox_static_files', | 39 'chromevox_static_files', |
| 37 'chromevox_strings', | 40 'chromevox_strings', |
| 38 'chromevox_uncompiled_js_files', | 41 'chromevox_uncompiled_js_files', |
| 39 '<(chromevox_third_party_dir)/chromevox.gyp:chromevox_third_party_re sources', | 42 '<(chromevox_third_party_dir)/chromevox.gyp:chromevox_third_party_re sources', |
| 40 '../braille_ime/braille_ime.gyp:braille_ime_manifest', | 43 '../braille_ime/braille_ime.gyp:braille_ime_manifest', |
| 41 ], | 44 ], |
| 42 'conditions': [ | 45 'conditions': [ |
| 43 ['disable_nacl==0 and disable_nacl_untrusted==0', { | 46 ['disable_nacl==0 and disable_nacl_untrusted==0', { |
| 44 'dependencies': [ | 47 'dependencies': [ |
| 45 '<(DEPTH)/third_party/liblouis/liblouis_nacl.gyp:liblouis_nacl_w rapper_nacl', | 48 '<(DEPTH)/third_party/liblouis/liblouis_nacl.gyp:liblouis_nacl_w rapper_nacl', |
| 46 ], | 49 ], |
| 47 }], | 50 }], |
| 48 ['chromevox_compress_js==1', { | 51 ['chromevox_compress_js==1', { |
| 49 'dependencies': [ | 52 'dependencies': [ |
| 50 'chromevox_content_script', | 53 'chromevox1_content_script', |
| 51 'chromevox_background_script', | 54 'chromevox1_background_script', |
| 52 'chromevox_options_script', | 55 'chromevox1_options_script', |
|
David Tseng
2014/10/14 23:10:11
nit: sort
| |
| 53 'chromevox_kbexplorer_script', | 56 'chromevox1_kbexplorer_script', |
| 57 'chromevox2_background_script', | |
| 54 ], | 58 ], |
| 55 }], | 59 }, { |
| 56 ['chromevox_compress_js==0', { | |
| 57 'dependencies': [ | 60 'dependencies': [ |
|
David Tseng
2014/10/14 23:10:10
# else chromevox_compress_js==0
| |
| 58 'chromevox_copied_scripts', | 61 'chromevox_copied_scripts', |
| 62 'chromevox_deps', | |
| 59 ], | 63 ], |
| 60 }], | 64 }], |
| 61 ], | 65 ], |
| 62 }, | 66 }, |
| 63 { | 67 { |
| 64 'target_name': 'chromevox_assets', | 68 'target_name': 'chromevox_assets', |
| 65 'type': 'none', | 69 'type': 'none', |
| 66 'includes': [ | 70 'includes': [ |
| 67 'chromevox_assets.gypi', | 71 'chromevox_assets.gypi', |
| 68 ], | 72 ], |
| 69 }, | 73 }, |
| 70 { | 74 { |
| 71 'target_name': 'chromevox_manifest', | |
| 72 'type': 'none', | |
| 73 'variables': { | |
| 74 'output_manifest_path': '<(chromevox_dest_dir)/manifest.json', | |
| 75 }, | |
| 76 'includes': [ 'generate_manifest.gypi', ], | |
| 77 }, | |
| 78 { | |
| 79 'target_name': 'chromevox_guest_manifest', | |
| 80 'type': 'none', | |
| 81 'variables': { | |
| 82 'output_manifest_path': '<(chromevox_dest_dir)/manifest_guest.json', | |
| 83 'is_guest_manifest': 1, | |
| 84 }, | |
| 85 'includes': [ 'generate_manifest.gypi', ], | |
| 86 }, | |
| 87 { | |
| 88 'target_name': 'chromevox_static_files', | 75 'target_name': 'chromevox_static_files', |
| 89 'type': 'none', | 76 'type': 'none', |
| 90 'copies': [ | 77 'copies': [ |
| 91 { | 78 { |
| 92 'destination': '<(chromevox_dest_dir)/chromevox/background', | 79 'destination': '<(chromevox_dest_dir)/chromevox/background', |
| 93 'files': [ | 80 'files': [ |
| 94 'chromevox/background/background.html', | 81 'chromevox/background/background.html', |
| 95 'chromevox/background/kbexplorer.html', | 82 'chromevox/background/kbexplorer.html', |
| 96 'chromevox/background/options.html', | 83 'chromevox/background/options.html', |
| 97 ], | 84 ], |
| 98 }, | 85 }, |
| 86 { | |
| 87 'destination': '<(PRODUCT_DIR)/resources/chromeos/chromevox/cvox2/ background', | |
| 88 'files': [ | |
| 89 'cvox2/background/background.html', | |
| 90 ], | |
| 91 }, | |
| 99 ], | 92 ], |
| 100 }, | 93 }, |
| 101 { | 94 { |
| 102 # JavaScript files that are always directly included into the | 95 # JavaScript files that are always directly included into the |
| 103 # destination directory. | 96 # destination directory. |
| 104 'target_name': 'chromevox_uncompiled_js_files', | 97 'target_name': 'chromevox_uncompiled_js_files', |
| 105 'type': 'none', | 98 'type': 'none', |
| 106 'copies': [ | 99 'copies': [ |
| 107 { | 100 { |
| 108 'destination': '<(chromevox_dest_dir)/closure', | |
| 109 'files': [ | |
| 110 'closure/closure_preinit.js', | |
| 111 ], | |
| 112 }, | |
| 113 { | |
| 114 'destination': '<(chromevox_dest_dir)/chromevox/injected', | 101 'destination': '<(chromevox_dest_dir)/chromevox/injected', |
| 115 'files': [ | 102 'files': [ |
| 116 'chromevox/injected/api.js', | 103 'chromevox/injected/api.js', |
| 117 'chromevox/injected/api_util.js', | 104 ], |
| 105 'conditions': [ | |
|
David Tseng
2014/10/14 23:10:10
What happened to api_util.js above? It should alwa
| |
| 106 [ 'chromevox_compress_js==1', { | |
| 107 'files': [ | |
| 108 'chromevox/injected/api_util.js', | |
| 109 ], | |
| 110 }], | |
| 118 ], | 111 ], |
| 119 }, | 112 }, |
| 120 ], | 113 ], |
| 114 'conditions': [ | |
| 115 [ 'chromevox_compress_js==0', { | |
| 116 'copies': [ | |
| 117 { | |
| 118 'destination': '<(chromevox_dest_dir)/closure', | |
| 119 'files': [ | |
| 120 'closure/closure_preinit.js', | |
| 121 ], | |
| 122 }, | |
| 123 ], | |
| 124 }], | |
| 125 ], | |
| 121 }, | 126 }, |
| 122 { | 127 { |
| 123 'target_name': 'chromevox_strings', | 128 'target_name': 'chromevox_strings', |
| 124 'type': 'none', | 129 'type': 'none', |
| 125 'actions': [ | 130 'actions': [ |
| 126 { | 131 { |
| 127 'action_name': 'chromevox_strings', | 132 'action_name': 'chromevox_strings', |
| 128 'variables': { | 133 'variables': { |
| 129 'grit_grd_file': 'strings/chromevox_strings.grd', | 134 'grit_grd_file': 'strings/chromevox_strings.grd', |
| 130 'grit_out_dir': '<(chromevox_dest_dir)', | 135 'grit_out_dir': '<(chromevox_dest_dir)', |
| 131 # We don't generate any RC files, so no resource_ds file is need ed. | 136 # We don't generate any RC files, so no resource_ds file is need ed. |
| 132 'grit_resource_ids': '', | 137 'grit_resource_ids': '', |
| 133 }, | 138 }, |
| 134 'includes': [ '../../../../../build/grit_action.gypi' ], | 139 'includes': [ '../../../../../build/grit_action.gypi' ], |
| 135 }, | 140 }, |
| 136 ], | 141 ], |
| 137 }, | 142 }, |
| 138 { | 143 { |
| 139 'target_name': 'chromevox2', | 144 'target_name': 'chromevox_deps', |
| 140 'type': 'none', | |
| 141 'dependencies': [ | |
| 142 'chromevox2_copied_scripts', | |
| 143 'chromevox2_deps', | |
| 144 'chromevox2_manifest', | |
| 145 'chromevox2_guest_manifest', | |
| 146 'chromevox2_resources', | |
| 147 ], | |
| 148 }, | |
| 149 { | |
| 150 'target_name': 'chromevox2_copied_scripts', | |
| 151 'type': 'none', | |
| 152 'variables': { | |
| 153 'dest_dir': '<(chromevox_dest_dir)', | |
| 154 }, | |
| 155 'sources': [ | |
| 156 'cvox2/background/loader.js', | |
| 157 ], | |
| 158 'includes': [ 'copy_js.gypi', ], | |
| 159 }, | |
| 160 { | |
| 161 'target_name': 'chromevox2_deps', | |
| 162 'type': 'none', | 145 'type': 'none', |
| 163 'variables': { | 146 'variables': { |
| 164 'deps_js_output_file': '<(chromevox_dest_dir)/deps.js', | 147 'deps_js_output_file': '<(chromevox_dest_dir)/deps.js', |
| 165 }, | 148 }, |
| 166 'sources': [ | 149 'sources': [ |
| 167 'cvox2/background/loader.js', | 150 '<(chromevox1_background_script_loader_file)', |
| 151 '<(chromevox1_content_script_loader_file)', | |
| 152 '<(chromevox1_options_script_loader_file)', | |
| 153 '<(chromevox1_kbexplorer_loader_file)', | |
| 154 '<(chromevox2_background_script_loader_file)', | |
|
David Tseng
2014/10/14 23:10:11
nit: sort
| |
| 168 ], | 155 ], |
| 169 'includes': ['generate_deps.gypi'], | 156 'includes': ['generate_deps.gypi'], |
| 170 }, | 157 }, |
| 171 { | 158 { |
| 172 'target_name': 'chromevox2_resources', | 159 'target_name': 'chromevox1_manifest', |
| 173 'type': 'none', | 160 'type': 'none', |
| 174 'copies': [ | 161 'variables': { |
| 175 { | 162 'output_manifest_path': '<(chromevox_dest_dir)/manifest.json', |
| 176 'destination': '<(PRODUCT_DIR)/resources/chromeos/chromevox/cvox2/ background', | 163 }, |
| 177 'files': [ | 164 'includes': [ 'generate_manifest.gypi', ], |
| 178 'cvox2/background/background.html', | 165 }, |
| 179 ], | 166 { |
| 180 }, | 167 'target_name': 'chromevox1_guest_manifest', |
| 181 ], | 168 'type': 'none', |
| 169 'variables': { | |
| 170 'output_manifest_path': '<(chromevox_dest_dir)/manifest_guest.json', | |
| 171 'is_guest_manifest': 1, | |
| 172 }, | |
| 173 'includes': [ 'generate_manifest.gypi', ], | |
| 182 }, | 174 }, |
| 183 { | 175 { |
| 184 'target_name': 'chromevox2_manifest', | 176 'target_name': 'chromevox2_manifest', |
| 185 'type': 'none', | 177 'type': 'none', |
| 186 'variables': { | 178 'variables': { |
| 187 'output_manifest_path': '<(chromevox_dest_dir)/manifest_next.json', | 179 'output_manifest_path': '<(chromevox_dest_dir)/manifest_next.json', |
| 188 'use_chromevox_next': 1, | 180 'is_chromevox_next': 1, |
| 189 }, | 181 }, |
| 190 'includes': [ 'generate_manifest.gypi', ], | 182 'includes': [ 'generate_manifest.gypi', ], |
| 191 }, | 183 }, |
| 192 { | 184 { |
| 193 'target_name': 'chromevox2_guest_manifest', | 185 'target_name': 'chromevox2_guest_manifest', |
| 194 'type': 'none', | 186 'type': 'none', |
| 195 'variables': { | 187 'variables': { |
| 196 'output_manifest_path': '<(chromevox_dest_dir)/manifest_next_guest.j son', | 188 'output_manifest_path': '<(chromevox_dest_dir)/manifest_next_guest.j son', |
| 197 'is_guest_manifest': 1, | 189 'is_guest_manifest': 1, |
| 198 'use_chromevox_next': 1, | 190 'is_chromevox_next': 1, |
| 199 }, | 191 }, |
| 200 'includes': [ 'generate_manifest.gypi', ], | 192 'includes': [ 'generate_manifest.gypi', ], |
| 201 }, | 193 }, |
| 202 ], | 194 ], |
| 203 'conditions': [ | 195 'conditions': [ |
| 204 ['chromevox_compress_js==1', { | 196 ['chromevox_compress_js==1', { |
| 205 'targets': [ | 197 'targets': [ |
| 206 { | 198 { |
| 207 'target_name': 'chromevox_content_script', | 199 'target_name': 'chromevox1_content_script', |
| 208 'type': 'none', | 200 'type': 'none', |
| 209 'variables': { | 201 'variables': { |
| 210 'output_file': '<(chromevox_dest_dir)/chromeVoxChromePageScript. js', | 202 'output_file': '<(chromevox_dest_dir)/chromeVoxChromePageScript. js', |
| 211 }, | 203 }, |
| 212 'sources': [ '<(content_script_loader_file)' ], | 204 'sources': [ '<(chromevox1_content_script_loader_file)' ], |
| 213 'includes': [ 'compress_js.gypi', ], | 205 'includes': [ 'compress_js.gypi', ], |
| 214 }, | 206 }, |
| 215 { | 207 { |
| 216 'target_name': 'chromevox_background_script', | 208 'target_name': 'chromevox1_background_script', |
| 217 'type': 'none', | 209 'type': 'none', |
| 218 'variables': { | 210 'variables': { |
| 219 'output_file': '<(chromevox_dest_dir)/chromeVoxChromeBackgroundS cript.js', | 211 'output_file': '<(chromevox_dest_dir)/chromeVoxChromeBackgroundS cript.js', |
| 220 }, | 212 }, |
| 221 'sources': [ '<(background_script_loader_file)' ], | 213 'sources': [ '<(chromevox1_background_script_loader_file)' ], |
| 222 'includes': [ 'compress_js.gypi', ], | 214 'includes': [ 'compress_js.gypi', ], |
| 223 }, | 215 }, |
| 224 { | 216 { |
| 225 'target_name': 'chromevox_options_script', | 217 'target_name': 'chromevox1_options_script', |
| 226 'type': 'none', | 218 'type': 'none', |
| 227 'variables': { | 219 'variables': { |
| 228 'output_file': '<(chromevox_dest_dir)/chromeVoxChromeOptionsScri pt.js', | 220 'output_file': '<(chromevox_dest_dir)/chromeVoxChromeOptionsScri pt.js', |
| 229 }, | 221 }, |
| 230 'sources': [ '<(options_script_loader_file)' ], | 222 'sources': [ '<(chromevox1_options_script_loader_file)' ], |
| 231 'includes': [ 'compress_js.gypi', ], | 223 'includes': [ 'compress_js.gypi', ], |
| 232 }, | 224 }, |
| 233 { | 225 { |
| 234 'target_name': 'chromevox_kbexplorer_script', | 226 'target_name': 'chromevox1_kbexplorer_script', |
| 235 'type': 'none', | 227 'type': 'none', |
| 236 'variables': { | 228 'variables': { |
| 237 'output_file': '<(chromevox_dest_dir)/chromeVoxKbExplorerScript. js', | 229 'output_file': '<(chromevox_dest_dir)/chromeVoxKbExplorerScript. js', |
| 238 }, | 230 }, |
| 239 'sources': [ '<(kbexplorer_loader_file)' ], | 231 'sources': [ '<(chromevox1_kbexplorer_loader_file)' ], |
| 232 'includes': [ 'compress_js.gypi', ], | |
| 233 }, | |
| 234 { | |
| 235 'target_name': 'chromevox2_background_script', | |
| 236 'type': 'none', | |
| 237 'variables': { | |
| 238 'output_file': '<(chromevox_dest_dir)/chromeVox2ChromeBackground Script.js', | |
| 239 }, | |
| 240 'sources': [ | |
| 241 '<(chromevox1_background_script_loader_file)', | |
| 242 '<(chromevox2_background_script_loader_file)', | |
| 243 ], | |
| 240 'includes': [ 'compress_js.gypi', ], | 244 'includes': [ 'compress_js.gypi', ], |
| 241 }, | 245 }, |
| 242 ], | 246 ], |
| 243 }, | 247 }, { |
| 244 ], | |
| 245 ['chromevox_compress_js==0', { | |
| 246 'targets': [ | 248 'targets': [ |
|
David Tseng
2014/10/14 23:10:10
nit: # else chromevox_compress_js==0
| |
| 247 { | 249 { |
| 248 'target_name': 'chromevox_copied_scripts', | 250 'target_name': 'chromevox_copied_scripts', |
| 249 'type': 'none', | 251 'type': 'none', |
| 250 'variables': { | 252 'variables': { |
| 251 'dest_dir': '<(chromevox_dest_dir)', | 253 'dest_dir': '<(chromevox_dest_dir)', |
| 252 }, | 254 }, |
| 253 'sources': [ | 255 'sources': [ |
| 254 '<(background_script_loader_file)', | 256 '<(chromevox1_background_script_loader_file)', |
| 255 '<(content_script_loader_file)', | 257 '<(chromevox1_content_script_loader_file)', |
| 256 '<(kbexplorer_loader_file)', | 258 '<(chromevox1_kbexplorer_loader_file)', |
| 257 '<(options_script_loader_file)', | 259 '<(chromevox1_options_script_loader_file)', |
| 260 '<(chromevox2_background_script_loader_file)', | |
| 258 ], | 261 ], |
| 259 'includes': [ 'copy_js.gypi', ], | 262 'includes': [ 'copy_js.gypi', ], |
| 260 }, | 263 }, |
| 261 ], | 264 ], |
| 262 }], | 265 }], |
| 263 ], | 266 ], |
| 264 }], | 267 }], |
| 265 ], | 268 ], |
| 266 } | 269 } |
| OLD | NEW |