summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/gcc/package.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/gcc/package.py b/var/spack/repos/builtin/packages/gcc/package.py
index 769098221e..a5ceb46046 100644
--- a/var/spack/repos/builtin/packages/gcc/package.py
+++ b/var/spack/repos/builtin/packages/gcc/package.py
@@ -95,6 +95,9 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage):
variant('nvptx',
default=False,
description='Target nvptx offloading to NVIDIA GPUs')
+ variant('bootstrap',
+ default=False,
+ description='add --enable-bootstrap flag for stage3 build')
depends_on('flex', type='build', when='@master')
@@ -468,11 +471,15 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage):
if spec.satisfies('+binutils'):
binutils = spec['binutils'].prefix.bin
options.extend([
- '--with-sysroot=/',
'--with-gnu-ld',
'--with-ld=' + binutils.ld,
'--with-gnu-as',
'--with-as=' + binutils.join('as'),
+ ])
+
+ # enable_bootstrap
+ if spec.satisfies('+bootstrap'):
+ options.extend([
'--enable-bootstrap',
])