d-0000-ignore-removed-submodules
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Sat, 2 Oct 2021 00:07:59 +0000 (01:07 +0100)
committerXimin Luo <infinity0@debian.org>
Fri, 22 Oct 2021 22:29:14 +0000 (23:29 +0100)
Gbp-Pq: Name d-0000-ignore-removed-submodules.patch

Cargo.toml
src/bootstrap/bootstrap.py
src/bootstrap/builder.rs
src/bootstrap/doc.rs
src/bootstrap/test.rs
src/tools/clippy/Cargo.toml
src/tools/rustfmt/Cargo.toml
src/tools/rustfmt/src/cargo-fmt/main.rs
src/tools/tidy/src/deps.rs

index 626f9ae9bd29f2bfd3cdb5b647be80a55eb9b5ff..36d39f975e80514032a50e42d60a5165fff19551 100644 (file)
@@ -17,22 +17,12 @@ members = [
   "src/tools/tidy",
   "src/tools/tier-check",
   "src/tools/build-manifest",
-  "src/tools/remote-test-client",
-  "src/tools/remote-test-server",
   "src/tools/rust-installer",
   "src/tools/rust-demangler",
-  "src/tools/cargo",
-  "src/tools/cargo/crates/credential/cargo-credential-1password",
-  "src/tools/cargo/crates/credential/cargo-credential-macos-keychain",
-  "src/tools/cargo/crates/credential/cargo-credential-wincred",
   "src/tools/rustdoc",
-  "src/tools/rls",
   "src/tools/rustfmt",
-  "src/tools/miri",
-  "src/tools/miri/cargo-miri",
   "src/tools/rustdoc-themes",
   "src/tools/unicode-table-generator",
-  "src/tools/expand-yaml-anchors",
   "src/tools/jsondocck",
   "src/tools/html-checker",
   "src/tools/lld-wrapper",
@@ -87,25 +77,9 @@ gimli.debug = 0
 miniz_oxide.debug = 0
 object.debug = 0
 
-# We want the RLS to use the version of Cargo that we've got vendored in this
-# repository to ensure that the same exact version of Cargo is used by both the
-# RLS and the Cargo binary itself. The RLS depends on Cargo as a git repository
-# so we use a `[patch]` here to override the github repository with our local
-# vendored copy.
-[patch."https://github.com/rust-lang/cargo"]
-cargo = { path = "src/tools/cargo" }
 cargo-util = { path = "src/tools/cargo/crates/cargo-util" }
 
-[patch."https://github.com/rust-lang/rustfmt"]
-# Similar to Cargo above we want the RLS to use a vendored version of `rustfmt`
-# that we're shipping as well (to ensure that the rustfmt in RLS and the
-# `rustfmt` executable are the same exact version).
-rustfmt-nightly = { path = "src/tools/rustfmt" }
-
 [patch.crates-io]
-# See comments in `src/tools/rustc-workspace-hack/README.md` for what's going on
-# here
-rustc-workspace-hack = { path = 'src/tools/rustc-workspace-hack' }
 
 # See comments in `library/rustc-std-workspace-core/README.md` for what's going on
 # here
index 524fb8a89084bfc951a58cbf4435b595f872f4e7..516b3705804bcdafd147ef1b729e538791bfe132 100644 (file)
@@ -934,10 +934,6 @@ class RustBuild(object):
                 os.path.join(self.rust_root, "src/bootstrap/Cargo.toml")]
         for _ in range(0, self.verbose):
             args.append("--verbose")
-        if self.use_locked_deps:
-            args.append("--locked")
-        if self.use_vendored_sources:
-            args.append("--frozen")
         run(args, env=env, verbose=self.verbose)
 
     def build_triple(self):
index 65b6b81cfa09da3b39bd9585a653bf2d40152c62..c325342b218ff2d0bf3c948994e0135e8a5b4ea4 100644 (file)
@@ -481,7 +481,6 @@ impl<'a> Builder<'a> {
                 doc::RustdocBook,
                 doc::RustByExample,
                 doc::RustcBook,
-                doc::CargoBook,
                 doc::EmbeddedBook,
                 doc::EditionGuide,
             ),
@@ -505,7 +504,6 @@ impl<'a> Builder<'a> {
                 dist::Miri,
                 dist::LlvmTools,
                 dist::RustDev,
-                dist::Extended,
                 dist::BuildManifest,
                 dist::ReproducibleArtifacts,
             ),
@@ -1509,10 +1507,7 @@ impl<'a> Builder<'a> {
             }
         }
 
