Skip to content

Commit

Permalink
Rollup merge of rust-lang#52594 - Mark-Simulacrum:error-index-stage0,…
Browse files Browse the repository at this point in the history
… r=alexcrichton

Run the error index tool against the sysroot libdir

Previously when building the error index tool in stage 0 we would
attempt to use stage 0 libraries, but because it depends on rustdoc,
those don't exist: rustdoc is built against stage 1 libraries.

This patch aligns those two and passes the stage 1 libdir to the error
index.

@GuillaumeGomez discovered that this hasn't worked (presumably for a long time now, but not sure).

r? @alexcrichton
  • Loading branch information
kennytm committed Jul 22, 2018
2 parents aea141e + ab0092e commit de3cf0c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bootstrap/tool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ pub fn prepare_tool_cargo(

macro_rules! tool {
($($name:ident, $path:expr, $tool_name:expr, $mode:expr $(,llvm_tools = $llvm:expr)*;)+) => {
#[derive(Copy, Clone)]
#[derive(Copy, PartialEq, Eq, Clone)]
pub enum Tool {
$(
$name,
Expand Down Expand Up @@ -640,7 +640,7 @@ impl<'a> Builder<'a> {
fn prepare_tool_cmd(&self, compiler: Compiler, tool: Tool, cmd: &mut Command) {
let host = &compiler.host;
let mut lib_paths: Vec<PathBuf> = vec![
if compiler.stage == 0 {
if compiler.stage == 0 && tool != Tool::ErrorIndex {
self.build.rustc_snapshot_libdir()
} else {
PathBuf::from(&self.sysroot_libdir(compiler, compiler.host))
Expand Down

0 comments on commit de3cf0c

Please sign in to comment.