2023-10-24 14:36:19 +00:00
|
|
|
# Copyright (c) 2013 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.
|
|
|
|
|
|
|
|
# Defines the configuration of RBE.
|
|
|
|
|
2024-04-12 22:06:32 +00:00
|
|
|
_dart_root = get_path_info("../..", "abspath")
|
|
|
|
|
2023-10-24 14:36:19 +00:00
|
|
|
declare_args() {
|
|
|
|
# Set to true to enable distributed compilation using RBE.
|
|
|
|
use_rbe = false
|
|
|
|
|
2024-01-10 11:38:43 +00:00
|
|
|
# Set to the operating system to use in the RBE pool
|
|
|
|
rbe_os = "linux"
|
|
|
|
|
|
|
|
# Set to the architecture used in the RBE pool.
|
|
|
|
rbe_cpu = "x64"
|
2023-10-24 14:36:19 +00:00
|
|
|
|
2024-01-10 11:38:43 +00:00
|
|
|
# Set to the docker image to use in the RBE.
|
|
|
|
rbe_image = "docker://gcr.io/cloud-marketplace/google/debian11@sha256:69e2789c9f3d28c6a0f13b25062c240ee7772be1f5e6d41bb4680b63eae6b304"
|
|
|
|
|
2024-04-12 22:06:32 +00:00
|
|
|
# Do expensive RBE compilations both locally and remotely, whatever is faster.
|
|
|
|
rbe_expensive_exec_strategy = "racing"
|
|
|
|
|
|
|
|
rbe_exec_root = rebase_path("//", root_build_dir)
|
2023-10-24 14:36:19 +00:00
|
|
|
|
2024-04-12 22:06:32 +00:00
|
|
|
rbe_dir = rebase_path(_dart_root + "/buildtools/reclient", root_build_dir)
|
2023-10-24 14:36:19 +00:00
|
|
|
}
|
2024-01-10 11:38:43 +00:00
|
|
|
|
|
|
|
declare_args() {
|
|
|
|
if (rbe_os == "linux") {
|
|
|
|
rbe_os_family = "Linux"
|
|
|
|
} else if (rbe_os == "win") {
|
|
|
|
rbe_os_family = "Windows"
|
|
|
|
} else if (rbe_os == "mac") {
|
|
|
|
rbe_os_family = "Mac"
|
|
|
|
} else {
|
|
|
|
rbe_os_family = rbe_os
|
|
|
|
}
|
|
|
|
|
|
|
|
# Set to the desired fully qualified RBE platform.
|
|
|
|
rbe_platform = "container-image=$rbe_image,OSFamily=$rbe_os_family"
|
|
|
|
}
|
|
|
|
|
|
|
|
rewrapper_args = [
|
|
|
|
"$rbe_dir/rewrapper",
|
|
|
|
"--exec_root=$rbe_exec_root",
|
|
|
|
"--platform=$rbe_platform",
|
|
|
|
]
|