Proper scons executable on Windows (#34934)
This commit is contained in:
parent
1034b23320
commit
44c69cadf4
@ -2,9 +2,12 @@
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
import sys
|
||||
|
||||
from spack.package import *
|
||||
|
||||
is_windows = sys.platform == "win32"
|
||||
|
||||
|
||||
class Scons(PythonPackage):
|
||||
"""SCons is a software construction tool"""
|
||||
@ -56,4 +59,7 @@ def setup_dependent_run_environment(self, env, dependent_spec):
|
||||
env.prepend_path("PYTHONPATH", self.prefix.lib.scons)
|
||||
|
||||
def setup_dependent_package(self, module, dspec):
|
||||
if is_windows:
|
||||
module.scons = Executable(self.spec.prefix.Scripts.scons)
|
||||
else:
|
||||
module.scons = Executable(self.spec.prefix.bin.scons)
|
||||
|
Loading…
Reference in New Issue
Block a user