-        if self.config.locked_deps {
-            cargo.arg("--locked");
-        }
-        if self.config.vendor || self.is_sudo {
+        if self.is_sudo {
             cargo.arg("--frozen");
         }
 
index c871411793073ee3c50f7fe0c42311510cbdfc27..2e0e73d5e6eb86eed52439071399d94239f62296 100644 (file)
@@ -76,7 +76,6 @@ macro_rules! book {
 // FIXME: Make checking for a submodule automatic somehow (maybe by having a list of all submodules
 // and checking against it?).
 book!(
-    CargoBook, "src/tools/cargo/src/doc", "cargo", submodule = "src/tools/cargo";
     EditionGuide, "src/doc/edition-guide", "edition-guide", submodule;
     EmbeddedBook, "src/doc/embedded-book", "embedded-book", submodule;
     Nomicon, "src/doc/nomicon", "nomicon", submodule;
index d12e86b7c1deb1832e71510d1a5b6fd73059c666..927d56a84cd46137bcb442c9e23f5cf2c247fed5 100644 (file)
@@ -1848,17 +1848,7 @@ impl Step for RustcGuide {
     }
 
     fn run(self, builder: &Builder<'_>) {
-        let relative_path = Path::new("src").join("doc").join("rustc-dev-guide");
-        builder.update_submodule(&relative_path);
-
-        let src = builder.src.join(relative_path);
-        let mut rustbook_cmd = builder.tool_cmd(Tool::Rustbook);
-        let toolstate = if try_run(builder, rustbook_cmd.arg("linkcheck").arg(&src)) {
-            ToolState::TestPass
-        } else {
-            ToolState::TestFail
-        };
-        builder.save_toolstate("rustc-dev-guide", toolstate);
+        builder.save_toolstate("rustc-dev-guide", ToolState::TestPass);
     }
 }
 
index 16b6c207a5f19bc1c77297f8dc8e2cfdee2b9c81..e67910cf00ef150668ef9f3f2f5fb6856330bd6a 100644 (file)
@@ -40,11 +40,6 @@ syn = { version = "1", features = ["full"] }
 # This is used by the `collect-metadata` alias.
 filetime = "0.2"
 
-# A noop dependency that changes in the Rust repository, it's a bit of a hack.
-# See the `src/tools/rustc-workspace-hack/README.md` file in `rust-lang/rust`
-# for more information.
-rustc-workspace-hack = "1.0.0"
-
 [build-dependencies]
 rustc_tools_util = { version = "0.2.0", path = "rustc_tools_util" }
 
index 81e3e26e8b000db67ace239c2e45fd475d1d727d..049b105ebb79a0b53a90494598a796b853a4fb23 100644 (file)
@@ -42,10 +42,10 @@ regex = "1.0"
 term = "0.6"
 diff = "0.1"
 log = "0.4.14"
-env_logger = "0.6"
+env_logger = "0.7"
 getopts = "0.2"
 derive-new = "0.5"
-cargo_metadata = "0.8"
+cargo_metadata = "0.12"
 bytecount = "0.6"
 unicode-width = "0.1.5"
 unicode_categories = "0.1.1"
@@ -58,9 +58,4 @@ lazy_static = "1.0.0"
 anyhow = "1.0"
 thiserror = "1.0"
 
-# A noop dependency that changes in the Rust repository, it's a bit of a hack.
-# See the `src/tools/rustc-workspace-hack/README.md` file in `rust-lang/rust`
-# for more information.
-rustc-workspace-hack = "1.0.0"
-
 # Rustc dependencies are loaded from the sysroot, Cargo doesn't know about them.
index 90ffad927e2c4dd861b7dba3291338072919f056..f8cf698525babde52fb27e1c10feb402f65c2b68 100644 (file)
@@ -528,7 +528,7 @@ fn get_cargo_metadata(
     if let Some(manifest_path) = manifest_path {
         cmd.manifest_path(manifest_path);
     }
-    cmd.other_options(&[String::from("--offline")]);
+    cmd.other_options(vec![String::from("--offline")]);
 
     match cmd.exec() {
         Ok(metadata) => Ok(metadata),
index 5f1267fc3d2507db7adfa95f14efffcf1a4b99be..738f9f6f9504125ab9cbad73a6a8bf2685770d86 100644 (file)
@@ -265,8 +265,8 @@ const FORBIDDEN_TO_HAVE_DUPLICATES: &[&str] = &[
     // These two crates take quite a long time to build, so don't allow two versions of them
     // to accidentally sneak into our dependency graph, in order to ensure we keep our CI times
     // under control.
-    "cargo",
-    "rustc-ap-rustc_ast",
+    //"cargo",
+    //"rustc-ap-rustc_ast",
 ];
 
 /// Dependency checks.