mirror of
https://github.com/rust-lang/rust.git
synced 2025-04-28 11:07:42 +00:00
Small fixups
- use `path` instead of `paths` - don't mark rust-analyzer as an optional tool - print the cargo command that's run in the proc-macro-test build script this originally was part of a change to fix `test --stage 0 rust-analyzer`, but I'm going to leave that for a separate PR so it's easier to review.
This commit is contained in:
parent
e0add21c2b
commit
ee09dc5510
@ -312,7 +312,7 @@ impl Step for RustAnalyzer {
|
|||||||
const DEFAULT: bool = true;
|
const DEFAULT: bool = true;
|
||||||
|
|
||||||
fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_> {
|
fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_> {
|
||||||
run.paths(&["src/tools/rust-analyzer"])
|
run.path("src/tools/rust-analyzer")
|
||||||
}
|
}
|
||||||
|
|
||||||
fn make_run(run: RunConfig<'_>) {
|
fn make_run(run: RunConfig<'_>) {
|
||||||
|
@ -721,7 +721,7 @@ impl Step for RustAnalyzer {
|
|||||||
mode: Mode::ToolStd,
|
mode: Mode::ToolStd,
|
||||||
path: "src/tools/rust-analyzer",
|
path: "src/tools/rust-analyzer",
|
||||||
extra_features: vec!["rust-analyzer/in-rust-tree".to_owned()],
|
extra_features: vec!["rust-analyzer/in-rust-tree".to_owned()],
|
||||||
is_optional_tool: true,
|
is_optional_tool: false,
|
||||||
source_type: SourceType::InTree,
|
source_type: SourceType::InTree,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -62,7 +62,7 @@ fn main() {
|
|||||||
Command::new(toolchain::cargo())
|
Command::new(toolchain::cargo())
|
||||||
};
|
};
|
||||||
|
|
||||||
let output = cmd
|
cmd
|
||||||
.current_dir(&staging_dir)
|
.current_dir(&staging_dir)
|
||||||
.args(&["build", "-p", "proc-macro-test-impl", "--message-format", "json"])
|
.args(&["build", "-p", "proc-macro-test-impl", "--message-format", "json"])
|
||||||
// Explicit override the target directory to avoid using the same one which the parent
|
// Explicit override the target directory to avoid using the same one which the parent
|
||||||
@ -70,9 +70,11 @@ fn main() {
|
|||||||
// This can happen when `CARGO_TARGET_DIR` is set or global config forces all cargo
|
// This can happen when `CARGO_TARGET_DIR` is set or global config forces all cargo
|
||||||
// instance to use the same target directory.
|
// instance to use the same target directory.
|
||||||
.arg("--target-dir")
|
.arg("--target-dir")
|
||||||
.arg(&target_dir)
|
.arg(&target_dir);
|
||||||
.output()
|
|
||||||
.unwrap();
|
println!("Running {:?}", cmd);
|
||||||
|
|
||||||
|
let output = cmd.output().unwrap();
|
||||||
if !output.status.success() {
|
if !output.status.success() {
|
||||||
println!("proc-macro-test-impl failed to build");
|
println!("proc-macro-test-impl failed to build");
|
||||||
println!("============ stdout ============");
|
println!("============ stdout ============");
|
||||||
|
Loading…
Reference in New Issue
Block a user