Skip to content

Re-do: Progress on #9451 #10108

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 19 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ num_cpus = "1.0"
opener = "0.5"
os_info = "3.0.7"
percent-encoding = "2.0"
regex = "1" # Issue 9451
rustfix = "0.6.0"
semver = { version = "1.0.3", features = ["serde"] }
serde = { version = "1.0.123", features = ["derive"] }
Expand Down
1 change: 0 additions & 1 deletion ci/validate-man.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
# This script validates that there aren't any changes to the man pages.

set -e

cd src/doc

changes=$(git status --porcelain)
Expand Down
5 changes: 5 additions & 0 deletions src/cargo/core/compiler/build_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ impl BuildConfig {
mode: CompileMode,
) -> CargoResult<BuildConfig> {
let cfg = config.build_config()?;

let requested_kinds = CompileKind::from_requested_targets(config, requested_targets)?;
if jobs == Some(0) {
anyhow::bail!("jobs must be at least 1")
Expand Down Expand Up @@ -105,6 +106,10 @@ impl BuildConfig {
_ => bail!("only one `--target` argument is supported"),
}
}

pub fn set_requested_kind_at(&mut self, k: CompileKind, idx: usize) {
self.requested_kinds[idx] = k;
}
}

#[derive(Clone, Copy, Debug, PartialEq, Eq)]
Expand Down
3 changes: 3 additions & 0 deletions src/cargo/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ use std::fmt;
pub use crate::util::errors::{InternalError, VerboseError};
pub use crate::util::{indented_lines, CargoResult, CliError, CliResult, Config};

// Tests
pub use crate::ops::{PerPackageTarget, PerPackageTargetMode};

pub const CARGO_ENV: &str = "CARGO";

#[macro_use]
Expand Down
Loading