pub struct Rustc {
pub target: TargetSelection,
pub build_compiler: Compiler,
crates: Vec<String>,
}
Expand description
Build rustc using the passed build_compiler
.
- Makes sure that
build_compiler
has a standard library prepared for its host target, so that it can compile build scripts and proc macros when building thisrustc
. - Makes sure that
build_compiler
has a standard library prepared fortarget
, so that the builtrustc
can link to it and use it at runtime.
Fields§
§target: TargetSelection
The target on which rustc will run (its host).
build_compiler: Compiler
The previous compiler used to compile this rustc.
crates: Vec<String>
Whether to build a subset of crates, rather than the whole compiler.
This should only be requested by the user, not used within bootstrap itself. Using it within bootstrap can lead to confusing situation where lints are replayed in two different steps.
Implementations§
Trait Implementations§
Source§impl Step for Rustc
impl Step for Rustc
Source§fn run(self, builder: &Builder<'_>) -> Self::Output
fn run(self, builder: &Builder<'_>) -> Self::Output
Builds the compiler.
This will build the compiler for a particular stage of the build using
the build_compiler
targeting the target
architecture. The artifacts
created will also be linked into the sysroot directory.
Source§const IS_HOST: bool = true
const IS_HOST: bool = true
run.target
passed to the make_run
function of
this Step will be determined based on the --host
flag.
If this value is false, then they will be determined based on the --target
flag. Read moreSource§const DEFAULT: bool = false
const DEFAULT: bool = false
describe
macro in Builder::get_step_descriptions
. Read moreSource§type Output = BuiltRustc
type Output = BuiltRustc
Step::run
.Source§fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_>
fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_>
Step
should be run when given specific paths (e.g., x build $path
).Source§fn make_run(run: RunConfig<'_>)
fn make_run(run: RunConfig<'_>)
Step
handler when not triggered indirectly by other Step
s using Builder::ensure
.
For example, ./x.py test bootstrap
runs this for test::Bootstrap
. Similarly, ./x.py test
runs it for every step
that is listed by the describe
macro in Builder::get_step_descriptions
.Source§fn metadata(&self) -> Option<StepMetadata>
fn metadata(&self) -> Option<StepMetadata>
impl Eq for Rustc
impl StructuralPartialEq for Rustc
Auto Trait Implementations§
impl Freeze for Rustc
impl RefUnwindSafe for Rustc
impl Send for Rustc
impl Sync for Rustc
impl Unpin for Rustc
impl UnwindSafe for Rustc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Pointable for T
impl<T> Pointable for T
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 96 bytes