Adding init_config back. Don't initalize config rather let compiler_find do all the work. spack compiler list and spack compilers can do the work
This commit is contained in:
parent
64c83638ff
commit
fe30113502
@ -76,8 +76,13 @@ def compiler_find(args):
|
|||||||
if not paths:
|
if not paths:
|
||||||
paths = get_path('PATH')
|
paths = get_path('PATH')
|
||||||
|
|
||||||
compilers = [c for c in spack.compilers.find_compilers(*args.add_paths)
|
# Don't initialize compilers config via compilers.get_compiler_config.
|
||||||
if c.spec not in spack.compilers.all_compilers(scope=args.scope)]
|
# Just let compiler_find do the
|
||||||
|
# entire process and return an empty config from all_compilers
|
||||||
|
# Default for any other process is init_config=True
|
||||||
|
compilers = [c for c in spack.compilers.find_compilers(*paths)
|
||||||
|
if c.spec not in spack.compilers.all_compilers(
|
||||||
|
scope=args.scope, init_config=False)]
|
||||||
if compilers:
|
if compilers:
|
||||||
spack.compilers.add_compilers_to_config(compilers, scope=args.scope)
|
spack.compilers.add_compilers_to_config(compilers, scope=args.scope)
|
||||||
n = len(compilers)
|
n = len(compilers)
|
||||||
|
Loading…
Reference in New Issue
Block a user