load("@prelude//platforms:defs.bzl", "host_configuration") load(":defs.bzl", "execution_platform") # Where every action runs: locally, against the BuildBuddy cache. Registered by # `[build] execution_platforms` in .buckconfig — and, because a toolchain is # itself a target in the prelude cell, by `[parser] target_platform_detector_spec` # there too. Setting only the first leaves every rustc action on the prelude's # uncached default. execution_platform( name = "cache", cpu_configuration = host_configuration.cpu, os_configuration = host_configuration.os, use_windows_path_separators = host_info().os.is_windows, visibility = ["PUBLIC"], ) # The same platform, allowed to dispatch. The properties name the worker to run # on; BuildBuddy matches an action against its executor pool by these. execution_platform( name = "remote", cpu_configuration = host_configuration.cpu, os_configuration = host_configuration.os, remote_enabled = True, remote_execution_properties = { "OSFamily": "Linux", # This project's own image, built by .gitlab-ci.yml from ci/rbe.Dockerfile # and published to its container registry. The public # gcr.io/flame-public/rbe-ubuntu24-04 carries neither pkg-config nor # libasound2-dev, and alsa-sys's build script needs the first to find the # second — so with that image the graph could not be built remotely at # all, whatever the executor was asked to do. # # Still 24.04, and for the reason that image was pinned to it: a build # script is compiled on the host and *run* on the worker, and 22.04's # glibc 2.35 is old enough that thiserror's died with "GLIBC_2.39 not # found" before a single crate was compiled. frq hit the same floor from # the other side (jolt itself needs 2.38) and moved for the same reason. # # By digest, not by tag. An execution platform ought to name bytes, and # here it has to: the executor caches an image under the reference it # was given, so a rebuilt `:latest` kept serving the old layers and the # build went on failing for a package the image already had. The # pipeline prints this line on every publish. "container-image": "docker://registry.gitlab.com/nandithebull/jolt-native/rbe@sha256:3de0e1c922b35f40023db8d50bbf606a3cb8168b5b8b4a27aac08f06cf7e0328", }, use_windows_path_separators = host_info().os.is_windows, visibility = ["PUBLIC"], ) # A *target* platform, unlike the two above: this is what a graph is built # for, not where the building runs. Naming it on a configured_alias moves the # target configuration and leaves the execution platform alone, so build # scripts and proc macros still compile and run on the host. platform( name = "android-arm64", constraint_values = [ "prelude//os/constraints:os[android]", "prelude//cpu/constraints:cpu[arm64]", ], visibility = ["PUBLIC"], )