]> git.lizzy.rs Git - rust.git/commitdiff
switch to my xargo fork, because that one works with current libstd
authorRalf Jung <post@ralfj.de>
Wed, 1 May 2019 18:37:08 +0000 (20:37 +0200)
committerRalf Jung <post@ralfj.de>
Wed, 1 May 2019 18:37:08 +0000 (20:37 +0200)
src/bin/cargo-miri.rs

index 5fc6f4af2b2d3896e95f7a345a3b19040572e2e9..8fb6d04aa07ef0d447ae304321e6436e492ff945 100644 (file)
@@ -133,7 +133,11 @@ fn xargo_version() -> Option<(u32, u32, u32)> {
         (split.next().expect("malformed `xargo --version` output: empty"),
          split.next().expect("malformed `xargo --version` output: not at least two words"))
     };
-    if name != "xargo" {
+    if name == "xargo" {
+        // This is the upstream version which is currently broken, we need our fork.
+        return None;
+    }
+    if name != "xargo-rj" {
         panic!("malformed `xargo --version` output: application name is not `xargo`");
     }
     let mut version_pieces = version.split('.');
@@ -183,11 +187,11 @@ fn setup(ask_user: bool) {
     let xargo = xargo_version();
     if xargo.map_or(true, |v| v < (0, 3, 13)) {
         if ask_user {
-            ask("It seems you do not have a recent enough xargo installed. I will run `cargo install xargo -f`. Proceed?");
+            ask("It seems you do not have a recent enough xargo installed. I will run `cargo install --git https://github.com/RalfJung/xargo -f`. Proceed?");
         } else {
-            println!("Installing xargo: `cargo install xargo -f`");
+            println!("Installing xargo: `cargo install --git https://github.com/RalfJung/xargo -f`");
         }
-        if !Command::new("cargo").args(&["install", "xargo", "-f"]).status().unwrap().success() {
+        if !Command::new("cargo").args(&["install", "--git", "https://github.com/RalfJung/xargo", "-f"]).status().unwrap().success() {
             show_error(format!("Failed to install xargo"));
         }
     }