Expand description
Sanity checking and tool selection performed by bootstrap.
This module ensures that the build environment is correctly set up before executing any build tasks. It verifies required programs exist (like git and cmake when needed), selects some tools based on the environment (like the Python interpreter), and validates that C compilers for cross-compiling are available.
In theory if we get past this phase itβs a bug if a build fails, but in practice thatβs likely not true!
Re-exportsΒ§
use std::collections::HashMap;πuse std::collections::HashSet;πuse std::ffi::OsStr;πuse std::ffi::OsString;πuse std::path::PathBuf;πuse std::env;πuse std::env;πuse std::fs;πuse crate::core::build_steps::tool;πuse crate::core::builder::Builder;πuse crate::core::config::flags::Subcommand;πuse crate::core::config::CompilerBuiltins;πuse crate::core::config::DebuggerPath;πuse crate::core::config::Target;πuse crate::core::session::Session;πuse crate::utils::exec::command;πuse crate::utils::helpers;πuse crate::utils::helpers::t;π
StructsΒ§
ConstantsΒ§
- LIBSTDCXX_
MIN_ πVERSION_ THRESHOLD - Minimum version threshold for libstdc++ required when using prebuilt LLVM
from CI (with
llvm.download-ci-llvmoption). - STAG
E0_ πMISSING_ TARGETS - During sanity checks, we search for target tuples to determine if they exist in the compilerβs
built-in target list (
rustc --print target-list). While a target tuple may be present in the in-tree compiler, the stage 0 compiler might not yet know about it (assuming not operating with local-rebuild). In such cases, we handle the targets missing from stage 0 in this list.
FunctionsΒ§
- check π