| OLD | NEW |
| 1 # Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 # Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 # for details. All rights reserved. Use of this source code is governed by a | 2 # for details. All rights reserved. Use of this source code is governed by a |
| 3 # BSD-style license that can be found in the LICENSE file. | 3 # BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 import("../invoke_dart.gni") | 5 import("//build/compiled_action.gni") |
| 6 import("../application_snapshot.gni") |
| 6 | 7 |
| 7 group("dartanalyzer") { | 8 group("dartanalyzer") { |
| 8 deps = [ | 9 deps = [ |
| 9 ":generate_dartanalyzer_snapshot", | 10 ":generate_dartanalyzer_snapshot", |
| 10 ":generate_summary_spec", | 11 ":generate_summary_spec", |
| 11 ":generate_summary_strong", | 12 ":generate_summary_strong", |
| 12 ] | 13 ] |
| 13 } | 14 } |
| 14 | 15 |
| 15 analyzer_files = exec_script("../../tools/list_dart_files.py", | 16 analyzer_files = exec_script("../../tools/list_dart_files.py", |
| (...skipping 14 matching lines...) Expand all Loading... |
| 30 } | 31 } |
| 31 | 32 |
| 32 sdk_lib_files = exec_script("../../tools/list_dart_files.py", | 33 sdk_lib_files = exec_script("../../tools/list_dart_files.py", |
| 33 [ rebase_path("../../sdk/lib") ], | 34 [ rebase_path("../../sdk/lib") ], |
| 34 "list lines") | 35 "list lines") |
| 35 | 36 |
| 36 template("generate_summary") { | 37 template("generate_summary") { |
| 37 assert(defined(invoker.type), "Must specify the summary type") | 38 assert(defined(invoker.type), "Must specify the summary type") |
| 38 type = invoker.type | 39 type = invoker.type |
| 39 assert(type == "spec" || type == "strong") | 40 assert(type == "spec" || type == "strong") |
| 40 invoke_dart(target_name) { | 41 compiled_action(target_name) { |
| 42 tool = "../../runtime/bin:dart" |
| 41 inputs = sdk_lib_files + analyzer_files | 43 inputs = sdk_lib_files + analyzer_files |
| 42 | 44 |
| 43 output = "$root_gen_dir/$type.sum" | 45 output = "$root_gen_dir/$type.sum" |
| 44 outputs = [ | 46 outputs = [ |
| 45 output, | 47 output, |
| 46 ] | 48 ] |
| 47 | 49 |
| 48 dot_packages = rebase_path("../../.packages") | 50 dot_packages = rebase_path("../../.packages") |
| 49 build_sdk_summaries = | 51 build_sdk_summaries = |
| 50 rebase_path("../../pkg/analyzer/tool/summary/build_sdk_summaries.dart") | 52 rebase_path("../../pkg/analyzer/tool/summary/build_sdk_summaries.dart") |
| 51 abs_output = rebase_path(output) | 53 abs_output = rebase_path(output) |
| 52 | 54 |
| 53 args = [ | 55 args = [ |
| 54 "--packages=$dot_packages", | 56 "--packages=$dot_packages", |
| 55 build_sdk_summaries, | 57 build_sdk_summaries, |
| 56 "build-$type", | 58 "build-$type", |
| 57 abs_output, | 59 abs_output, |
| 58 rebase_path("../../sdk"), | 60 rebase_path("../../sdk"), |
| 59 ] | 61 ] |
| 60 } | 62 } |
| 61 } | 63 } |
| 62 | 64 |
| 63 generate_summary("generate_summary_spec") { | 65 generate_summary("generate_summary_spec") { |
| 64 type = "spec" | 66 type = "spec" |
| 65 } | 67 } |
| 66 | 68 |
| 67 generate_summary("generate_summary_strong") { | 69 generate_summary("generate_summary_strong") { |
| 68 type = "strong" | 70 type = "strong" |
| 69 } | 71 } |
| OLD | NEW |