mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Compute rather than hardcode the host output suffix (flutter/engine#34978)
This commit is contained in:
parent
612396063a
commit
aa0adcdb7c
@ -205,18 +205,16 @@ bin_to_linkable("platform_strong_dill_linkable") {
|
||||
|
||||
if (host_os == "mac" && (target_cpu == "arm" || target_cpu == "arm64")) {
|
||||
action("create_arm_gen_snapshot") {
|
||||
if (host_cpu == "arm64") {
|
||||
clang_dir = "clang_arm64"
|
||||
} else {
|
||||
clang_dir = "clang_x64"
|
||||
}
|
||||
output_dir = "$root_out_dir/$clang_dir"
|
||||
host_output_dir = get_label_info(
|
||||
"//third_party/dart/runtime/bin:gen_snapshot($host_toolchain)",
|
||||
"root_out_dir")
|
||||
clang_dir = rebase_path(host_output_dir, root_build_dir)
|
||||
script = "//flutter/sky/tools/create_macos_gen_snapshots.py"
|
||||
visibility = [ ":*" ]
|
||||
deps = [ "//third_party/dart/runtime/bin:gen_snapshot($host_toolchain)" ]
|
||||
args = [
|
||||
"--dst",
|
||||
rebase_path(output_dir),
|
||||
rebase_path(host_output_dir),
|
||||
"--clang-dir",
|
||||
clang_dir,
|
||||
]
|
||||
@ -225,13 +223,13 @@ if (host_os == "mac" && (target_cpu == "arm" || target_cpu == "arm64")) {
|
||||
"--armv7-out-dir",
|
||||
rebase_path("$root_out_dir"),
|
||||
]
|
||||
outputs = [ "$output_dir/gen_snapshot_armv7" ]
|
||||
outputs = [ "$host_output_dir/gen_snapshot_armv7" ]
|
||||
} else {
|
||||
args += [
|
||||
"--arm64-out-dir",
|
||||
rebase_path("$root_out_dir"),
|
||||
]
|
||||
outputs = [ "$output_dir/gen_snapshot_arm64" ]
|
||||
outputs = [ "$host_output_dir/gen_snapshot_arm64" ]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user