BUILD.gn 2.1 KB
Newer Older
A
Adam Barth 已提交
1 2 3 4
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

5
group("flutter") {
A
Adam Barth 已提交
6
  testonly = true
7

8
  public_deps = [
9 10 11 12
    "$flutter_root/lib/snapshot:compile_platform",
    "$flutter_root/lib/snapshot:generate_snapshot_bin",
    "$flutter_root/sky",
    "$flutter_root/third_party/txt",
13
  ]
P
P.Y. Laligand 已提交
14

15 16
  if (!is_fuchsia) {
    if (current_toolchain == host_toolchain) {
17
      public_deps += [
18
        "$flutter_root/frontend_server",
19
        "//third_party/dart:create_sdk",
20 21 22 23
      ]
    }
  }

A
Adam Barth 已提交
24
  if (is_fuchsia) {
25
    public_deps += [
26 27 28 29
      "$flutter_root/content_handler",
      "$flutter_root/content_handler:aot_content_handler",
      "$flutter_root/examples",
      "$flutter_root/flow",
A
Adam Barth 已提交
30
    ]
31
  }
32 33 34

  # If on the host, compile all unittests targets.
  if (current_toolchain == host_toolchain) {
35
    if (is_mac) {
36 37 38 39
      public_deps += [
        "$flutter_root/shell/platform/darwin:flutter_channels_unittests",
        "$flutter_root/shell/platform/embedder:flutter_embedder_framework",
      ]
40
    }
41
    if (!is_win) {
42 43 44 45
      public_deps += [
        "$flutter_root/shell/platform/embedder:embedder_unittests",
        "$flutter_root/shell/platform/embedder:flutter_engine",
      ]
46
    }
47
    public_deps += [
48 49 50 51 52 53
      "$flutter_root/flow:flow_unittests",
      "$flutter_root/fml:fml_unittests",
      "$flutter_root/sky/engine/wtf:wtf_unittests",
      "$flutter_root/synchronization:synchronization_unittests",
      "$flutter_root/third_party/txt:txt_benchmarks",
      "$flutter_root/third_party/txt:txt_unittests",
54
      "//garnet/public/lib/fxl:fxl_unittests",
55 56
    ]
  }
A
Adam Barth 已提交
57
}
58

59
config("config") {
60
  include_dirs = [ ".." ]
61 62
}

63
if (is_fuchsia) {
64
  import("//build/package.gni")
65 66

  package("package") {
67
    system_image = true
68 69 70 71
    testonly = true

    package_name = "flutter"

72 73 74
    deps = [
      ":flutter",
    ]
75 76 77

    binaries = [
      {
78
        name = "flutter_jit_runner"
79 80 81 82 83 84 85
      },
      {
        name = "flutter_aot_runner"
      },
    ]
  }
} else {
86 87 88 89
  group("dist") {
    testonly = true

    deps = [
90
      "$flutter_root/sky/dist",
91 92
    ]
  }
93
}