Skip to content

Commit

Permalink
Notice non-toplevel dll dependencies in rustbuild
Browse files Browse the repository at this point in the history
Previously Cargo would hardlink all the dependencies into the "root" as
foo.dll and the `toplevel` array would get populated with these, but
that's no longer the case. Instead, cargo will only do this for the
final artifacts/final libraries.

Rustbuild is updated to continue looping through the artifacts mentioned
instead of early-returning. This should fix the bug.

@alexcrichton found the cause of this and suggested this fix.
  • Loading branch information
Mark-Simulacrum authored and alexcrichton committed Jun 30, 2018
1 parent ad97f8b commit 3d68774
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/bootstrap/compile.rs
Expand Up @@ -1049,22 +1049,22 @@ pub fn run_cargo(builder: &Builder, cargo: &mut Command, stamp: &Path, is_check:
!filename.ends_with(".lib") &&
!is_dylib(&filename) &&
!(is_check && filename.ends_with(".rmeta")) {
return;
continue;
}

let filename = Path::new(&*filename);

// If this was an output file in the "host dir" we don't actually
// worry about it, it's not relevant for us.
if filename.starts_with(&host_root_dir) {
return;
continue;
}

// If this was output in the `deps` dir then this is a precise file
// name (hash included) so we start tracking it.
if filename.starts_with(&target_deps_dir) {
deps.push(filename.to_path_buf());
return;
continue;
}

// Otherwise this was a "top level artifact" which right now doesn't
Expand Down

0 comments on commit 3d68774

Please sign in to comment.