fix catalyst so that it doesn't depend on a particular spelling of python (#16667)

This commit is contained in:
Omar Padron
2020-05-15 15:11:32 -04:00
committed by GitHub
parent 32a9adcf60
commit 97d7ef678d

View File

@@ -6,6 +6,7 @@
from spack import *
import os
import subprocess
import sys
import llnl.util.tty as tty
@@ -133,7 +134,12 @@ def do_stage(self, mirror_only=False):
'Editions')
catalyst_source_dir = os.path.abspath(self.root_cmakelists_dir)
command = ['python', catalyst_script,
python_path = (os.path.realpath(
spec['python3'].command.path if '+python3' in self.spec else
spec['python'].command.path if '+python' in self.spec else
sys.executable))
command = [python_path, catalyst_script,
'-r', self.stage.source_path,
'-o', catalyst_source_dir]