From 716196930aff66253eb3f6339531a06c65f174ac Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Fri, 22 Sep 2023 13:04:58 +0200 Subject: Remove distutils dependency in Spack (#40153) * msvc.py: don't import distutils Introduced in #27021, makes Spack forward incompatible with Python. The module was already deprecated at the time of the PR. * update spack package --- var/spack/repos/builtin/packages/spack/package.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'var') diff --git a/var/spack/repos/builtin/packages/spack/package.py b/var/spack/repos/builtin/packages/spack/package.py index e656f8656b..ba1e026e81 100644 --- a/var/spack/repos/builtin/packages/spack/package.py +++ b/var/spack/repos/builtin/packages/spack/package.py @@ -61,10 +61,15 @@ class Spack(Package): # This should be read as "require at least curl", not "require curl". requires("fetchers=curl", when="@:0.16", msg="Curl is required for Spack < 0.17") - # Python (with spack python -i ipython support) + # Python depends_on("python@2.6.0:2.7,3.5:", type="run") depends_on("python@2.7.0:2.7,3.5:", type="run", when="@0.18.0:") depends_on("python@2.7.0:2.7,3.6:", type="run", when="@0.19.0:") + + # Old Spack unfortunately depends on distutils, removed in Python 3.12 + depends_on("python@:3.12", type="run", when="@0.18:0.20.1") + + # spack python -i ipython support depends_on("py-ipython", type="run") # Concretizer -- cgit v1.2.3-70-g09d2