Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(90)

Unified Diff: BUILD.gn

Issue 2547013003: Fuchsia: Build an OS image that includes Dart's test suite. (Closed)
Patch Set: Fix copyright year. Fix comment. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/bin/directory_fuchsia.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: BUILD.gn
diff --git a/BUILD.gn b/BUILD.gn
index 60a0dbd24c0a830149f5aa91025825e952eb35f2..5c483f2c464648922f09030b303499a181fcd14f 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -167,3 +167,77 @@ group("samples") {
"runtime/bin:sample_extension",
]
}
+
+
+# The rules below build a qemu Fuchsia OS image that includes the Dart tree
+# under /system/test/dart. Building this image is gated by the GN argument
+# 'dart_build_fuchsia_test_image' because building the image is slow.
+if (defined(is_fuchsia) && (is_fuchsia)) {
+ declare_args() {
+ dart_build_fuchsia_test_image = false
+ }
+
+ if (dart_build_fuchsia_test_image) {
+ action("generate_dart_test_manifest") {
+ testonly = true
+
+ deps = [
+ "//packages/gn:mkbootfs",
+ ]
+
+ output_prefix = "$target_gen_dir/dart_test_tree"
+ outputs = [
+ "$output_prefix.manifest",
+ ]
+
+ mode = "release"
+ if (is_debug) {
+ mode = "debug"
+ }
+
+ mkbootfs_gen = get_label_info("//packages/gn:mkbootfs", "target_gen_dir")
+ user_manifest = "$mkbootfs_gen/user.bootfs.manifest"
+
+ script = "tools/gen_fuchsia_test_manifest.py"
+ args = [
+ "-m",
+ mode,
+ "-u",
+ rebase_path(user_manifest),
+ "-o",
+ rebase_path(output_prefix),
+ ]
+ }
+
+ action("generate_dart_test_image") {
+ testonly = true
+ deps = [
+ "runtime/bin:dart",
+ "runtime/bin:run_vm_tests",
+ "runtime/bin:process_test",
+ ":generate_dart_test_manifest",
+ ]
+
+ input = "$target_gen_dir/dart_test_tree.manifest"
+ inputs = [
+ input,
+ ]
+
+ output = "$root_out_dir/dart_test_tree.bin"
+ outputs = [
+ output,
+ ]
+
+ script = "//packages/gn/make_bootfs.py"
+ args = [
+ "--manifest",
+ rebase_path(input),
+ "--output-file",
+ rebase_path(output),
+ "--build-id-map",
+ rebase_path("$target_gen_dir/build_id_map"),
+ "--compress",
+ ]
+ }
+ }
+}
« no previous file with comments | « no previous file | runtime/bin/directory_fuchsia.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698