blob: 76633442bc9c61728f0d10d546e8cd61691450ef [file] [log] [blame]
# Copyright 2015 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.
root_dist_dir = "$root_build_dir/dist"
copy("sky_viewer") {
sources = [
"$root_build_dir/sky_viewer.mojo",
]
outputs = [ "$root_dist_dir/viewer/{{source_file_part}}" ]
deps = [
"//services/sky",
]
}
copy("sky_shell") {
if (is_android) {
sources = [
"$root_build_dir/apks/SkyShell.apk",
]
deps = [
"//sky/shell",
]
} else if (is_ios || is_mac) {
sources = [
"$root_build_dir/SkyShell.app",
]
deps = [
"//sky/shell:shell_struct",
]
} else {
sources = [
"$root_build_dir/sky_shell",
"$root_build_dir/icudtl.dat",
]
deps = [
"//sky/shell",
"//third_party/icu:icudata",
]
}
sky_snapshot_dir =
get_label_info("//sky/tools/sky_snapshot($host_toolchain)", "root_out_dir")
sources += [ "$sky_snapshot_dir/sky_snapshot" ]
deps += [
"//sky/tools/sky_snapshot($host_toolchain)",
]
outputs = [ "$root_dist_dir/shell/{{source_file_part}}" ]
}
if (is_android) {
import("//build/config/android/rules.gni")
copy_ex("sky_engine") {
clear_dir = true
# Note: The package actually ends up in $root_dist_dir/packages/sky_engine/sky_engine
dest = "$root_dist_dir/packages/sky_engine"
sources = [
"$root_gen_dir/dart-pkg/sky_engine",
]
deps = [
"//sky/packages/sky_engine",
]
}
copy_ex("sky_services") {
clear_dir = true
# Note: The package actually ends up in $root_dist_dir/packages/sky_services/sky_services
dest = "$root_dist_dir/packages/sky_services"
sources = [
"$root_gen_dir/dart-pkg/sky_services",
]
deps = [
"//sky/packages/sky_services",
]
}
}
group("dist") {
deps = [
":sky_viewer",
]
if (!is_ios && !is_mac) {
deps += [ ":sky_shell" ]
}
if (is_android) {
deps += [
":sky_engine",
":sky_services",
]
}
}