Commit f27bb1da authored by Kevin Marshall's avatar Kevin Marshall Committed by Commit Bot

Allow fuchsia_executable_runner() to specify additional deps targets.

This change allows callers of fuchsia_executable_runner() to provide
deps, as a substitute for the previous support for caller-provided
"data_deps" rules. Standalone data_deps rules were removed because
they could lead to the case where data dependencies are specified but
not reflected in the actual build dependency graph.

Change-Id: I48c4cf8b130fa1fd33bccb0c1a45f29559b88cdd
Reviewed-on: https://chromium-review.googlesource.com/902944
Commit-Queue: Kevin Marshall <kmarshall@chromium.org>
Reviewed-by: default avatarStephen Lanham <slan@chromium.org>
Reviewed-by: default avatarScott Graham <scottmg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#534550}
parent 34aecb34
......@@ -186,22 +186,26 @@ template("fuchsia_executable_runner") {
_exe_name = get_label_info(exe_target, "name")
_exe_path = "${root_out_dir}/${_exe_name}"
# Define the target dependencies as the union of the executable target
# and the invoker's deps.
if (defined(invoker.deps)) {
_combined_deps = invoker.deps + [ exe_target ]
} else {
_combined_deps = [ exe_target ]
}
package(_pkg_target) {
forward_variables_from(invoker, [ "testonly" ])
package_name = _exe_name
binary = _exe_name
deps = [
exe_target,
]
deps = _combined_deps
}
generate_runner_script(_gen_runner_target) {
forward_variables_from(invoker, [ "testonly" ])
runner_script = "exe_runner.py"
generated_script = "$root_build_dir/bin/run_${_exe_name}"
deps = [
exe_target,
]
deps = _combined_deps
exe_path = _exe_path
root_target_name = invoker.target_name
package_name = _exe_name
......@@ -221,9 +225,7 @@ template("fuchsia_executable_runner") {
runner_script = "archive_builder.py"
generated_script =
"$root_build_dir/bin/archive_" + get_label_info(exe_target, "name")
deps = [
exe_target,
]
deps = _combined_deps
exe_path = _exe_path
root_target_name = invoker.target_name
package_name = _exe_name
......
......@@ -453,7 +453,7 @@ if (is_fuchsia) {
exe_target = ":cast_shell"
if (chromecast_branding != "public") {
data_deps = [
deps = [
"//chromecast/internal:fuchsia_internal_data_deps",
]
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment