pub struct WorkspaceBuildScripts {
outputs: ArenaMap<Package, BuildScriptOutput>,
error: Option<String>,
}Expand description
Output of the build script and proc-macro building steps for a workspace.
Fields§
§outputs: ArenaMap<Package, BuildScriptOutput>§error: Option<String>Implementations§
Source§impl WorkspaceBuildScripts
impl WorkspaceBuildScripts
Sourcepub(crate) fn run_for_workspace(
config: &CargoConfig,
workspace: &CargoWorkspace,
progress: &dyn Fn(String),
sysroot: &Sysroot,
toolchain: Option<&Version>,
) -> Result<WorkspaceBuildScripts>
pub(crate) fn run_for_workspace( config: &CargoConfig, workspace: &CargoWorkspace, progress: &dyn Fn(String), sysroot: &Sysroot, toolchain: Option<&Version>, ) -> Result<WorkspaceBuildScripts>
Runs the build scripts for the given workspace
Sourcepub(crate) fn run_once(
config: &CargoConfig,
workspaces: &[&CargoWorkspace],
progress: &dyn Fn(String),
working_directory: &AbsPathBuf,
) -> Result<Vec<WorkspaceBuildScripts>>
pub(crate) fn run_once( config: &CargoConfig, workspaces: &[&CargoWorkspace], progress: &dyn Fn(String), working_directory: &AbsPathBuf, ) -> Result<Vec<WorkspaceBuildScripts>>
Runs the build scripts by invoking the configured command once. This populates the outputs for all passed in workspaces.
pub fn error(&self) -> Option<&str>
pub(crate) fn get_output(&self, idx: Package) -> Option<&BuildScriptOutput>
Sourcepub(crate) fn rustc_crates(
rustc: &CargoWorkspace,
current_dir: &AbsPath,
extra_env: &FxHashMap<String, Option<String>>,
sysroot: &Sysroot,
) -> Self
pub(crate) fn rustc_crates( rustc: &CargoWorkspace, current_dir: &AbsPath, extra_env: &FxHashMap<String, Option<String>>, sysroot: &Sysroot, ) -> Self
Assembles build script outputs for the rustc crates via --print target-libdir.
fn run_per_ws( cmd: Command, workspace: &CargoWorkspace, progress: &dyn Fn(String), ) -> Result<WorkspaceBuildScripts>
fn run_command( cmd: Command, with_output_for: impl FnMut(&PackageId, &mut dyn FnMut(&str, &mut BuildScriptOutput)), progress: &dyn Fn(String), ) -> Result<Option<String>>
fn build_command( config: &CargoConfig, allowed_features: &FxHashSet<String>, manifest_path: &ManifestPath, target_dir: &Utf8Path, current_dir: &AbsPath, sysroot: &Sysroot, toolchain: Option<&Version>, ) -> Result<(Option<LockfileCopy>, Command)>
Trait Implementations§
Source§impl Clone for WorkspaceBuildScripts
impl Clone for WorkspaceBuildScripts
Source§impl Debug for WorkspaceBuildScripts
impl Debug for WorkspaceBuildScripts
Source§impl Default for WorkspaceBuildScripts
impl Default for WorkspaceBuildScripts
impl Eq for WorkspaceBuildScripts
Source§impl PartialEq for WorkspaceBuildScripts
impl PartialEq for WorkspaceBuildScripts
impl StructuralPartialEq for WorkspaceBuildScripts
Auto Trait Implementations§
impl Freeze for WorkspaceBuildScripts
impl RefUnwindSafe for WorkspaceBuildScripts
impl Send for WorkspaceBuildScripts
impl Sync for WorkspaceBuildScripts
impl Unpin for WorkspaceBuildScripts
impl UnsafeUnpin for WorkspaceBuildScripts
impl UnwindSafe for WorkspaceBuildScripts
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more