Skip to content

Commit

Permalink
Add rustc-dev to nightly default and complete profiles
Browse files Browse the repository at this point in the history
  • Loading branch information
cuviper authored and Mark-Simulacrum committed Oct 15, 2019
1 parent 3a05616 commit 4c906dc
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/tools/build-manifest/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -427,6 +427,13 @@ impl Builder {
"rls-preview", "rust-src", "llvm-tools-preview",
"lldb-preview", "rust-analysis", "miri-preview"
]);

// The compiler libraries are not stable for end users, but `rustc-dev` was only recently
// split out of `rust-std`. We'll include it by default as a transition for nightly users.
if self.rust_release == "nightly" {
self.extend_profile("default", &mut manifest.profiles, &["rustc-dev"]);
self.extend_profile("complete", &mut manifest.profiles, &["rustc-dev"]);
}
}

fn add_renames_to(&self, manifest: &mut Manifest) {
Expand Down Expand Up @@ -549,6 +556,14 @@ impl Builder {
dst.insert(profile_name.to_owned(), pkgs.iter().map(|s| (*s).to_owned()).collect());
}

fn extend_profile(&mut self,
profile_name: &str,
dst: &mut BTreeMap<String, Vec<String>>,
pkgs: &[&str]) {
dst.get_mut(profile_name).expect("existing profile")
.extend(pkgs.iter().map(|s| (*s).to_owned()));
}

fn package(&mut self,
pkgname: &str,
dst: &mut BTreeMap<String, Package>,
Expand Down

0 comments on commit 4c906dc

Please sign in to comment.