summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/gcc/package.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/gcc/package.py b/var/spack/repos/builtin/packages/gcc/package.py
index 86e2b843e4..6bdfaeccc2 100644
--- a/var/spack/repos/builtin/packages/gcc/package.py
+++ b/var/spack/repos/builtin/packages/gcc/package.py
@@ -426,6 +426,10 @@ class Gcc(AutotoolsPackage):
# Get the contents of the installed binary directory
bin_path = self.spec.prefix.bin
+
+ if not os.path.isdir(bin_path):
+ return
+
bin_contents = os.listdir(bin_path)
# Find the first non-symlink compiler binary present for each language