| # Copyright 2019 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/config.gni") |
| import("//build/packages/prebuilt_package.gni") |
| import("//src/chromium/build_args.gni") |
| |
| declare_args() { |
| # If true then the most recent canary version of the Cast Runner is used, |
| # otherwise the most recently validated version is used. |
| use_cast_runner_canary = false |
| } |
| |
| prebuilt_archive_base_path = "//prebuilt/third_party/cast_runner" |
| debug_archive_base_path = "//prebuilt/build_ids/" + target_cpu + "/chromium" |
| |
| if (use_cast_runner_canary) { |
| prebuilt_archive_base_path += "_latest" |
| debug_archive_base_path += "_latest" |
| } |
| |
| group("cast") { |
| public_deps = [ ":cast_runner" ] |
| } |
| |
| group("cast_runner") { |
| deps = [ |
| ":cast_runner_config", |
| ":cast_runner_pkg", |
| ] |
| } |
| |
| config_data("cast_runner_config") { |
| visibility = [ ":cast_runner" ] |
| |
| for_pkg = "appmgr" |
| |
| sources = [ "config/cast_scheme_map.config" ] |
| |
| outputs = [ "scheme_map/cast.config" ] |
| } |
| |
| prebuilt_package("cast_runner_pkg") { |
| visibility = [ ":cast_runner" ] |
| |
| package_name = "cast_runner" |
| archive = |
| prebuilt_archive_base_path + "/arch/" + target_cpu + "/cast_runner.far" |
| if (chromium_build_dir != "") { |
| archive = |
| chromium_build_dir + "/gen/fuchsia/runners/cast_runner/cast_runner.far" |
| } |
| debug_archive = debug_archive_base_path + "/cast_runner.symbols.tar.bz2" |
| } |