summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/spack/spack/stage.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/spack/spack/stage.py b/lib/spack/spack/stage.py
index 8933ad6da2..61faec6de9 100644
--- a/lib/spack/spack/stage.py
+++ b/lib/spack/spack/stage.py
@@ -323,10 +323,11 @@ class Stage(object):
def cache_local(self):
archiveDst = join_path(os.path.abspath(spack.cache_path), self.mirror_path)
- mkdirp(os.path.dirname(archiveDst))
- # TODO: this moves the archive for URLFetchStrategy vs. a copy - edit
- # to do a move?
- self.fetcher.archive(archiveDst)
+ if not os.path.exists(archiveDst): #tmp conditional
+ mkdirp(os.path.dirname(archiveDst))
+ # TODO: this moves the archive for URLFetchStrategy vs. a copy -
+ # edit to do a move?
+ self.fetcher.archive(archiveDst)
def expand_archive(self):