def download_tarball(spec):
    '\n    Download binary tarball for given package into stage area\n    Return True if successful\n    '
    if (not spack.mirror.MirrorCollection()):
        tty.die(('Please add a spack mirror to allow ' + 'download of pre-compiled packages.'))
    tarball = tarball_path_name(spec, '.spack')
    for mirror in spack.mirror.MirrorCollection().values():
        url = url_util.join(mirror.fetch_url, _build_cache_relative_path, tarball)
        stage = Stage(url, name='build_cache', keep=True)
        try:
            stage.fetch()
            return stage.save_filename
        except fs.FetchError:
            continue
    return None
Download binary tarball for given package into stage area
Return True if successful
def download_tarball(spec):
    '\n    Download binary tarball for given package into stage area\n    Return True if successful\n    '
    if (not spack.mirror.MirrorCollection()):
        tty.die(('Please add a spack mirror to allow ' + 'download of pre-compiled packages.'))
    tarball = tarball_path_name(spec, '.spack')
    for mirror in spack.mirror.MirrorCollection().values():
        url = url_util.join(mirror.fetch_url, _build_cache_relative_path, tarball)
        stage = Stage(url, name='build_cache', keep=True)
        try:
            stage.fetch()
            return stage.save_filename
        except fs.FetchError:
            continue
    return None