| OLD | NEW |
| 1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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 import("//build/util/java_action.gni") | 5 import("//build/util/java_action.gni") |
| 6 | 6 |
| 7 declare_args() { | 7 declare_args() { |
| 8 # Control whether the JavaScript files shipped with Chrome on iOS are | 8 # Control whether the JavaScript files shipped with Chrome on iOS are |
| 9 # compiled with closure_compiler or not. Useful for debugging. | 9 # compiled with closure_compiler or not. Useful for debugging. |
| 10 compile_javascript = true | 10 compile_javascript = true |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 compile_js_target_name = target_name + "_compile_js" | 106 compile_js_target_name = target_name + "_compile_js" |
| 107 | 107 |
| 108 java_action_foreach(compile_js_target_name) { | 108 java_action_foreach(compile_js_target_name) { |
| 109 visibility = [ ":$_target_name" ] | 109 visibility = [ ":$_target_name" ] |
| 110 script = closure_compiler_path | 110 script = closure_compiler_path |
| 111 sources = invoker.sources | 111 sources = invoker.sources |
| 112 outputs = [ | 112 outputs = [ |
| 113 "$target_gen_dir/{{source_file_part}}", | 113 "$target_gen_dir/{{source_file_part}}", |
| 114 ] | 114 ] |
| 115 | 115 |
| 116 # TODO(crbug.com/487804): need to enable the following compilation checks | |
| 117 # once the corresponding errors have been fixed: | |
| 118 # --jscomp_error=checkTypes | |
| 119 # --jscomp_error=checkVars | |
| 120 # --jscomp_error=missingProperties | |
| 121 # --jscomp_error=undefinedVars | |
| 122 args = [ | 116 args = [ |
| 123 "--compilation_level", | 117 "--compilation_level", |
| 124 "SIMPLE_OPTIMIZATIONS", | 118 "SIMPLE_OPTIMIZATIONS", |
| 119 "--jscomp_error=checkTypes", |
| 120 "--jscomp_error=checkVars", |
| 121 "--jscomp_error=missingProperties", |
| 122 "--jscomp_error=undefinedVars", |
| 125 "--jscomp_error=accessControls", | 123 "--jscomp_error=accessControls", |
| 126 "--jscomp_error=ambiguousFunctionDecl", | 124 "--jscomp_error=ambiguousFunctionDecl", |
| 127 "--jscomp_error=constantProperty", | 125 "--jscomp_error=constantProperty", |
| 128 "--jscomp_error=deprecated", | 126 "--jscomp_error=deprecated", |
| 129 "--jscomp_error=externsValidation", | 127 "--jscomp_error=externsValidation", |
| 130 "--jscomp_error=globalThis", | 128 "--jscomp_error=globalThis", |
| 131 "--jscomp_error=invalidCasts", | 129 "--jscomp_error=invalidCasts", |
| 132 "--jscomp_error=missingReturn", | 130 "--jscomp_error=missingReturn", |
| 133 "--jscomp_error=nonStandardJsDocs", | 131 "--jscomp_error=nonStandardJsDocs", |
| 134 "--jscomp_error=suspiciousCode", | 132 "--jscomp_error=suspiciousCode", |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 "visibility", | 262 "visibility", |
| 265 ]) | 263 ]) |
| 266 | 264 |
| 267 sources = invoker.sources | 265 sources = invoker.sources |
| 268 outputs = [ | 266 outputs = [ |
| 269 "{{bundle_resources_dir}}/{{source_file_part}}", | 267 "{{bundle_resources_dir}}/{{source_file_part}}", |
| 270 ] | 268 ] |
| 271 } | 269 } |
| 272 } | 270 } |
| 273 } | 271 } |
| OLD | NEW |