]> git.lizzy.rs Git - rust.git/blobdiff - src/bootstrap/lib.rs
Rollup merge of #38699 - japaric:lsan, r=alexcrichton
[rust.git] / src / bootstrap / lib.rs
index 1d01b8773cec88c339cff79ecde78fe7401db4b8..ba6b34343f0b35d15554fd0f5b142c71daa9c627 100644 (file)
@@ -879,6 +879,17 @@ fn musl_root(&self, target: &str) -> Option<&Path> {
             .map(|p| &**p)
     }
 
+    /// Returns the root of the "rootfs" image that this target will be using,
+    /// if one was configured.
+    ///
+    /// If `Some` is returned then that means that tests for this target are
+    /// emulated with QEMU and binaries will need to be shipped to the emulator.
+    fn qemu_rootfs(&self, target: &str) -> Option<&Path> {
+        self.config.target_config.get(target)
+            .and_then(|t| t.qemu_rootfs.as_ref())
+            .map(|p| &**p)
+    }
+
     /// Path to the python interpreter to use
     fn python(&self) -> &Path {
         self.config.python.as_ref().unwrap()