Remove unused codepath for single-file tools. NFC (#1013)

We don't have any tools that are just one file, and indeed we
assume these days that tools install to their own directory.
This commit is contained in:
Sam Clegg
2022-03-24 22:29:40 +00:00
committed by GitHub
parent 2a68987f5e
commit 1b1f5f24df

View File

@@ -1968,11 +1968,7 @@ class Tool(object):
elif url.endswith(ARCHIVE_SUFFIXES): elif url.endswith(ARCHIVE_SUFFIXES):
success = download_and_unzip(url, self.installation_path(), filename_prefix=getattr(self, 'zipfile_prefix', '')) success = download_and_unzip(url, self.installation_path(), filename_prefix=getattr(self, 'zipfile_prefix', ''))
else: else:
dst_file = download_file(urljoin(emsdk_packages_url, self.download_url()), self.installation_path()) assert False
if dst_file:
success = True
else:
success = False
if not success: if not success:
exit_with_error("installation failed!") exit_with_error("installation failed!")
@@ -2017,7 +2013,7 @@ class Tool(object):
def cleanup_temp_install_files(self): def cleanup_temp_install_files(self):
if KEEP_DOWNLOADS: if KEEP_DOWNLOADS:
return return
url = self.download_url() url = self.download_url()
if url.endswith(ARCHIVE_SUFFIXES): if url.endswith(ARCHIVE_SUFFIXES):
download_target = get_download_target(url, zips_subdir, getattr(self, 'zipfile_prefix', '')) download_target = get_download_target(url, zips_subdir, getattr(self, 'zipfile_prefix', ''))