diff --git a/src/bootstrap/tarball.rs b/src/bootstrap/tarball.rs index c743c5188e7..689b4819cdd 100644 --- a/src/bootstrap/tarball.rs +++ b/src/bootstrap/tarball.rs @@ -262,11 +262,13 @@ pub(crate) fn bare(self) -> GeneratedTarball { t!(std::fs::rename(&self.image_dir, &dest)); self.run(|this, cmd| { + let distdir = crate::dist::distdir(this.builder); + t!(std::fs::create_dir_all(&distdir)); cmd.arg("tarball") .arg("--input") .arg(&dest) .arg("--output") - .arg(crate::dist::distdir(this.builder).join(this.package_name())); + .arg(distdir.join(this.package_name())); }) }